[Bug c/66673] swapping variables via chained xor fails

2015-06-25 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66673 --- Comment #6 from Marek Polacek --- (In reply to joe.carnuccio from comment #2) > -Wall produces no warnings... Oh, you're using too old GCC. Please try a newer version.

[Bug c/66673] swapping variables via chained xor fails

2015-06-25 Thread trippels at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66673 --- Comment #5 from Markus Trippelsdorf --- https://www.google.com/?#q=nasal%20demons&lang=en

[Bug c/66673] swapping variables via chained xor fails

2015-06-25 Thread joe.carnuccio at qlogic dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66673 --- Comment #4 from joe.carnuccio at qlogic dot com --- if I do a ^= b ^= a ^= b it always work correctly; doing *p ^= *q ^= *p ^= *q fails (unless -Os is used); i.e. dereferenced pointers are being treated differently int a = 0x32, b = 0x45;

[Bug c/66673] swapping variables via chained xor fails

2015-06-25 Thread joe.carnuccio at qlogic dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66673 --- Comment #3 from joe.carnuccio at qlogic dot com --- Sorry, I ment this: root@elab305:/home/joe/test/c# make -B x CFLAGS+='-Wall' cc -Wall -c -o x.o x.c cc x.o -o x root@elab305:/home/joe/test/c# ./x 0 32

[Bug c/66673] swapping variables via chained xor fails

2015-06-25 Thread joe.carnuccio at qlogic dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66673 --- Comment #2 from joe.carnuccio at qlogic dot com --- -Wall produces no warnings... root@elab305:/home/joe/test/c# make -B x -Wall cc-c -o x.o x.c cc x.o -o x root@elab305:/home/joe/test/c# ./x 0 32

[Bug c/66673] swapping variables via chained xor fails

2015-06-25 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66673 Marek Polacek changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED CC|