From: SourceForge.net <no...@so...> - 2005-10-26 06:36:11
|
Bugs item #1305065, was opened at 2005-09-26 20:11 Message generated for change (Settings changed) made by bernhardheld You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=100599&aid=1305065&group_id=599 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: C-Front End Group: None Status: Open Resolution: None Priority: 5 Submitted By: Josef Pavlik (jetset) >Assigned to: Bernhard Held (bernhardheld) Summary: constant calculation problem Initial Comment: hi all, I found an problem with the following piece of code: void xx(int x){} main() { xx((-100)*10L*200L/254); // makes bad code xx((-100)*2000L/254); // this is right } the result is following: ;x.c:4: xx((-100)*10L*200L/254); mov dptr,#0x00F4 lcall _xx ;x.c:5: xx((-100)*2000L/254); mov dptr,#0xFCED ljmp _xx sdcc x.c sdcc -v SDCC : mcs51/gbz80/z80/avr/ds390/pic16/pic14/TININative/xa51/ds400/hc08 2.5.3 #1116 (Sep 26 2005) (UNIX) ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=100599&aid=1305065&group_id=599 |