Commit Graph

51470 Commits

Author SHA1 Message Date
Chris Lattner
ef6b2c05fd simplify this by using SmallString::str(), much nicer!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80874 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-03 03:54:02 +00:00
Lang Hames
3f2f3f5341 Fixed a test that ensures the LocalRewriter does not attempt to
avoid reloads by reusing clobbered registers.

This was causing issues in 256.bzip2 when compiled with PIC for
a while (starting at r78217), though the problem has since been masked. 



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80872 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-03 02:52:02 +00:00
Gabor Greif
03a5f139fb back out my recent commit (r80858), it seems to break self-hosting buildbot's stage 2 configure
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80871 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-03 02:02:59 +00:00
Devang Patel
5f4ac848d9 Now Bitcode reader bug is fixed. Reapply 80839.
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.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80868 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-03 01:39:20 +00:00
Devang Patel
c0ff8c85dc Add new value for given index in MDValuePtrs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80867 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-03 01:38:02 +00:00
Daniel Dunbar
7096395d02 Improve llvm::getHostTriple for some cases where the LLVM_HOSTTRIPLE is not
reliable.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80863 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-03 01:10:13 +00:00
Gabor Greif
190390b8d3 re-commit r66920 (which has been backed out in r66953) I may have more luck this time. I'll back out if needed...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80858 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-03 00:18:58 +00:00
Sean Callanan
9947bbb297 Added opaque 32-, 48-, and 80-bit memory operand types to the X86
instruction tables to support segmented addressing (and other objects
of obscure type).
Modified the X86 assembly printers to handle these new operand types.
Added JMP and CALL instructions that use segmented addresses.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80857 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-03 00:04:47 +00:00
Daniel Dunbar
6552478ee7 Show derived host triple in --version.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80855 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 23:52:38 +00:00
Shantonu Sen
5e869c353c Improve support for cross-hosted builds of LLVM.
--build=triple and other configure options are passed
to the BuildTools/ sub-invocation more consistently


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80854 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 23:52:23 +00:00
Douglas Gregor
05bb5261d8 Unbreak my CMake build. Say you'll link again.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80842 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 22:45:31 +00:00
Devang Patel
8fc5576413 Revert 80839 for now. It causes test failures.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80841 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 21:49:26 +00:00
Devang Patel
d9489cbb0c 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.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80839 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 21:22:09 +00:00
Anton Korobeynikov
69d1c1aebf More missed vdup patterns
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80838 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 21:21:28 +00:00
Dan Gohman
778b06bbce Switch llc from ParseBitcodeFile to ParseIRFile. This lets llc
transparently read either LLVM Assembly or LLVM Bitcode files.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80829 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 19:35:19 +00:00
Dan Gohman
5c4e17c5ec Add a comment noting the memory ownership rules.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80827 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 19:21:56 +00:00
Dan Gohman
87750fcfc8 Add convenience functions for reading in LLVM IR that autodetect
and LLVM Assembly and LLVM Bitcode and automatically call the
corresponding reader.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80809 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 17:54:06 +00:00
Chris Lattner
3bd52827bd switch from std::string to SmallString + raw_svector_ostream.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80807 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 17:37:38 +00:00
Chris Lattner
522e9a0435 split mcinst lowering stuff out to its own file.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80806 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 17:35:12 +00:00
Dan Gohman
fdfca79de0 Fix the syntax of add/sub/mul nsw/nuw and sdiv exact.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80805 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 17:31:42 +00:00
Dan Gohman
c2ac2d5347 Add const qualifiers for isBitcodeWrapper, and add new functions
isRawBitcode and isBitcode to allow clients to test whether a given
memory buffer holds a bitcode image.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80804 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 17:21:29 +00:00
Dan Gohman
2ec5fe524c Refactor common code from ParseAssemblyString and ParseAssemblyFile,
to expose a low-level interface for parsing from an existing MemoryBuffer.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80803 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 17:18:19 +00:00
Dan Gohman
3445d9a72a Add const qualifiers to dominates' arguments.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80801 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 17:05:05 +00:00
Andreas Neustifter
ca172ae477 Removed temporarily because of breaking Darwin builds.
(See http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20090831/086214.html)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80799 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 16:47:24 +00:00
Bob Wilson
d163917fd8 Rearrange code to eliminate redundancy and avoid gotos.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80798 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 16:35:35 +00:00
Nuno Lopes
2b4f28e270 plug another leak in LLParser::PerFunctionState::SetInstName()
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80792 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 15:02:57 +00:00
Andreas Neustifter
793d4a8467 Changed profiling-tool-chain.ll test to use optimal-edge-profiling instead of
edge-profiling, this is more useful since the loading of the
optimal-edge-profiling is more complicated.
The edge-profiling is tested in edge-profiling.ll where only the
instrumentation is tested.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80791 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 14:24:08 +00:00
Nuno Lopes
531552aaa2 plug memory leak in LLParser::PerFunctionState::SetInstName() by deleting a value after replacing it
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80790 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 14:22:03 +00:00
Andreas Neustifter
2252d481d6 Sort edges in MaximumSpanningTree more stable in case of equal weight.
(See http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20090824/085890.html)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80789 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 14:03:11 +00:00
Andreas Neustifter
8f123b85c6 Changed set of BlocksToInstrument to set of InsertedBlocks that do not have to
be instrumented.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80788 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 13:59:05 +00:00
Andreas Neustifter
9341cdc217 Code cleanups and added comments.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80781 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 12:38:39 +00:00
Torok Edwin
254bb831d8 Opaque types didn't work if llvm_is_multithreaded().
AlwaysOpaqueTy is always NULL at this point, and it causes an assertion failure.
Fix it by using the just constructed tmp instead.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80780 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 12:23:05 +00:00
Nuno Lopes
f11e88337f set svn:ignore
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80779 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 11:58:01 +00:00
Torok Edwin
148843b0ce Fix DbgStopPointInst->getFileName/getDirectory, broken by the MDNodification in
r80406, and readd a -print-dbginfo test.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80778 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 11:13:56 +00:00
Sandeep Patel
65c3c8f323 Retype from unsigned to CallingConv::ID accordingly. Approved by Bob Wilson.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80773 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 08:44:58 +00:00
Chris Lattner
25f1992cf5 Fix month.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80769 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 06:34:22 +00:00
Chris Lattner
40ef630a46 fix PR4815: some cases where DeleteDeadInstruction can delete
the instruction BBI points to.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80768 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 06:31:02 +00:00
Chris Lattner
20a2faa980 clean up this code a bit.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80767 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 06:15:37 +00:00
Chris Lattner
3e8b6631e6 eliminate VISIBILITY_HIDDEN from Transforms/Scalar. PR4861
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80766 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 06:11:42 +00:00
Chris Lattner
5260097283 refactor select 'sched insertion' out to its own method.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80764 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 05:57:00 +00:00
Chris Lattner
700841617a Add support for modeling whether or not the processor has support for
conditional moves as a subtarget feature.  This is the easy part of 
PR4841.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80763 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 05:53:04 +00:00
Chris Lattner
f19f9347b8 fix PR4848 an infinite loop when indexing down through a recursive gep
and we get the original pointer type.  This doesn't mean that we're
at the first pointer being indexed.  Correct the predicate.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80762 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 05:35:45 +00:00
Chris Lattner
9e17b632ec fix PR4837, some bugs folding vector compares. These
return a vector of i1, not i1 itself.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80761 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 05:12:37 +00:00
Chris Lattner
d3bd0821b0 revert my patch, duncan points out what is wrong with my logic. Add
a comment so that I don't change this in the future :)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80760 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 04:39:04 +00:00
Chris Lattner
b8bcbd61a8 one more try at making this simpler, hopefully it won't break everything :)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80759 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 04:34:06 +00:00
Duncan Sands
b3020d7a08 Complicate Chris's simplification, avoiding complaints
about singular iterators when building with expensive
checks turned on.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80757 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 03:48:41 +00:00
Daniel Dunbar
545898183e Don't force the triple or data layout in this test. We just have to get them
from the host and hope that works.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80751 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 02:43:11 +00:00
Dan Gohman
dc404a23ca Add a comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80749 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 01:14:16 +00:00
Sean Callanan
a09caa56d6 Fixed the asmstrings for 8-bit, 16-bit, and 32-bit ADD %rAX, imm instructions.
Added a 64-bit ADD %RAX, imm32 instruction.
Added all 4 forms for AND %rAX, imm and CMP %rAX, imm.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80746 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 00:55:49 +00:00
Evan Cheng
94f07d8137 Fix PR4845: r77946 completely broke x86_64 Darwin (or any situation where the
desired triplet is a sub-target, e.g. thumbv7 vs. arm host). Reverting the
patch isn't quite right either since the previous behavior does not allow the
triplet to be overridden with -march.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@80742 91177308-0d34-0410-b5e6-96231b3b80d8
2009-09-02 00:19:03 +00:00