Re: [fpc-devel] Possible internal corruption

2018-06-29 Thread J. Gareth Moreton
So I've made a breakthrough. The memory corruption is due to both parts of the CMOV optimization under OptPass2Jcc, not my Jcc addition (although it might have unintentionally accentuated it). The first part sets p to a dangling pointer, while the 2nd part is a little more complicated, but I'll

Re: [fpc-devel] Possible internal corruption

2018-06-29 Thread J. Gareth Moreton
It turns out that it's invalid memory.  Trying to call "ClassName" raises an access violation (other aligns work fine).  There's a dangling pointer somewhere.  I found one in the CMOV optimisation code, but that hasn't fixed the crash. Gareth On Fri 29/06/18 10:27 , Martok

Re: [fpc-devel] Possible internal corruption

2018-06-29 Thread Martok
> A clue that leads me to believe there's internal corruption is that a produced > .s file yields an alignment field of ".balign 119,0x90", which should never > happen. Could you set a breakpoint on aggas.pas:721 (the call to doalign) with a conditional on "tai_align_abstract(hp).aligntype=119"