Commit Graph

89246 Commits

Author SHA1 Message Date
Dan Gohman
819f9d6bf9 Add a comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174028 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 02:45:26 +00:00
Dan Gohman
de0eb19248 Move isKnownNonNull out of AliasAnalysis.h and into ValueTracking.cpp since
it isn't really an AliasAnalysis concept, and ValueTracking has similar things
that it could plausibly share code with some day.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174027 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 02:40:59 +00:00
Bill Wendling
85238aae1a Remove Attribute::hasAttributes() and make Attribute::hasAttribute() private.
The Attribute::hasAttributes() is kind of meaningless since an Attribute can
have only one attribute. And we would rather people use the 'operator=='
instead of Attribute::hasAttribute().

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174026 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 02:18:19 +00:00
Dan Gohman
a070d2a035 Change GetPointerBaseWithConstantOffset's DataLayout argument from a
reference to a pointer, so that it can handle the case where DataLayout
is not available and behave conservatively.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174024 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 02:00:45 +00:00
Bill Wendling
8ed701da9a Make the AttrBuilder creation method of Attribute private so that people won't use it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174023 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 01:51:27 +00:00
Saleem Abdulrasool
11486ffd5a build: @ENABLE_THREADS@ => @LLVM_ENABLE_THREADS@
Makefile.config does not have the value for ENABLE_THREADS substituted as the
variable is called LLVM_ENABLE_THREADS within configure.ac.  This was pointed
out by zygoloid over IRC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174021 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 01:34:59 +00:00
Daniel Dunbar
47896090f3 [lit] Move unittest adaptor code into discovery module.
- Also, add a test for it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174019 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 01:23:39 +00:00
Daniel Dunbar
c9fd0a57f7 [lit] Run the ShUtil tests as part of the test suite.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174018 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 01:23:26 +00:00
Daniel Dunbar
84d3c61c03 [lit] Set parallel mode for coverage tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174017 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 01:23:18 +00:00
Daniel Dunbar
3d4a973ee4 [lit] Move discovery code into its own module.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174014 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 01:14:01 +00:00
Bill Wendling
b96129dd48 Revert for now:
--- Reverse-merging r174010 into '.':
U    include/llvm/IR/Attributes.h
U    lib/IR/Verifier.cpp
U    lib/IR/Attributes.cpp



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174012 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 01:04:51 +00:00
Michael Gottesman
67dad63de6 Filecheckized 2x tests in SimplifyCFG and removed their date prefix to fit with current llvm style for test names.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174011 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 01:04:23 +00:00
Bill Wendling
c6077eff8b Remove the AttrBuilder version of the Attribute::get function.
The AttrBuilder is there to build up multiple attributes. The Attribute class
represents only one attribute at a time. So remove this unnecessary builder
creator method.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174010 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 00:53:21 +00:00
Eric Christopher
e187e25996 Whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174009 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 00:50:48 +00:00
Eric Christopher
a9bd4b4647 Check and allow floating point registers to select the size of the
register for inline asm. This conforms to how gcc allows for effective
casting of inputs into gprs (fprs is already handled).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174008 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 00:50:46 +00:00
Andrew Trick
946317d07b LangRef: Add a Rationale for volatile rules.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174007 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 00:49:39 +00:00
Eli Bendersky
2acfb179fc Replace some more greps with FileChecks in tests
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174006 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 00:44:12 +00:00
Dan Gohman
5f1686f0b0 Minor code simplification.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174005 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 00:32:11 +00:00
Bill Wendling
73dee180c8 Make sure that the Attribute object represents one attribute only.
Several places were still treating the Attribute object as respresenting
multiple attributes. Those places now use the AttributeSet to represent
multiple attributes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174003 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 00:29:54 +00:00
Daniel Dunbar
3f8195ea4f [lit] Add a MANIFEST file and a script for sanity checking the source dist.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174002 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 00:21:59 +00:00
Daniel Dunbar
ada2de95ac [lit] Add a basic discovery test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174001 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 00:21:51 +00:00
Daniel Dunbar
412d805841 [lit] Add a script for checking test coverage.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174000 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 00:21:44 +00:00
Daniel Dunbar
356dcac20e [lit] Add a test suite for lit itself.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173999 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 00:21:39 +00:00
Dan Gohman
f2335dcb17 stripAndComputeConstantOffsets is only called on pointers; check this
with an assert instead of failing and requiring callers to check for failure.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173998 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 00:12:20 +00:00
Eli Bendersky
ee1841cdda Rewrite this test properly with a FileCheck instead of greps
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173997 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 00:11:52 +00:00
Dan Gohman
d363ae5299 Fix ConstantFold's folding of icmp instructions to recognize that,
for example, a one-past-the-end pointer from one global variable may
be equal to the base pointer of another global variable.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173995 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-31 00:01:45 +00:00
Michael Gottesman
69f60e7c4a Added a unit test for r173983 that verifies that Target.isiOS() works correctly.
As a bonus I put in some extra checks to make sure that we are identifying the
machine word of various Mac OS X/iOS targets appropriately.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173994 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 23:48:13 +00:00
Hal Finkel
9a79b320cb PPC QPX requires a 32-byte aligned stack
On systems which support the QPX vector instructions, the stack must be
32-byte aligned.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173993 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 23:43:27 +00:00
Bill Wendling
ac72eb264c Remove addRetAttributes and addFnAttributes, which aren't useful abstractions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173992 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 23:40:31 +00:00
Bill Wendling
e74365462a Convert typeIncompatible to return an AttributeSet.
There are still places which treat the Attribute object as a collection of
attributes. I'm systematically removing them.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173990 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 23:07:40 +00:00
Evan Cheng
b25a645830 Forgot the test case before.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173988 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 22:57:00 +00:00
Evan Cheng
a66f40a8cc Restrict sin/cos optimization to 64-bit only for now. 32-bit is a bit messy and less critical.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173987 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 22:56:35 +00:00
Michael Gottesman
bc977bab42 Doxygenified some comments in IRBuilder.h.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173986 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 22:56:31 +00:00
Michael Gottesman
f84d4c16b3 Removed CreateFPExtOrFPTrunc for now until I have the time to get in my vector convert patch.
What I thought was going to be a quick thing has extended out a little bit in
time *sigh*. So after some thought in order to not cruft up the tree I am
removing this for now since it is the right thing to do.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173985 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 22:53:21 +00:00
Hal Finkel
f9cd7738a3 Initialize hasQPX in PPCSubtarget
This should have gone in with r173973.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173984 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 22:43:44 +00:00
Michael Gottesman
e502bba8c6 Encapsulate testing that we have an iOS Triple in Triple.h in the method isiOS
so we follow the convention that all other platforms follow by having an is*
test method.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173983 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 22:38:19 +00:00
Bill Wendling
383da6ba55 Remove redundant code.
It was creating a new AttrBuilder when we could just fill in the AttrBuilder
we're building.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173975 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 21:22:59 +00:00
Andrew Trick
9a6dd02261 ...in light of recent activity related to llvm.memcpy flags. I want to
prevent an llvm developer from mistakenly thinking that just because the
intrinsic has volatile flags that volatile operations can be converted
to or folded into them.

