Bob Wilson
b3e4773035
Rename file to have the correct suffix.
...
llvm-svn: 69380
2009-04-17 20:40:20 +00:00
Bob Wilson
911e92c7a3
Clean up formatting, remove trailing whitespace, fix comment typos and
...
punctuation. No functional changes.
llvm-svn: 69378
2009-04-17 20:35:10 +00:00
Dan Gohman
238dffed25
Delete an unused field.
...
llvm-svn: 69375
2009-04-17 20:03:31 +00:00
Bob Wilson
b8756b00cd
Use CallConvLower.h and TableGen descriptions of the calling conventions
...
for ARM. Patch by Sandeep Patel.
llvm-svn: 69371
2009-04-17 19:07:39 +00:00
Jim Grosbach
0603bca31b
Update information on canadian cross builds
...
llvm-svn: 69358
2009-04-17 17:25:16 +00:00
David Greene
d9756224ce
Use a safer iterator interface and get rid of std C++ library misuse.
...
This fixes a --enable-expensive-checks problem.
llvm-svn: 69353
2009-04-17 14:56:18 +00:00
David Greene
1e55a433c1
Regenerate configure.
...
llvm-svn: 69352
2009-04-17 14:50:39 +00:00
David Greene
ccb1d82cd7
Add a --enable-profiling option to configure to build Debug+Profile and
...
Opt+Profile tools. Now we can profile any kind of flavor we build.
llvm-svn: 69351
2009-04-17 14:49:22 +00:00
Rafael Espindola
d74132e2c5
For general dynamic TLS access we must use
...
leaq foo@TLSGD(%rip), %rdi
as part of the instruction sequence. Using a register other than %rdi and then
copying it to %rdi is not valid.
llvm-svn: 69350
2009-04-17 14:35:58 +00:00
Bill Wendling
073e1c91dd
Revert r69335 and r69336. They were causing build failures.
...
llvm-svn: 69347
2009-04-17 04:19:22 +00:00
Dan Gohman
61dc247292
Don't create ConstantInts with pointer type. This fixes a
...
regression in 403.gcc in PIC_CODEGEN=1 and DISABLE_LTO=1
mode.
llvm-svn: 69344
2009-04-17 02:02:52 +00:00
Evan Cheng
2d5be54315
Teach spiller to unfold instructions which modref spill slot when a scratch
...
register is available and when it's profitable.
e.g.
xorq %r12<kill>, %r13
addq %rax, -184(%rbp)
addq %r13, -184(%rbp)
==>
xorq %r12<kill>, %r13
movq -184(%rbp), %r12
addq %rax, %r12
addq %r13, %r12
movq %r12, -184(%rbp)
Two more instructions, but fewer memory accesses. It can also open up
opportunities for more optimizations.
llvm-svn: 69341
2009-04-17 01:29:40 +00:00
Dan Gohman
d254f36e54
MOV8rr_NOREX is a "Move" instruction. This doesn't currently
...
matter, because this instruction isn't generated until after
things that care.
llvm-svn: 69336
2009-04-17 00:45:17 +00:00
Dan Gohman
2349973ff3
Don't use MOV8rr_NOREX on x86-32. It doesn't actually hurt anything at
...
present, but it's inconsistent.
llvm-svn: 69335
2009-04-17 00:43:09 +00:00
Chris Lattner
d12470d85e
Fix some failures in targets on available_externally functions,
...
this fixes a crash on CodeGen/Generic/externally_available.ll
on ppc hosts. Thanks to Nicholas L for pointing this out.
llvm-svn: 69333
2009-04-17 00:26:12 +00:00
Dan Gohman
0b7e08929a
Use TargetData::getTypeSizeInBits instead of getPrimitiveSizeInBits()
...
to get the correct answer for pointer types.
llvm-svn: 69321
2009-04-16 22:35:57 +00:00
Bob Wilson
0e0d313fc0
Fix PR3994: LLVMMatchType arguments do not refer to absolute return value
...
and argument positions but only to the overloaded intrinsic parameters.
Keep a separate list of these overloaded parameters in CodeGenTarget.cpp
so they can be resolved easily. Remove assertions from IntrinsicEmitter.cpp:
they were harmless but confusing, and the assertions elsewhere in TableGen
will catch any incorrect values.
llvm-svn: 69316
2009-04-16 21:51:05 +00:00
Chris Lattner
1f5c81d50f
make sure to unlock keymgr if the JIT is created and destroyed, all
...
locks must be matched with unlocks. Also, use calloc to allocate the
block so that it is properly zero'd. Thanks to Nick Kledzik for
tracking this down.
llvm-svn: 69314
2009-04-16 21:47:59 +00:00
Bob Wilson
76f07543d9
Add a comment to describe LLVMMatchType.
...
llvm-svn: 69313
2009-04-16 21:46:42 +00:00
Eli Friedman
13e59b3c41
Fix for PR3944: make mem2reg O(N) instead of O(N^2) in the number of
...
incoming edges for a block with many predecessors.
llvm-svn: 69312
2009-04-16 21:40:28 +00:00
Dan Gohman
fa5d93b54c
Handle a pointer type correctly in SCEVExpander::visitAddRecExpr.
...
llvm-svn: 69310
2009-04-16 21:34:54 +00:00
Dan Gohman
397a4671f0
In the list-burr's pseudo two-addr dependency heuristics, don't
...
add dependencies on nodes with exactly one successor which is a
COPY_TO_REGCLASS node. In the case that the copy is coalesced
away, the dependence should be on the user of the copy, rather
than the copy itself.
llvm-svn: 69309
2009-04-16 20:59:02 +00:00
Dan Gohman
2165510df6
Handle SUBREG_TO_REG instructions with the same heuristics
...
as INSERT_SUBREG instructions in the list-burr scheduler.
llvm-svn: 69308
2009-04-16 20:57:10 +00:00
Dan Gohman
99b21e5635
Fix a bug with inttoptr/ptrtoint casts where the pointer has a different
...
size from the integer, requiring zero extension or truncation. Don't
create ZExtInsts with pointer types. This fixes a regression in
consumer-jpeg.
llvm-svn: 69307
2009-04-16 19:25:55 +00:00
Devang Patel
d324ddbd7b
Do not treat beginning of inlined scope as beginning of normal function scope if the location info is missing.
...
Insetad of doing ...
if (inlined_subroutine && known_location)
DW_TAG_inline_subroutine
else
DW_TAG_subprogram
do
if (inlined_subroutine) {
if (known_location)
DW_TAG_inline_subroutine
} else {
DW_TAG_subprogram
}
llvm-svn: 69300
2009-04-16 17:55:30 +00:00
Dan Gohman
f2bec6720f
Minor code simplifications. Don't attempt LSR on theoretical
...
targets with pointers larger than 64 bits, due to the code not
yet being APInt clean.
llvm-svn: 69296
2009-04-16 16:49:48 +00:00
Dan Gohman
67ad4ee457
LSR is no longer a GEP optimizer. It is now an IV expression
...
optimizer, which just happen to frequently involve optimizing GEPs.
llvm-svn: 69295
2009-04-16 16:46:01 +00:00
Dan Gohman
f7f9a14400
Fix SCEVExpander::visitSMaxExpr and SCEVExpander::visitUMaxExpr to
...
not create ICmpInsts with operands of different types. This fixes
a regression in Applications/d/make_dparser.
llvm-svn: 69294
2009-04-16 16:15:25 +00:00
Dan Gohman
1482541677
Teach SCEVExpander::InsertCastOfTo to avoid creating inttoptr-of-ptrtoint
...
and ptrtoint-of-inttoptr expressions. This fixes a regression in 300.twolf.
llvm-svn: 69293
2009-04-16 15:52:57 +00:00
Dan Gohman
b40c343360
Use ConstantExpr::getIntToPtr instead of SCEVExpander::InsertCastOfTo,
...
since the operand is always a constant.
llvm-svn: 69291
2009-04-16 15:48:38 +00:00
Dan Gohman
862f4743b8
Use a SCEV expression cast instead of immediately inserting a
...
new instruction with SCEVExpander::InsertCastOfTo.
llvm-svn: 69290
2009-04-16 15:47:35 +00:00
Devang Patel
6052d698f5
Record line number at the beginning of a func.start.
...
This line was accidently lost yesterday.
llvm-svn: 69286
2009-04-16 15:07:09 +00:00
Rafael Espindola
a07d1c3103
fix PR3995. A scale must be 1, 2, 4 or 8.
...
llvm-svn: 69284
2009-04-16 12:34:53 +00:00
Chris Lattner
1a7c8feff3
prove diagnostic -> group mapping information.
...
llvm-svn: 69270
2009-04-16 05:52:18 +00:00
Dan Gohman
98aa1d9693
Expand GEPs in ScalarEvolution expressions. SCEV expressions can now
...
have pointer types, though in contrast to C pointer types, SCEV
addition is never implicitly scaled. This not only eliminates the
need for special code like IndVars' EliminatePointerRecurrence
and LSR's own GEP expansion code, it also does a better job because
it lets the normal optimizations handle pointer expressions just
like integer expressions.
Also, since LLVM IR GEPs can't directly index into multi-dimensional
VLAs, moving the GEP analysis out of client code and into the SCEV
framework makes it easier for clients to handle multi-dimensional
VLAs the same way as other arrays.
Some existing regression tests show improved optimization.
test/CodeGen/ARM/2007-03-13-InstrSched.ll in particular improved to
the point where if-conversion started kicking in; I turned it off
for this test to preserve the intent of the test.
llvm-svn: 69258
2009-04-16 03:18:22 +00:00
Chris Lattner
3984f99025
encode subgroups into the clang .inc file. -Wall now works!
...
llvm-svn: 69257
2009-04-16 03:16:12 +00:00
Devang Patel
87488c2a88
In -fast mode do what FastISel does.
...
This code could use some refactoring help!
llvm-svn: 69254
2009-04-16 02:33:41 +00:00
Devang Patel
d9a9d5bdbb
If FastISel is run and it has known DebugLoc then use it.
...
llvm-svn: 69253
2009-04-16 01:33:10 +00:00
Devang Patel
c6c6759194
If location where the function was inlined is not know then do not emit debug info describing inlinied region.
...
llvm-svn: 69252
2009-04-16 01:31:54 +00:00
Chris Lattner
1d21ddd345
start producing subgroup info.
...
llvm-svn: 69249
2009-04-16 00:53:25 +00:00
Dale Johannesen
040d118b17
Another testcase for IV shortening.
...
llvm-svn: 69247
2009-04-16 00:45:21 +00:00
Dale Johannesen
ab8b46beca
Eliminate zext over (iv | const) or (signed iv),
...
and sext over (iv | const), if a longer iv is
available. Allow expressions to have more than
one zext/sext parent. All from OpenSSL.
llvm-svn: 69241
2009-04-15 23:31:51 +00:00
Chris Lattner
48fcc3fe58
make sure that empty diag groups get known by clang.
...
llvm-svn: 69235
2009-04-15 22:33:02 +00:00
Chris Lattner
265ef76440
implement support for writing out diagnostic group tables.
...
llvm-svn: 69219
2009-04-15 20:55:08 +00:00
Devang Patel
4a18de4193
s/RootDbgScope/FunctionDbgScope/g
...
llvm-svn: 69216
2009-04-15 20:41:31 +00:00
Dale Johannesen
98c9716c34
Eliminate zext over (iv & const) or ((iv+const)&const)
...
if a longer iv is available. These subscript forms are
not common; they're a bottleneck in OpenSSL.
llvm-svn: 69215
2009-04-15 20:41:02 +00:00
Chris Lattner
1a1ffcb4a4
use UppercaseString instead of EmitAllCaps
...
llvm-svn: 69213
2009-04-15 20:16:12 +00:00
Chris Lattner
3ab2b0ca2b
use escape string.
...
llvm-svn: 69212
2009-04-15 20:13:18 +00:00
Chris Lattner
b46ad5bbba
teach EscapeString and UnescapeString to handle ".
...
llvm-svn: 69211
2009-04-15 20:12:52 +00:00
Devang Patel
21463f4a25
Add DISubprogram is not null check.
...
This fixes test/CodeGen//2009-01-21-invalid-debug-info.m test case.
llvm-svn: 69210
2009-04-15 20:11:08 +00:00