Revert the addition of hasNoPointerOverflow to GEPOperator.
authorDan Gohman <gohman@apple.com>
Mon, 20 Jul 2009 17:43:30 +0000 (17:43 +0000)
committerDan Gohman <gohman@apple.com>
Mon, 20 Jul 2009 17:43:30 +0000 (17:43 +0000)
commitf2411744214dad8c71044aac2977ca77e9ebf028
treeab9b1cf7ba93de491166ef4b814f9b673ad8f2ae
parent8f4e22ff9a17b750fef179ed1572e9bfd01ed9a2
Revert the addition of hasNoPointerOverflow to GEPOperator.
Getelementptrs that are defined to wrap are virtually useless to
optimization, and getelementptrs that are undefined on any kind
of overflow are too restrictive -- it's difficult to ensure that
all intermediate addresses are within bounds. I'm going to take
a different approach.

Remove a few optimizations that depended on this flag.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76437 91177308-0d34-0410-b5e6-96231b3b80d8
12 files changed:
include/llvm/Operator.h
lib/Analysis/BasicAliasAnalysis.cpp
lib/Analysis/ScalarEvolution.cpp
lib/Transforms/Scalar/InstructionCombining.cpp
lib/VMCore/Constants.cpp
lib/VMCore/Instructions.cpp
lib/VMCore/Value.cpp
test/CodeGen/X86/iv-users-in-other-loops.ll
test/Transforms/IndVarSimplify/max-pointer.ll
test/Transforms/InstCombine/add2.ll
test/Transforms/InstCombine/add3.ll [new file with mode: 0644]
test/Transforms/InstCombine/cast_ptr.ll