Platforms may rely on volatile loads and stores of natively supported
data width to be executed as single instruction. When compiling
C, this expectation likely holds for l-values of volatile primitive
types with native hardware support, but not necessarily for aggregate
types. The frontend upholds these expectations, which are not
specified in the IR.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173974 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 21:19:35 +00:00
Hal Finkel
5bb16fdbb3 Add definitions for the PPC a2q core marked as having QPX available
This is the first commit of a large series which will add support for the
QPX vector instruction set to the PowerPC backend. This instruction set is
used on the IBM Blue Gene/Q supercomputers.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173973 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 21:17:42 +00:00
Eli Bendersky
2f89e8144b Remove a mention of TargetInstrDescriptor, which no longer exists in the code
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173971 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 20:54:21 +00:00
Sean Silva
e70de1f462 [docs] Guide prospective TableGen backend writers.
Boilerplate is often the hardest part of getting started with these
kinds of things, so throw them a bone.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173969 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 20:39:46 +00:00
Bill Wendling
aa57893e84 Use the number of 'slots' in the AttributeSetImpl being 0 to indicate that the AttributeSet is empty.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173962 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 19:39:21 +00:00
Eli Bendersky
f578c89dc6 Clean up whitespace and indentation a bit
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173960 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 19:24:23 +00:00
Manman Ren
1229c0cb10 Linker: correctly link in dbg.declare
Given source IR:
call void @llvm.dbg.declare(metadata !{i32* %argc.addr}, metadata !14), !dbg !15
we used to generate 
call void @llvm.dbg.declare(metadata !27, metadata !28), !dbg !29
!27 = metadata !{null}

With this patch, we will correctly generate
call void @llvm.dbg.declare(metadata !{i32* %argc.addr}, metadata !27), !dbg !28

Looking up %argc.addr in ValueMap will return null, since %argc.addr is already
correctly set up, we can use identity mapping.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173946 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 17:42:15 +00:00
Eli Bendersky
0f156af831 Add a special ARM trap encoding for NaCl.
More details in this thread: http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20130128/163783.html

Patch by JF Bastien



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173943 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 16:30:19 +00:00
Logan Chien
620d5bd8e4 Add missing header and test cases for r173939.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173941 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 15:48:50 +00:00
Logan Chien
52b1b3bbc6 Override virtual function for ARM EH directives.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173939 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 15:39:04 +00:00
Dmitri Gribenko
f121b79a6a LLDB uses ConvertUTF16toUTF8, remove #ifdef
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173936 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 15:10:12 +00:00
Dmitri Gribenko
328027bf26 Move UTF conversion routines from clang/lib/Basic to llvm/lib/Support
This is required to use them in TableGen.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173923 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 12:05:05 +00:00
Patrik Hagglund
3b5f0b0e50 Documentation: Updating the data layout default specifications to
correspond to the code.

Patch by Stephen McGruer.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173914 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-30 09:02:06 +00:00