[arm-gnu] strtoull - Newlib C Library - No
info at seng.de
info at seng.de
Wed Aug 29 14:16:24 UTC 2012
Hello,
Already increased stack size --> same result.
replaced "strtoull" by some source-code I fished from the net. Hopefully
started the program - and had the same result...
Identified the following sequence inside the code that leads to the
strange result:
long long test1 = 10, test2 = 4, test3;
test3 = test1 / test2;
As soon as the code of a division of a long long variable exists inside
the program (no matter where), the program shows the strange results.
Think that the code of strtoull contains a division too.
Manual "Using the GNU Compiler Collection, chapter 6.9" tells that long
long divisions are open coded and are available only on machines
'providing special support'.
So the solution is just to not use long long division, which is OK for
me.
It would be just of interest for me how the code of the division can
alter the program in a way that:
+ everything still works
+ debug functionality is still fine
+ even the result of the long long division is OK
- the baudrate changes to baudrate X 4 (which is defined by the content
of a CPU-register, not by the translated code itself)
Any Ideas?
--
with best regards
Peter Seng
===========================
Peter Seng
eMail: info at seng.de
===========================
More information about the arm-gnu
mailing list