[Bug rtl-optimization/70526] GCC 6 miscompiles Firefox JIT compiler

jakub at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Mon Apr 4 13:57:00 GMT 2016


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70526

--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
This changed with r223126.
The *.optimized dump is the same between r223124 and r223126, but already there
we can see that SRA used the TypedOrValueRegister type for the read:
  MEM[(struct  &)&D.2403] ={v} {CLOBBER};
  _2 = TypedOrValueRegister::dataTyped (&D.2403);
  MEM[(struct Register *)_2] = 10;
  SR.8_7 = MEM[(struct TypedOrValueRegister *)&D.2403];
  D.2403 ={v} {CLOBBER};
  if (SR.8_7 != 10)
and then the scheduler swaps the store of 10 with the load from the memory.
I'd say this testcase is invalid, but with placement new it would not be
invalid, the question is if it would still misbehave then.


More information about the Gcc-bugs mailing list