1
0
mirror of https://github.com/cc65/cc65.git synced 2024-07-10 23:29:05 +00:00
cc65/libsrc/pce/clock.s

22 lines
322 B
ArmAsm
Raw Normal View History

;
; clock_t clock (void);
;
2015-07-12 12:27:24 +00:00
.include "pce.inc"
2014-11-30 10:20:57 +00:00
2015-07-12 12:27:24 +00:00
.export _clock
2014-11-30 10:20:57 +00:00
.importzp sreg
2015-07-14 17:55:41 +00:00
;; .importzp tickcount
2015-07-12 12:27:24 +00:00
.proc _clock
2015-07-14 17:55:41 +00:00
lda tickcount+3
2015-07-12 14:40:52 +00:00
sta sreg+1
2015-07-14 17:55:41 +00:00
lda tickcount+2
2015-07-12 14:40:52 +00:00
sta sreg
2015-07-14 17:55:41 +00:00
ldx tickcount+1
lda tickcount
2014-11-30 10:20:57 +00:00
rts
.endproc