• David 'Digit' Turner's avatar
    Allow dalvik pre-optimization to run in ARMv7 emulator. · ec628b5b
    David 'Digit' Turner authored
    This sad hack is used to allow the Dex preopt pass to run properly
    in ARMv7 emulation mode. Without it, the function dvmComputeWidths()
    aborts the VM in ways that are hard to properly understand.
    
    This issue has been discussed extensively with fadden, which provided
    the patch. It seems that adding both log lines fixes it, but only using
    one will not. I'm suspecting an emulation bug, or even worse, a C compiler
    bug that would generate invalid machine code.
    
    NOTE: The dex pre-optimization pass of user builds requires to run
          the DexOpt in the emulator for all -user builds. While this patch
          might not fix the underlying issue, it allows us to generate these
          images correctly (along with a few other system hacks).
    ec628b5b
InstrUtils.c 35.8 KB