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

--- Comment #13 from Thomas Garnier <thgarnie at google dot com> ---
Created attachment 43223
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=43223&action=edit
testcase for switch folding

No switch folding if built with:

$CC -O2 -fno-PIE -c -o switch ./switch.c 

Switch folding if built with:

$CC -O2 -fPIE -c -o switch ./switch.c
or
$CC -O2 -fstatic-pie -c -o switch ./switch.c

Reply via email to