https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100653
Bug ID: 100653 Summary: usage of scalar_storage_order produces incorrect result Product: gcc Version: 11.1.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: tree-optimization Assignee: unassigned at gcc dot gnu.org Reporter: jan.smets at nokia dot com Target Milestone: --- Created attachment 50840 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=50840&action=edit scalar_storage_order test case Attached test case produces invalid results with -O2, good with -O1. Known to fail : 11.1 10.3 9.3 8.5 7.5 Known to work: 6.5 Target: x86_64-linux-gnu $ gcc test.c -o /tmp/test -O2 -Wall -Wextra && /tmp/test a0a1e01 EQ? 11e0a0a 0 $ gcc test.c -o /tmp/test -O1 -Wall -Wextra && /tmp/test a0a1e01 EQ? a0a1e01 1 Thank you