Incorrect result from assignment from a with loop
|Created on||Mar 16, 2009 19:45|
|Resolved on||Mar 18, 2009 20:29|
Created an attachment (id=506) Code to reproduce the bug. Run "sac2c -DB bughunt2.sac && ./a.out ; echo $?" and watch the result sac2c version 16013 Compile the code with -DB to see the with loop produce the wrong result and the program return 0. Compiler with -DA to see an equivalent for loop producing the correct result and the program return 1. Strangely -noINL and -noprelude both cause the bug to go away. I have removed all explicit inlining in the code and module imports now. By changing the defines at the top it should be clear that this bug does not depend on the size of the array above a certain size. Copy the body of the function call into the main function to get a compiler crash.
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information