[cc65] printf (C64 library) enables interrupts

From: Frank Buss <fb1frank-buss.de>
Date: 2014-07-20 21:21:55
I don't know if this is a bug and already fixed in later version, or if there is a reason why printf needs interrupts, but it was surprising for me.


C code (i is uint16_t) :

printf("%i%%", i * 100 >> 5);


VICE:

.C:2080  A0 04       LDY #$04       - A:00 X:00 Y:00 SP:f4 ..-..IZC   16427490
(C:$2080) n
.C:2082  20 BC 2B    JSR $2BBC      - A:00 X:00 Y:04 SP:f4 ..-..I.C   16427492
(C:$2082) n
.C:2085  A9 11       LDA #$11       - A:02 X:00 Y:04 SP:f4 ..-.....   16435189
(C:$2085) n


map file:
_printf                   002BBC RLA    


----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Sun Jul 20 21:27:30 2014

This archive was generated by hypermail 2.1.8 : 2014-07-20 21:27:33 CEST