This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

armcc [4.1 Build 894] generates bad code?

  • Note: This was originally posted on 5th February 2012 at http://forums.arm.com

    Thanks!! That seems to be what I was looking for! I tried to scan through compiler reference pdf, but I simply hate using pdf because of that clumsy adobe reader and wasn't patient enough to find this option.

    If I use profiler and if there is some sort of exception then it all breaks, any idea how to find that bad spot that triggers eception in profiler/emulator? If I use debugger then it work fine. Also, it seem that changing A and U bits doesn't work in profiler (Align and Unaligned access flags)
  • Note: This was originally posted on 5th February 2012 at http://forums.arm.com

    FYI, that option  --no_unaligned_access didn't help. I'm still getting millions of exceptions when running in emulator and I have no idea where they come from and how to find that offending part of code. What a crappy tool, insane...
  • Note: This was originally posted on 6th February 2012 at http://forums.arm.com


    FYI, that option  --no_unaligned_access didn't help. I'm still getting millions of exceptions when running in emulator and I have no idea where they come from and how to find that offending part of code. What a crappy tool, insane...


    Ok, after some time was wasted with RVDS profiler, it appears that the alignment issue was fixed with that -no-unaligned-access compiler switch. However, I still get millions of exceptions if I include handwritten asm code. I simply don't get it: is this rvds profiler a working product, or it's a pile of manoeuvre: if code is not good (supposedly, as it thinks) why the ###### it keeps running it and doesn't show what's wrong with that code...

    I hope I simply missed something, but I tried to click everywhere and I have no clue what's wrong with it, seems like it was designed with that flow

    https://www.google.com/search?hl=en&safe=off&client=firefox-a&hs=9Yv&rls=org.mozilla:en-US:official&sa=X&ei=FkcvT7zaHubh0QG1ram8Cg&ved=0CB4QvwUoAQ&q=pile+of+manoeuvre&spell=1
  • Note: This was originally posted on 4th February 2012 at http://forums.arm.com

    For ARMv6 and ARMv7 CPUs the compiler assumes unaligned access is allowed by default; for older cores it will assume no unaligned access by default.

    Try setting --no_unaligned_access