reassign 472554 erlang 1:12.b.1-dfsg-4
thanks

Actually, this is not a GCC bug, it is just that GCC 4.3 implements
some C99 rules correctly for the first time.  In C99, the strict
aliasing rules forbid casting (long) integers to pointers.  The Erlang
internal type "Eterm" is an unsigned long, which gets casted around
every two lines (hidden in macros).  The described segfault happens
because GCC sees no effect in the function ets_match_2() and replaces
it with a simple jmp to ets_select_2(), leaving the stack area
"pointed to" by the integer variable "ms" undefined.  This is correct
behaviour according to the C99 standard.

This gcc behaviour is triggered by "-ftree-pre -fstrict-aliasing"
(included in -O2 and -O3).

To work around this violation, we should compile with
"-fno-strict-aliasing".

Max



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to