Commit Graph

61018 Commits

Author SHA1 Message Date
Eli Friedman 48021d15d6 Misc accumulated tweaks to legalization logic for various targets.
llvm-svn: 73476
2009-06-16 06:40:59 +00:00
Zhongxing Xu e531f048f8 Do not invalidate unboundable regions in GRSimpleVals::EvalCall().
llvm-svn: 73474
2009-06-16 06:18:21 +00:00
Chris Lattner 0101f45785 another xform that is target-independent (should be done in instcombine).
llvm-svn: 73472
2009-06-16 06:15:56 +00:00
Chris Lattner aba55a69b1 I think instcombine should unconditionally do this xform.
llvm-svn: 73471
2009-06-16 06:11:35 +00:00
Chris Lattner 06310bf178 Fix PR4336: Iterating over use-def chains doesn't seem to be deterministic.
The problem was that BitcodeReader::materializeModule would read functions
from the bc file in densemap pointer key order (doubly non-deterministic!),
which would cause the use-def chains to be set up for globals in
non-determinstic order.  Non-determinstic use/def chains can cause 
nondeterminism in many places down-stream.

Many thanks to Julien Lerouge for putting together the pass in the PR that
shows the issue!

llvm-svn: 73470
2009-06-16 05:15:21 +00:00
Bill Wendling 92b17b550e There doesn't seem to be a reason to move the save FP stuff.
llvm-svn: 73468
2009-06-16 04:12:45 +00:00
Bill Wendling f6c6a7f1b7 The DWARF to compact encoding converter assumes that the DW_CFA_def_cfa_offset
comes after the DW_CFA_def_cfa_register, because the CFA is really ESP from the
start of the function and only gets an offset when the "subl $xxx,%esp"
instruction happens, not the other way around.

And reapply r72898:

The DWARF unwind info was incorrect. While compiling with
`-fomit-frame-pointer', we would lack the DW_CFA_advance_loc information for a
lot of function, and then they would be `0'. The linker (at least on Darwin)
needs to encode the stack size. In some cases, the stack size is too large to
directly encode. So the linker checks to see if there is a "subl $xxx,%esp"
instruction at the point where the `DW_CFA_def_cfa_offset' says the pc was. If
so, the compact encoding records the offset in the function to where the stack
size is embedded. But because the `DW_CFA_advance_loc' instructions are missing,
it looks before the function and dies.

So, instead of emitting the EH debug label before the stack adjustment
operations, emit it afterwards, right before the frame move stuff.

llvm-svn: 73465
2009-06-16 04:06:15 +00:00
Bill Wendling 4a172428e5 Fix typos.
llvm-svn: 73464
2009-06-16 04:02:03 +00:00
Anders Carlsson a42ab8f3d5 Handle temporaries in default arguments.
llvm-svn: 73462
2009-06-16 03:37:31 +00:00
Devang Patel 14491abe48 Use MainCU if it is available.
llvm-svn: 73457
2009-06-16 02:09:30 +00:00
Owen Anderson f0ffb777d9 Add initial stab at documenting the use of LLVM with threaded clients.
Comments welcome!

llvm-svn: 73456
2009-06-16 01:17:16 +00:00
Dan Gohman 22d4cf60d8 Add comments to ConstantInt::get and ConstantFP::get to more fully
describe their behavior.

llvm-svn: 73454
2009-06-16 01:02:32 +00:00
Anders Carlsson 90036dc96a Keep track of whether a type parameter type is a parameter pack.
llvm-svn: 73452
2009-06-16 00:30:48 +00:00
Dan Gohman adfd42a3c8 Use Type::getScalarType.
llvm-svn: 73451
2009-06-16 00:20:26 +00:00
Steve Naroff 853308d89d Add a comment to Sema::ActOnTranslationUnitScope().
llvm-svn: 73450
2009-06-16 00:20:10 +00:00
Mikhail Glushenkov b4b44ea71c Regenerate.
llvm-svn: 73449
2009-06-16 00:14:20 +00:00
Mikhail Glushenkov bf5085251a Documentation update.
llvm-svn: 73448
2009-06-16 00:13:52 +00:00
Chris Lattner 49ffbb73ce accept and ignore -Wdiv-by-zero
llvm-svn: 73446
2009-06-15 23:45:43 +00:00
Owen Anderson 20fe9e6345 Remove extraneous propset.
llvm-svn: 73441
2009-06-15 23:12:00 +00:00
Owen Anderson e2432761f0 Owen Anderson 2009-06-15: Use a SmallPtrSet here, for speed and to match df_iterator.
Owen Anderson 2009-06-15: Remember to clear out our maps to prevent crashing.

llvm-svn: 73438
2009-06-15 22:54:48 +00:00
Dan Gohman 0274d32530 Add a CreateFNeg function to IRBuilder.
llvm-svn: 73437
2009-06-15 22:50:40 +00:00
Dan Gohman 8e85118943 Update this test to use fmul instead of mul.
llvm-svn: 73436
2009-06-15 22:49:34 +00:00
Dan Gohman 6e6808adaf Change this from an assert to a cerr+exit, since it's diagnosing an
unsupported inline asm construct, rather than verifying a code invariant.

