[Bug tree-optimization/62006] Bad code generation with -O3 (possibly due to -ftree-partial-pre)

tkoeppe at google dot com gcc-bugzilla@gcc.gnu.org
Mon Aug 4 12:05:00 GMT 2014


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

--- Comment #4 from Thomas Köppe <tkoeppe at google dot com> ---
Ah, you're right, this offset pointer computation as it stands is undefined
behaviour. The intended use is to use those pointers only within a preallocated
arena, so that the pointers would indeed live in a common object (a large
array).

I shall change the allocator to an arena allocator and rerun the test.

The intended use for offset pointers is to inter-process communication; a
vector with the fancy-pointer allocator can be used from two separate
processes.


More information about the Gcc-bugs mailing list