[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [avr-gcc-list] simulator
From: |
Theodore A. Roth |
Subject: |
Re: [avr-gcc-list] simulator |
Date: |
Mon, 1 Oct 2001 13:42:00 -0600 (MDT) |
Ok, I just did a simple test to see how fast my simulator is. I am only
getting about 250 instructions per second. I doubt this would be
acceptable.
I'd only been running very simple short programs before so I didn't really
notice how slow it is. I might be able to speed it up some, but it doesn't
look like it can help much. Looks like it's time for C.
What is the minimum inst/sec that would be satisfactory?
Ted Roth
Here's the asm program I ran through it (2964 inst in 12.28 seconds on my
PPro 180):
.device AT90S8515
.include "8515def.inc"
.cseg
rjmp MAIN ; reset
nop ; int0
nop ; int1
nop ; timer1 capt
nop ; timer1 compa
nop ; timer1 compb
nop ; timer1 ovf
nop ; timer0 ovf
nop ; spi, stc
nop ; uart, rx
nop ; uart, udre
nop ; uart, tx
nop ; ana_comp
MAIN:
;; init stack pointer to 0x025f (the last byte of int sram)
ldi r16, $5f ; low byte of end
of int sram
out SPL, r16
ldi r16, $02 ; high byte of end
of int sram
out SPH, r16
ldi r16, $0f ; initialize outer
loop counter
LOOP1:
cpi r16, $00
breq DONE
dec r16
rcall INNER
rjmp LOOP1
INNER:
ldi r17, $2f ; initialize inner
loop counter
LOOP2:
cpi r17, $00
breq REPEAT
dec r17
rjmp LOOP2
REPEAT:
ret
DONE:
nop
Re: [avr-gcc-list] simulator, Bruce D. Lightner, 2001/10/01
RE: [avr-gcc-list] simulator, Bart McCoard, 2001/10/05