Discussion:
TSIM simulation time overflow
Sven-Åke Andersson
2012-02-27 10:06:42 UTC
Permalink
I am trying to load my Linux image and simulate it using TSIM. Here is what
happens.
I get a simulation time overflow. I am using the SP605 board.

Sven


-> tsim-leon3 -mmu images/image.dsu

This TSIM evaluation version will expire July 1, 2012


TSIM/LEON3 SPARC simulator, version 2.0.21 (evaluation version)

Copyright (C) 2001, Gaisler Research - all rights reserved.
This software may only be used with a valid license.
For latest updates, go to http://www.gaisler.com/
Comments or bug-reports to tsim-FkzTOoA/***@public.gmane.org

serial port A on stdin/stdout
allocated 4096 K RAM memory, in 1 bank(s)
allocated 32 M SDRAM memory, in 1 bank
allocated 2048 K ROM memory
icache: 1 * 4 kbytes, 16 bytes/line (4 kbytes total)
dcache: 1 * 4 kbytes, 16 bytes/line (4 kbytes total)
section: .stage2, addr: 0x40000000, size 10240 bytes
section: .vmlinux, addr: 0x40004000, size 2904128 bytes
read 3717 symbols
tsim>

tsim> go
go
resuming at 0x40000000
Booting Linux
Booting Linux...
PROMLIB: Sun Boot Prom Version 0 Revision 0
Linux version 2.6.21.1 (***@Superdatorn) (gcc version 3.4.4) #12 Mon Feb
20 08:54:34 CET 2012
ARCH: LEON
TYPE: Leon2/3 System-on-a-Chip
Ethernet address: 0:0:0:0:0:0
CACHE: direct mapped cache, set size 4k
CACHE: not flushing on every context switch
Boot time fixup v1.6. 4/Mar/98 Jakub Jelinek (jj-***@public.gmane.org). Patching
kernel for srmmu[Leon2]/iommu
Nocache: 0xfc000000-0xfc080000, 128 pages [128-1280]
node 2: /cpu00 (type:cpu) (props:.node device_type mid mmu-nctx
clock-frequency uart1_baud uart2_baud )
node 3: /a: (type:serial) (props:.node device_type name )
node 4: /ambapp0 (type:ambapp) (props:.node device_type name )
PROM: Built device tree from rootnode 1 with 1478 bytes of memory.
DEBUG: psr.impl = 0xf fsr.vers = 0x7
Built 1 zonelists. Total pages: 277
Kernel command line: console=ttyS0,38400 rdinit=/sbin/init
PID hash table entries: 16 (order: 4, 64 bytes)
Todo: init master_l10_counter
Attaching grlib apbuart serial drivers (clk:50hz):
Console: colour dummy device 80x25
Dentry cache hash table entries: 1024 (order: 0, 4096 bytes)
Inode-cache hash table entries: 1024 (order: 0, 4096 bytes)
pkbase: 0xfc800000 pkend: 0xfcc00000 fixstart 0xfcff1000
Memory: 580k/4096k available (940k kernel code, 3516k reserved, 108k data,
1780k init, 0k highmem)
Mount-cache hash table entries: 512
Simulation time overflow (2^32) - halting

Program exited normally.
tsim>


[Non-text portions of this message have been removed]



------------------------------------
Jiri Gaisler
2012-02-27 10:22:39 UTC
Permalink
TSIM evaluation version is limited to 32-bit time, roughly
equal to 1 minutes real-time @ 50 MHz. However, this is no
your problem - the real issue is that you are trying to run
linux with only 4 Mbyte SRAM, this will obviously not work.
Try this command line instead:

tsim-leon3 -nosram -sdram 32 -mmu images/image.dsu

Jiri.
Post by Sven-Åke Andersson
I am trying to load my Linux image and simulate it using TSIM. Here is what
happens.
I get a simulation time overflow. I am using the SP605 board.
Sven
-> tsim-leon3 -mmu images/image.dsu
This TSIM evaluation version will expire July 1, 2012
TSIM/LEON3 SPARC simulator, version 2.0.21 (evaluation version)
Copyright (C) 2001, Gaisler Research - all rights reserved.
This software may only be used with a valid license.
For latest updates, go to http://www.gaisler.com/
serial port A on stdin/stdout
allocated 4096 K RAM memory, in 1 bank(s)
allocated 32 M SDRAM memory, in 1 bank
allocated 2048 K ROM memory
icache: 1 * 4 kbytes, 16 bytes/line (4 kbytes total)
dcache: 1 * 4 kbytes, 16 bytes/line (4 kbytes total)
section: .stage2, addr: 0x40000000, size 10240 bytes
section: .vmlinux, addr: 0x40004000, size 2904128 bytes
read 3717 symbols
tsim>
tsim> go
go
resuming at 0x40000000
Booting Linux
Booting Linux...
PROMLIB: Sun Boot Prom Version 0 Revision 0
20 08:54:34 CET 2012
ARCH: LEON
TYPE: Leon2/3 System-on-a-Chip
Ethernet address: 0:0:0:0:0:0
CACHE: direct mapped cache, set size 4k
CACHE: not flushing on every context switch
kernel for srmmu[Leon2]/iommu
Nocache: 0xfc000000-0xfc080000, 128 pages [128-1280]
node 2: /cpu00 (type:cpu) (props:.node device_type mid mmu-nctx
clock-frequency uart1_baud uart2_baud )
node 3: /a: (type:serial) (props:.node device_type name )
node 4: /ambapp0 (type:ambapp) (props:.node device_type name )
PROM: Built device tree from rootnode 1 with 1478 bytes of memory.
DEBUG: psr.impl = 0xf fsr.vers = 0x7
Built 1 zonelists. Total pages: 277
Kernel command line: console=ttyS0,38400 rdinit=/sbin/init
PID hash table entries: 16 (order: 4, 64 bytes)
Todo: init master_l10_counter
Console: colour dummy device 80x25
Dentry cache hash table entries: 1024 (order: 0, 4096 bytes)
Inode-cache hash table entries: 1024 (order: 0, 4096 bytes)
pkbase: 0xfc800000 pkend: 0xfcc00000 fixstart 0xfcff1000
Memory: 580k/4096k available (940k kernel code, 3516k reserved, 108k data,
1780k init, 0k highmem)
Mount-cache hash table entries: 512
Simulation time overflow (2^32) - halting
Program exited normally.
tsim>
[Non-text portions of this message have been removed]
------------------------------------
Sven
2012-02-27 11:01:34 UTC
Permalink
I used the command you proposed. This time it continued until
the linux prompt and then stopped with Simulation time overflow


-> tsim-leon3 -nosram -sdram 32 -mmu images/image.dsu
switch -sdram is not supported by the evaluation version

This TSIM evaluation version will expire July 1, 2012


TSIM/LEON3 SPARC simulator, version 2.0.21 (evaluation version)

Copyright (C) 2001, Gaisler Research - all rights reserved.
This software may only be used with a valid license.
For latest updates, go to http://www.gaisler.com/
Comments or bug-reports to tsim-FkzTOoA/***@public.gmane.org

serial port A on stdin/stdout
allocated 4096 K RAM memory, in 1 bank(s)
allocated 32 M SDRAM memory, in 1 bank
allocated 2048 K ROM memory
icache: 1 * 4 kbytes, 16 bytes/line (4 kbytes total)
dcache: 1 * 4 kbytes, 16 bytes/line (4 kbytes total)
section: .stage2, addr: 0x40000000, size 10240 bytes
section: .vmlinux, addr: 0x40004000, size 2904128 bytes
read 3717 symbols
tsim> go

.......................


End of printout.


Mount-cache hash table entries: 512
leon: power management initialized
io scheduler noop registered
io scheduler cfq registered (default)
grlib apbuart: 2 serial driver(s) at [0x80000100(irq 2),0x80000900(irq 3)]
grlib apbuart: system frequency: 50000 khz, baud rates: 38400 38400
ttyS0 at MMIO 0x80000100 (irq = 2) is a Leon
Testing fifo size for UART port 0: got 0 bytes.
ttyS1 at MMIO 0x80000900 (irq = 3) is a Leon
Testing fifo size for UART port 1: got 0 bytes.
RAMDISK driver initialized: 16 RAM disks of 4096K size 1024 blocksize
loop: loaded (max 8 devices)
Freeing unused kernel memory: 1780k freed
init started: BusyBox v1.8.2 (2012-02-17 10:35:39 CET)
starting pid 14, tty '': '/etc/init.d/rcS'
Shell invoked to run file: /etc/init.d/rcS
Command: #!/bin/sh
Command: mount -t proc none /proc
Command: mount -t sysfs none /sys
Command: mount -t devpts devpts /dev/pts
Command: mount -t tmpfs -o size=1M tmpfs /var/tmp
mount: mounting tmpfs on /var/tmp failed: Invalid argument
pid 18: failed 65280
Command:
Command: hostname sparky
Command:
Command: /sbin/ifconfig lo up 127.0.0.1 netmask 255.0.0.0
ifconfig: socket: Function not implemented
pid 20: failed 256
Command: /sbin/ifconfig eth0 up 192.168.0.80
ifconfig: socket: Function not implemented
pid 21: failed 256
Command:
Command: route add 127.0.0.1 dev lo
route: socket: Function not implemented
pid 22: failed 256
Command: route add default dev eth0
route: socket: Function not implemented
pid 23: failed 256
Command:
Command: /bin/portmap &
/bin/portmap: Bad command or file name

sh 14: Child 24 died
[24]
Command: #mount -o nolock -o ro -t nfs 192.168.0.15:/home /home/nfs
Execution Finished, Exiting
starting pid 25, tty '': '/bin/sh'

Sash command shell (version 1.1.1)
/> Simulation time overflow (2^32) - halting

Program exited normally.
tsim>





------------------------------------
Jiri Gaisler
2012-02-27 12:05:47 UTC
Permalink
Post by Sven
I used the command you proposed. This time it continued until
the linux prompt and then stopped with Simulation time overflow
Looks good to me. Once you get to the promt, the linux kernel
might invoke the power-saving functions in the processor,
accelerating the simulation speed significantly. The eval
version of TSIM will then time-out pretty quick ...

Jiri.
Post by Sven
-> tsim-leon3 -nosram -sdram 32 -mmu images/image.dsu
switch -sdram is not supported by the evaluation version
This TSIM evaluation version will expire July 1, 2012
TSIM/LEON3 SPARC simulator, version 2.0.21 (evaluation version)
Copyright (C) 2001, Gaisler Research - all rights reserved.
This software may only be used with a valid license.
For latest updates, go to http://www.gaisler.com/
serial port A on stdin/stdout
allocated 4096 K RAM memory, in 1 bank(s)
allocated 32 M SDRAM memory, in 1 bank
allocated 2048 K ROM memory
icache: 1 * 4 kbytes, 16 bytes/line (4 kbytes total)
dcache: 1 * 4 kbytes, 16 bytes/line (4 kbytes total)
section: .stage2, addr: 0x40000000, size 10240 bytes
section: .vmlinux, addr: 0x40004000, size 2904128 bytes
read 3717 symbols
tsim> go
.......................
End of printout.
Mount-cache hash table entries: 512
leon: power management initialized
io scheduler noop registered
io scheduler cfq registered (default)
grlib apbuart: 2 serial driver(s) at [0x80000100(irq 2),0x80000900(irq 3)]
grlib apbuart: system frequency: 50000 khz, baud rates: 38400 38400
ttyS0 at MMIO 0x80000100 (irq = 2) is a Leon
Testing fifo size for UART port 0: got 0 bytes.
ttyS1 at MMIO 0x80000900 (irq = 3) is a Leon
Testing fifo size for UART port 1: got 0 bytes.
RAMDISK driver initialized: 16 RAM disks of 4096K size 1024 blocksize
loop: loaded (max 8 devices)
Freeing unused kernel memory: 1780k freed
init started: BusyBox v1.8.2 (2012-02-17 10:35:39 CET)
starting pid 14, tty '': '/etc/init.d/rcS'
Shell invoked to run file: /etc/init.d/rcS
Command: #!/bin/sh
Command: mount -t proc none /proc
Command: mount -t sysfs none /sys
Command: mount -t devpts devpts /dev/pts
Command: mount -t tmpfs -o size=1M tmpfs /var/tmp
mount: mounting tmpfs on /var/tmp failed: Invalid argument
pid 18: failed 65280
Command: hostname sparky
Command: /sbin/ifconfig lo up 127.0.0.1 netmask 255.0.0.0
ifconfig: socket: Function not implemented
pid 20: failed 256
Command: /sbin/ifconfig eth0 up 192.168.0.80
ifconfig: socket: Function not implemented
pid 21: failed 256
Command: route add 127.0.0.1 dev lo
route: socket: Function not implemented
pid 22: failed 256
Command: route add default dev eth0
route: socket: Function not implemented
pid 23: failed 256
Command: /bin/portmap &
/bin/portmap: Bad command or file name
sh 14: Child 24 died
[24]
Command: #mount -o nolock -o ro -t nfs 192.168.0.15:/home /home/nfs
Execution Finished, Exiting
starting pid 25, tty '': '/bin/sh'
Sash command shell (version 1.1.1)
/> Simulation time overflow (2^32) - halting
Program exited normally.
tsim>
------------------------------------

Loading...