Obscure crashes due to gcc 4.9 -O2 => -fisolate-erroneous-paths-dereference
chrisj at rtems.org
Thu Feb 19 20:54:21 UTC 2015
On 19/02/2015 7:36 pm, Sebastian Huber wrote:
> On 19/02/15 00:52, Chris Johns wrote:
>> On 19/02/2015 7:25 am, Joel Sherrill wrote:
>>> Yep. But if all we have is writeable vector tables at 0x0, then it
>>> MIGHT be
>>> ok. GCC may not be able to detect. But on the m68k's without a VBR
>>> register the table is always at 0x0.
>> Yeap ...
>> I hit this one when testing on the mc5235.
> This is not a GCC bug. Read/write from/to the 0 address is undefined in
> C. I think the only reliable solution for these kind of operations is to
> write assembly code or do some tricks that may fail with newer GCC
> version or link-time optimization.
Yes. I found this out after I had a patch. The ticket details the path I
took to resolve the issue.
> See also:
Yes. This is difficult to resolve.
More information about the devel