2013-10-21 Richard Biener <rguenther@suse.de>
commit6c9a67d3cccce07300e4da47d1c824d57a6eb41b
authorrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 21 Oct 2013 13:33:29 +0000 (21 13:33 +0000)
committerrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 21 Oct 2013 13:33:29 +0000 (21 13:33 +0000)
tree2c119af718c18fb0704fced88a9f1f6ccdffaab7
parentfc8edbaa7e7d39994a98fc3705ab43e4695ac79e
2013-10-21  Richard Biener  <rguenther@suse.de>

PR tree-optimization/58794
* fold-const.c (operand_equal_p): Compare FIELD_DECL operand
of COMPONENT_REFs with OEP_CONSTANT_ADDRESS_OF left in place.

* c-c++-common/torture/pr58794-1.c: New testcase.
* c-c++-common/torture/pr58794-2.c: Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@203891 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ChangeLog
gcc/fold-const.c
gcc/testsuite/ChangeLog
gcc/testsuite/c-c++-common/torture/pr58794-1.c [new file with mode: 0644]
gcc/testsuite/c-c++-common/torture/pr58794-2.c [new file with mode: 0644]