]> git.ipfire.org Git - thirdparty/gcc.git/commit
PR tree-optimization/88775
authorjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 15 Jan 2019 08:11:00 +0000 (08:11 +0000)
committerjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 15 Jan 2019 08:11:00 +0000 (08:11 +0000)
commit15934f6ea532167eae1a48fe122a14f5f24a59dd
treeb8edaf2086c909d4288a6456d875c07bcd0e9202
parent5ce6daa3b3e129f0c356ef78d7e87108cce80e39
PR tree-optimization/88775
* match.pd (cmp (convert1?@2 addr@0) (convert2? addr@1)): Optimize
equal == 0 equality pointer comparisons some more if compared in
integral types and either one points to an automatic var and the
other to a global, or we can prove at least one points to the middle
or both point to start or both point to end.

* gcc.dg/tree-ssa/pr88775-1.c: New test.
* gcc.dg/tree-ssa/pr88775-2.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@267931 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ChangeLog
gcc/match.pd
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/tree-ssa/pr88775-1.c [new file with mode: 0644]
gcc/testsuite/gcc.dg/tree-ssa/pr88775-2.c [new file with mode: 0644]