llvm-svn: 73435
2009-06-15 22:32:41 +00:00
Evan Cheng f691b829ab On Darwin, frame pointer r7 is never available.
llvm-svn: 73434
2009-06-15 22:32:01 +00:00
Dan Gohman 7889f2b5e2 Use Type::isIntOrIntVector and Type::isFPOrFPVector.
llvm-svn: 73433
2009-06-15 22:25:12 +00:00
Dan Gohman 7ccc52f131 Support vector casts in more places, fixing a variety of assertion
failures.

To support this, add some utility functions to Type to help support
vector/scalar-independent code. Change ConstantInt::get and
ConstantFP::get to support vector types, and add an overload to
ConstantInt::get that uses a static IntegerType type, for
convenience.

Introduce a new getConstant method for ScalarEvolution, to simplify
common use cases.

llvm-svn: 73431
2009-06-15 22:12:54 +00:00
Anton Korobeynikov eb68408a5a Address more comments :)
llvm-svn: 73430
2009-06-15 22:08:48 +00:00
Dan Gohman 0b5d042562 Fix a typo in a diagnostic.
llvm-svn: 73429
2009-06-15 21:52:11 +00:00
Anton Korobeynikov 409105fc95 Rename methods for the sake of consistency.
llvm-svn: 73428
2009-06-15 21:46:20 +00:00
Anton Korobeynikov 6aba5c6fae Document ABIType enum. Patch by Sandeep Patel!
llvm-svn: 73427
2009-06-15 21:46:02 +00:00
Devang Patel 56e6fe1642 Gracefully handle imbalanced inline function begin and end markers.
llvm-svn: 73426
2009-06-15 21:45:50 +00:00
Evan Cheng b9bff5880a ifcvt should ignore cfg where true and false successors are the same.
llvm-svn: 73423
2009-06-15 21:24:34 +00:00
Evan Cheng ad0dba582f Typo.
llvm-svn: 73422
2009-06-15 21:18:20 +00:00
Dan Gohman 405cf6c282 Rewrite the noredzone description, attempting to avoid confusing language.
llvm-svn: 73421
2009-06-15 21:18:01 +00:00
Bill Wendling 2dadb42dd0 The Ls and Qs were mixed up. Patch by Sean.
llvm-svn: 73417
2009-06-15 20:59:31 +00:00
Dale Johannesen 9df78ee1ae Fix the crash in this test. This is basically the same
problem addressed in 31284, but the patch there only
addressed the case where an invoke is the first thing in
a block.

llvm-svn: 73416
2009-06-15 20:59:27 +00:00
Ted Kremenek 96aa146d90 Fix: <rdar://problem/6945561> -[CIContext createCGLayerWithSize:info:] misinterpreted by clang scan-build
llvm-svn: 73415
2009-06-15 20:58:58 +00:00
Evan Cheng eba57e41b3 Do not form ldrd / strd if the two dests / srcs are the same. Code clean up.
llvm-svn: 73413
2009-06-15 20:54:56 +00:00
Owen Anderson bd6a213725 Merge PartialInliner changes.
llvm-svn: 73412
2009-06-15 20:50:26 +00:00
Ted Kremenek 3092e9c5c2 Fix: <rdar://problem/6961230> add knowledge of IOKit functions to retain/release checker
llvm-svn: 73411
2009-06-15 20:36:07 +00:00
Douglas Gregor baafda8394 Tweak the C++ open projects page
llvm-svn: 73409
2009-06-15 19:53:21 +00:00
Eli Friedman dd2ab963de PR4395: Don't detect token concatenation in C mode for
C++-specific tokens.

llvm-svn: 73408
2009-06-15 19:48:50 +00:00
Bill Wendling e790614fa5 "The Intel instruction tables should include the 64-bit and 32-bit instructions
that push immediate operands of 1, 2, and 4 bytes (extended to the native
register size in each case).  The assembly mnemonics are "pushl" and "pushq."
One such instruction appears at the beginning of the "start" function , so this
is essential for accurate disassembly when unwinding."

Patch by Sean Callanan!

llvm-svn: 73407
2009-06-15 19:39:04 +00:00
Evan Cheng 1cf0f193b0 Silence a warning.
llvm-svn: 73406
2009-06-15 19:36:32 +00:00
Bill Wendling 20f0adfc0e This test is failing. Revert for now.
llvm-svn: 73404
2009-06-15 19:10:56 +00:00
Anders Carlsson ebf5be8db9 Include <limits>
llvm-svn: 73403
2009-06-15 19:08:31 +00:00
Douglas Gregor f39bf33dc0 More XML output support, from Olaf Krzikalla!
llvm-svn: 73402
2009-06-15 19:02:54 +00:00
Dan Gohman 19f8b0c3e0 Code cleanups. getSCEVAtScope no longer uses SCEVCouldNotCompute.
llvm-svn: 73401
2009-06-15 18:38:59 +00:00
Bill Wendling 66e104cd11 Add another testcase for r71478.
llvm-svn: 73399
2009-06-15 18:36:34 +00:00
Dan Gohman a8f8a85388 Make the EnableLoadPRE variable static.
llvm-svn: 73398
2009-06-15 18:30:15 +00:00