From: SourceForge.net <no...@so...> - 2005-07-22 22:14:30
|
Bugs item #1241835, was opened at 2005-07-20 14:55 Message generated for change (Comment added) made by epetrich You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=100599&aid=1241835&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: hc08 port Group: None Status: Open Resolution: None Priority: 5 Submitted By: Nobody/Anonymous (nobody) Assigned to: Nobody/Anonymous (nobody) Summary: Cast bug or subtraction bug Initial Comment: Hi.Look at this piece of code: ;PageOffset = (uint8_t)(Address-FLASH_GIVE_PAGE(Address)); lda 6,s sta 1,s lda 6,s and #0xC0 sta 4,s lda 5,s sta 3,s lda 4,s lda 1,s psha sub 1,s Variables Address and the result of FLASH_GIVE_PAGE macro are 16 bit, variable PageOffset is 8 bit.When I try to cast the 16 bit result of subtraction to 8 bit variable there is a mistake as you can see.Very similar mistake was in 16 bit comparison bug. ---------------------------------------------------------------------- >Comment By: Erik Petrich (epetrich) Date: 2005-07-22 17:14 Message: Logged In: YES user_id=635249 Fixed in src/hc08/gen.c 1.37 (SDCC version 2.5.1 #1066) ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=100599&aid=1241835&group_id=599 |