Dale Johannesen
2aea794226
New test, see comments.
...
llvm-svn: 47078
2008-02-13 18:36:48 +00:00
Ted Kremenek
cd44b12f96
Fixed 80 col violations.
...
llvm-svn: 47076
2008-02-13 18:06:44 +00:00
Duncan Sands
f8d29f228d
Teach LegalizeTypes how to expand and promote CTLZ,
...
CTTZ and CTPOP. The expansion code differs from
that in LegalizeDAG in that it chooses to take the
CTLZ/CTTZ count from the Hi/Lo part depending on
whether the Hi/Lo value is zero, not on whether
CTLZ/CTTZ of Hi/Lo returned 32 (or whatever the
width of the type is) for it. I made this change
because the optimizers may well know that Hi/Lo
is zero and exploit it. The promotion code for
CTTZ also differs from that in LegalizeDAG: it
uses an "or" to get the right result when the
original value is zero, rather than using a compare
and select. This also means the value doesn't
need to be zero extended.
llvm-svn: 47075
2008-02-13 18:01:53 +00:00
Chris Lattner
7b7ace5537
avoid making implicit casts that just remove typedefs.
...
llvm-svn: 47074
2008-02-13 18:01:07 +00:00
Chris Lattner
419df4e066
gcc 3.2.3 is also bad.
...
llvm-svn: 47073
2008-02-13 17:50:24 +00:00
Ted Kremenek
755d39b233
Unbreak the build.
...
llvm-svn: 47072
2008-02-13 17:45:18 +00:00
Ted Kremenek
1c16527774
Renamed files to match class renaming in r47070:
...
http://llvm.org/viewvc/llvm-project?rev=47070&view=rev
llvm-svn: 47071
2008-02-13 17:43:07 +00:00
Ted Kremenek
f6c62f3459
Renamed class GREngine => GRCoreEngine.
...
Renamed class GRConstants => GRExprEngine.
This was done with a Perl script, and will result in 80 col. violations that
I will gradually fix up.
llvm-svn: 47070
2008-02-13 17:41:41 +00:00
Eli Friedman
2be9af9556
Fix a minor bug in isNullPointerConstant triggered by the linux
...
tgmath.h.
Note that there is another issue with tgmath.h, so mandel.c still
doesn't work.
llvm-svn: 47069
2008-02-13 17:29:58 +00:00
Ted Kremenek
2bba901a36
Simplify GRIndirectGotoNodeBuilder.
...
llvm-svn: 47068
2008-02-13 17:27:37 +00:00
Chris Lattner
d973e836f1
Fix the PPC JIT regressions by encoding zeroreg as 0 for BLR.
...
llvm-svn: 47067
2008-02-13 17:24:14 +00:00
Chris Lattner
67b9ef7be8
remove some dead code.
...
llvm-svn: 47066
2008-02-13 17:18:26 +00:00
Devang Patel
f64f7fb1b6
Remove use of ltdl
...
llvm-svn: 47065
2008-02-13 17:11:39 +00:00
Ted Kremenek
632bcb82a7
Added GREngine support for "break" and "continue".
...
llvm-svn: 47064
2008-02-13 16:56:51 +00:00
Duncan Sands
235b26f225
Add notes on Ada compilers that can be used for
...
the build. Put all items that the user should
specify in bold. Make it a debug build.
llvm-svn: 47063
2008-02-13 16:46:10 +00:00
Wojciech Matyjewicz
0e411f653c
Fix typo. Thanks to Duncan for noticing.
...
llvm-svn: 47062
2008-02-13 12:21:32 +00:00
Wojciech Matyjewicz
35545fd84d
Add comments as per review feedback.
...
llvm-svn: 47061
2008-02-13 11:51:34 +00:00
Evan Cheng
587c66ed96
Some code clean up.
...
llvm-svn: 47060
2008-02-13 09:56:03 +00:00
Evan Cheng
87f1b39f2b
Simplify.
...
llvm-svn: 47059
2008-02-13 09:18:16 +00:00
Evan Cheng
dc3f3841fc
Simplify.
...
llvm-svn: 47058
2008-02-13 09:13:21 +00:00
Evan Cheng
bb4b97f90e
Fix a potential serious problem where kills belonging to the val# defined by a two-address instruction is also on the val# that defines the input.
...
llvm-svn: 47057
2008-02-13 09:06:18 +00:00
Evan Cheng
8cc58728a8
* Cannot safely commute an instruction there are other defs which can reach its uses.
...
* Ignore copy instructions which have already been coalesced.
llvm-svn: 47056
2008-02-13 08:41:08 +00:00
Eli Friedman
460648abde
Add a note pointing to PR1996.
...
llvm-svn: 47055
2008-02-13 07:56:04 +00:00
Chris Lattner
a08af08a88
In SDISel, for targets that support FORMAL_ARGUMENTS nodes, lower this
...
node as soon as we create it in SDISel. Previously we would lower it in
legalize. The problem with this is that it only exposes the argument
loads implied by FORMAL_ARGUMENTs after legalize, so that only dag combine 2
can hack on them. This causes us to miss some optimizations because
datatype expansion also happens here.
Exposing the loads early allows us to do optimizations on them. For example
we now compile arg-cast.ll to:
_foo:
movl $2147483647, %eax
andl 8(%esp), %eax
ret
where we previously produced:
_foo:
subl $12, %esp
movsd 16(%esp), %xmm0
movsd %xmm0, (%esp)
movl $2147483647, %eax
andl 4(%esp), %eax
addl $12, %esp
ret
It might also make sense to do this for ISD::CALL nodes, which have implicit
stores on many targets.
llvm-svn: 47054
2008-02-13 07:39:09 +00:00
Chris Lattner
f6518cf4ab
don't try to avoid inserting loads when lowering FORMAL_ARGUMENTS.
...
DAGCombine is now quite good at zapifying them.
llvm-svn: 47053
2008-02-13 07:35:30 +00:00
Chris Lattner
ee322b44a4
teach dag combiner how to eliminate MERGE_VALUES nodes.
...
llvm-svn: 47052
2008-02-13 07:25:05 +00:00
Nate Begeman
eea32990a9
readme updates
...
llvm-svn: 47051
2008-02-13 07:06:12 +00:00
Eli Friedman
03ec63f29d
Add test for PR1996. (This is my first time adding a test for a
...
transform, so please review.)
llvm-svn: 47050
2008-02-13 06:55:57 +00:00
Nate Begeman
fe61967361
Add testcase for recent legalizer change
...
llvm-svn: 47049
2008-02-13 06:48:40 +00:00
Nate Begeman
735ab3ce67
Support legalizing insert_vector_elt on targets where the element
...
type is not legal.
llvm-svn: 47048
2008-02-13 06:43:04 +00:00
Evan Cheng
ea8530d82c
New tests.
...
llvm-svn: 47047
2008-02-13 03:23:53 +00:00
Evan Cheng
1446726f3e
Initial support for copy elimination by commuting its definition MI.
...
PR1877.
A3 = op A2 B0<kill>
...
B1 = A3 <- this copy
...
= op A3 <- more uses
==>
B2 = op B0 A2<kill>
...
B1 = B2 <- now an identify copy
...
= op B2 <- more uses
This speeds up FreeBench/neural by 29%, Olden/bh by 12%, oopack_v1p8 by 53%.
llvm-svn: 47046
2008-02-13 03:01:43 +00:00
Nate Begeman
87abe955fc
Make register scavenging happy by not using a reg (CR0) that isn't defined
...
llvm-svn: 47045
2008-02-13 02:58:33 +00:00
Evan Cheng
47f462a7ec
- Added removeValNo() to remove all live ranges of a particular value#.
...
- removeRange() can now update value# information.
llvm-svn: 47044
2008-02-13 02:48:26 +00:00
Evan Cheng
244183ef0d
commuteInstr() can now commute non-ssa machine instrs.
...
llvm-svn: 47043
2008-02-13 02:46:49 +00:00
Evan Cheng
61732d994e
Added debugging routine dumpUses.
...
llvm-svn: 47042
2008-02-13 02:45:38 +00:00
Anders Carlsson
73cc507602
Use IgnoreParenCasts.
...
llvm-svn: 47041
2008-02-13 01:22:59 +00:00
Chris Lattner
f26609686f
Move IgnoreParenCasts to be a method on Expr.
...
llvm-svn: 47040
2008-02-13 01:02:39 +00:00
Dan Gohman
f990faf23b
Convert SelectionDAG::ComputeMaskedBits to use APInt instead of uint64_t.
...
Add an overload that supports the uint64_t interface for use by clients
that haven't been updated yet.
llvm-svn: 47039
2008-02-13 00:35:47 +00:00
Ted Kremenek
7022efbe7b
Added support to GREngine/GRConstants for handling computed gotos.
...
llvm-svn: 47038
2008-02-13 00:24:44 +00:00
Dale Johannesen
ffde4ff5b1
__DATA not __DATA__ is the right segment name on darwin.
...
Spotted by Nick Kledzik.
llvm-svn: 47037
2008-02-12 23:35:09 +00:00
Nate Begeman
bcc182f50d
Remove some dead code
...
llvm-svn: 47036
2008-02-12 22:54:40 +00:00
Nate Begeman
8ef50214f0
SSE4.1 64b integer insert/extract pattern support
...
Move formats into the formats file
llvm-svn: 47035
2008-02-12 22:51:28 +00:00
Ted Kremenek
822f7370b2
Added GREngine support for GotoStmt.
...
llvm-svn: 47034
2008-02-12 21:51:20 +00:00
Dan Gohman
922096cc5e
Adjust for the API change to APInt::getBitsSet.
...
People more familiar with clang than me, please review this.
llvm-svn: 47033
2008-02-12 21:49:34 +00:00
Dan Gohman
5b3dffefa2
Change APInt::getBitsSet to accept a "half-open" range, where the
...
hiBit parameter marks the index one past the last desired set bit.
llvm-svn: 47032
2008-02-12 21:47:33 +00:00
Duncan Sands
481d4b27dd
Note that these instructions are for x86-32 linux
...
(the only platform on which the Ada compiler even
builds).
llvm-svn: 47031
2008-02-12 21:40:21 +00:00
Ted Kremenek
736e441266
Added transfer function/value track logic for taking the address of a label.
...
llvm-svn: 47030
2008-02-12 21:37:56 +00:00
Ted Kremenek
1f3d4a73f5
Minor (cosmetic) reshuffling of code. Fixed a bug in "Assume" logic when
...
handling Non-Lvalues of the type nonlval::SymbolVal; we were accidentally
casting them to lval::SymbolVal.
llvm-svn: 47029
2008-02-12 21:37:25 +00:00
Duncan Sands
2ae968abcb
Add more spacing.
...
llvm-svn: 47028
2008-02-12 21:28:39 +00:00