| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
| |
llvm-svn: 81862
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
instead of cloning and RAUWing it.
- Make AbstractTypeUser a friend of Value so that it can offer
its subclasses a way to update a Value's type in place. This
is better than a universally visible setType method on Value,
and it's sufficient for the immediate need.
- Eliminate the constant "convert" functions. This eliminates a
lot of logic duplication, and fixes a complicated bug where a
constant can't actually be cloned during the type refinement
process because some of the types that its folder needs are
half-destroyed, being in the middle of refinement themselves.
- Move the getValType functions from being static overloaded
functions in Constants.cpp to be members of class template
specializations in ConstantsContext.h. This means that the
code ends up getting instantiated twice, however it also
makes it possible to eliminate all "convert" functions, so
it's not a big net code size increase. And if desired, the
duplicate instantiations could be eliminated with some
reorganization.
llvm-svn: 81861
|
| |
|
|
|
|
|
|
|
|
| |
While I'm there, change code that does:
SomeTy == Type::getFooType(Context)
into:
SomeTy->getTypeID() == FooTyID
to decrease the amount of useless type creation which may involve locking, etc.
llvm-svn: 81846
|
| |
|
|
|
|
| |
an unpacked one.
llvm-svn: 81845
|
| |
|
|
|
|
| |
are in the SCC for each execution of a CGSCC pass.
llvm-svn: 81838
|
| |
|
|
| |
llvm-svn: 81836
|
| |
|
|
| |
llvm-svn: 81750
|
| |
|
|
|
|
| |
been told that the type is no longer abstract.
llvm-svn: 81749
|
| |
|
|
| |
llvm-svn: 81736
|
| |
|
|
|
|
|
| |
Also break the type verification stuff into its own TypeSet to keep the
Verifier pass from becoming an AbstractTypeUser.
llvm-svn: 81729
|
| |
|
|
|
|
|
|
| |
change as types are refined. Remove abstract types from CheckedTypes when they
we're informed that they have been refined. The only way types get refined in
the verifier is when later function passes start optimizing. Fixes PR4970.
llvm-svn: 81716
|
| |
|
|
|
|
| |
for systems that don't support quoting (PR4966).
llvm-svn: 81682
|
| |
|
|
|
|
| |
recompute it.
llvm-svn: 81634
|
| |
|
|
| |
llvm-svn: 81633
|
| |
|
|
| |
llvm-svn: 81580
|
| |
|
|
| |
llvm-svn: 81530
|
| |
|
|
| |
llvm-svn: 81506
|
| |
|
|
|
|
|
|
| |
(uniqued if unnamed) global variable name with the prefix that
it is supposed to get. It doesn't do "mangling" in the sense of
adding quotes and hacking on bad characters.
llvm-svn: 81505
|
| |
|
|
| |
llvm-svn: 81484
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
how to fold notionally-out-of-bounds array getelementptr indices instead
of just doing these in lib/Analysis/ConstantFolding.cpp, because it can
be done in a fairly general way without TargetData, and because not all
constants are visited by lib/Analysis/ConstantFolding.cpp. This enables
more constant folding.
Also, set the "inbounds" flag when the getelementptr indices are
one-past-the-end.
llvm-svn: 81483
|
| |
|
|
|
|
|
|
|
| |
within the notional bounds of the static type of the getelementptr (which
is not the same as "inbounds") from GlobalOpt into a utility routine,
and use it in ConstantFold.cpp to check whether there are any mis-behaved
indices.
llvm-svn: 81478
|
| |
|
|
| |
llvm-svn: 81468
|
| |
|
|
| |
llvm-svn: 81443
|
| |
|
|
| |
llvm-svn: 81426
|
| |
|
|
| |
llvm-svn: 81356
|
| |
|
|
| |
llvm-svn: 81355
|
| |
|
|
| |
llvm-svn: 81353
|
| |
|
|
| |
llvm-svn: 81235
|
| |
|
|
|
|
| |
performance.
llvm-svn: 81193
|
| |
|
|
|
|
|
|
|
| |
so "Assert1(isa<>); cast<>" is a valid idiom.
Actually check the PHI node's odd-numbered operands for BasicBlock-ness, like
the comment said.
llvm-svn: 81182
|
| |
|
|
|
|
|
| |
Make the verifier more robust by avoiding unprotected cast<> calls. Notably,
Assert1(isa<>); cast<> is not safe as Assert1 does not terminate the program.
llvm-svn: 81179
|
| |
|
|
| |
llvm-svn: 81172
|
| |
|
|
| |
llvm-svn: 81157
|
| |
|
|
| |
llvm-svn: 81156
|
| |
|
|
|
|
| |
- Hopefully this unbreaks some llvm-gcc bootstraps.
llvm-svn: 81141
|
| |
|
|
|
|
| |
Patch by Erick Tryzelaar.
llvm-svn: 81107
|
| |
|
|
|
|
| |
icc (#177, partial). Patch by Erick Tryzelaar.
llvm-svn: 81106
|
| |
|
|
|
|
| |
breaks MiniSAT on x86_64.
llvm-svn: 81098
|
| |
|
|
|
|
| |
MDNode's operand list does not include all elements.
llvm-svn: 81045
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Constant uniquing tables. This allows distinct ConstantExpr objects
with the same operation and different flags.
Even though a ConstantExpr "a + b" is either always overflowing or
never overflowing (due to being a ConstantExpr), it's still necessary
to be able to represent it both with and without overflow flags at
the same time within the IR, because the safety of the flag may
depend on the context of the use. If the constant really does overflow,
it wouldn't ever be safe to use with the flag set, however the use
may be in code that is never actually executed.
This also makes it possible to merge all the flags tests into a single test.
llvm-svn: 80998
|
| |
|
|
|
|
| |
introduced regressions in the Ocaml bindings tests.
llvm-svn: 80969
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
and exact flags. Because ConstantExprs are uniqued, creating an
expression with this flag causes all expressions with the same operands
to have the same flag, which may not be safe. Add, sub, mul, and sdiv
ConstantExprs are usually folded anyway, so the main interesting flag
here is inbounds, and the constant folder already knows how to set the
inbounds flag automatically in most cases, so there isn't an urgent need
for the API support.
This can be reconsidered in the future, but for now just removing these
API bits eliminates a source of potential trouble with little downside.
llvm-svn: 80959
|
| |
|
|
| |
llvm-svn: 80928
|
| |
|
|
|
|
|
|
| |
instead of a bool argument, and to do the dominator check itself.
This makes it eaiser to use when DominatorTree information is
available.
llvm-svn: 80920
|
| |
|
|
|
|
| |
buildbot's stage 2 configure
llvm-svn: 80871
|
| |
|
|
|
|
|
|
| |
Use CallbackVH, instead of WeakVH, to hold MDNode elements.
Use FoldingSetNode to unique MDNodes in a context.
Use CallbackVH hooks to update context's MDNodeSet appropriately.
llvm-svn: 80868
|
| |
|
|
|
|
| |
this time. I'll back out if needed...
llvm-svn: 80858
|
| |
|
|
| |
llvm-svn: 80841
|
| |
|
|
|
|
|
| |
Use FoldingSetNode to unique MDNodes in a context.
Use CallbackVH hooks to update context's MDNodeSet appropriately.
llvm-svn: 80839
|
| |
|
|
|
|
|
| |
AlwaysOpaqueTy is always NULL at this point, and it causes an assertion failure.
Fix it by using the just constructed tmp instead.
llvm-svn: 80780
|