Nadav Rotem [Thu, 7 Feb 2013 22:34:07 +0000 (22:34 +0000)]
fix 80-col violation and fix the docs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174671
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Thu, 7 Feb 2013 21:34:34 +0000 (21:34 +0000)]
[lit] Add a display function for lit.Test.TestResult.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174667
91177308-0d34-0410-b5e6-
96231b3b80d8
Akira Hatanaka [Thu, 7 Feb 2013 21:32:32 +0000 (21:32 +0000)]
[mips] Make Filler a class and reduce indentation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174666
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Thu, 7 Feb 2013 21:19:56 +0000 (21:19 +0000)]
Formatting.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174664
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Thu, 7 Feb 2013 21:19:50 +0000 (21:19 +0000)]
"Clean up" line section symbol emission by emitting the section
syms before constructing the compile units so we're not emitting
section references to sections not there already.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174663
91177308-0d34-0410-b5e6-
96231b3b80d8
Will Schmidt [Thu, 7 Feb 2013 20:43:33 +0000 (20:43 +0000)]
[patch] bug 15055 Add Unistd.h to OProfileWrapper.cpp
Add #include <unistd.h> to OProfileWrapper.cpp. This provides the declarations for 'read' and 'close' that are otherwise missing, and result in 'error: <foo> was not declared in this scope'.
This matches the issue as reported in bug 15055 "Can no longer compile LLVM with --with-oprofile"
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174661
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Schmidt [Thu, 7 Feb 2013 20:33:57 +0000 (20:33 +0000)]
Constrain PowerPC autovectorization to fix bug 15041.
Certain vector operations don't vectorize well with the current
PowerPC implementation. Element insert/extract performs poorly
without VSX support because Altivec requires going through memory.
SREM, UREM, and VSELECT all produce bad scalar code.
There's a lot of work to do for the cost model before
autovectorization will be tuned well, and this is not an attempt to
address the larger problem.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174660
91177308-0d34-0410-b5e6-
96231b3b80d8
Akira Hatanaka [Thu, 7 Feb 2013 19:48:00 +0000 (19:48 +0000)]
[mips] Add definition of JALR instruction which has two register operands. Change the
original JALR instruction with one register operand to be a pseudo-instruction.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174657
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Thu, 7 Feb 2013 19:39:45 +0000 (19:39 +0000)]
R600/SI: cleanup VGPR encoding
Remove all the unused code.
Patch by: Christian König
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174656
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Thu, 7 Feb 2013 19:39:43 +0000 (19:39 +0000)]
R600/SI: Handle VGPR64 destination in copyPhysReg().
Allows nexuiz to run with radeonsi.
Patch by: Michel Dänzer
Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174655
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Thu, 7 Feb 2013 19:39:42 +0000 (19:39 +0000)]
R600/SI: Add pattern for mul.
20 more little piglits with radeonsi.
Patch by: Michel Dänzer
Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174654
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Thu, 7 Feb 2013 19:39:40 +0000 (19:39 +0000)]
R600/SI: simplify and fix SMRD encoding
The _SGPR variants where wrong.
Patch by: Christian König
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174653
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Thu, 7 Feb 2013 19:39:38 +0000 (19:39 +0000)]
R600/SI: add proper 64bit immediate support v2
v2: rebased on current upstream
Patch by: Christian König
Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174652
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Thu, 7 Feb 2013 19:39:34 +0000 (19:39 +0000)]
R600: Add an explicit default processor
This is for the case when no processor is passed to the backend. This
prevents the
'' is not a recognized processor for this target (ignoring processor)
warning from being generated by clang.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174651
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Ilseman [Thu, 7 Feb 2013 19:26:05 +0000 (19:26 +0000)]
Identify and simplify idempotent intrinsics. Test case included.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174650
91177308-0d34-0410-b5e6-
96231b3b80d8
Arnold Schwaighofer [Thu, 7 Feb 2013 19:05:21 +0000 (19:05 +0000)]
Loop Vectorizer: Refactor Memory Cost Computation
We don't want too many classes in a pass and the classes obscure the details. I
was going a little overboard with object modeling here. Replace classes by
generic code that handles both loads and stores.
No functionality change intended.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174646
91177308-0d34-0410-b5e6-
96231b3b80d8
Meador Inge [Thu, 7 Feb 2013 18:36:50 +0000 (18:36 +0000)]
ADT: Correct APInt::getActiveWords for zero values
PR15138 was opened because of a segfault in the Bitcode writer.
The actual issue ended up being a bug in APInt where calls to
APInt::getActiveWords returns a bogus value when the APInt value
is 0. This patch fixes the problem by ensuring that getActiveWords
returns 1 for 0 valued APInts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174641
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Thu, 7 Feb 2013 18:26:45 +0000 (18:26 +0000)]
[Object][ELF] Fix crash on no dynamic section.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174639
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Thu, 7 Feb 2013 17:02:14 +0000 (17:02 +0000)]
R600/SI: Use proper instructions for array/shadow samplers.
Patch by: Michel Dänzer
Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174634
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Thu, 7 Feb 2013 17:02:13 +0000 (17:02 +0000)]
R600/SI: Make sample intrinsic address parameter type overloaded.
Handle vectors of 1 to 16 integers.
Change the intrinsic names to prevent the wrong one from being selected at
runtime due to the overloading.
Patch By: Michel Dänzer
Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174633
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Thu, 7 Feb 2013 17:02:09 +0000 (17:02 +0000)]
R600/SI: Add basic support for more integer vector types.
v1i32, v2i32, v8i32 and v16i32.
Only add VGPR register classes for integer vector types, to avoid attempts
copying from VGPR to SGPR registers, which is not possible.
Patch By: Michel Dänzer
Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174632
91177308-0d34-0410-b5e6-
96231b3b80d8
Arnold Schwaighofer [Thu, 7 Feb 2013 16:10:15 +0000 (16:10 +0000)]
ARM cost model: Add costs for vector selects
Vector selects are cheap on NEON. They get lowered to a vbsl instruction.
radar://
13158753
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174631
91177308-0d34-0410-b5e6-
96231b3b80d8
Michel Danzer [Thu, 7 Feb 2013 14:55:16 +0000 (14:55 +0000)]
R600/SI: Add pattern for flog2
22 more little piglits with radeonsi.
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174615
91177308-0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Thu, 7 Feb 2013 14:54:42 +0000 (14:54 +0000)]
FDE::dumpHeader(): Forgot to fix one more formatting, ... take two!
Excuse me, I could not test it locally.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174614
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Thu, 7 Feb 2013 14:02:37 +0000 (14:02 +0000)]
R600: Consolidate sub register indices.
Use sub0-15 everywhere.
Patch by: Michel Dänzerr
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174610
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Thu, 7 Feb 2013 14:02:35 +0000 (14:02 +0000)]
R600: Add support for SET*_DX10 instructions
These instructions compare two floating point values and return an
integer true (-1) or false (0) value.
When compiling code generated by the Mesa GLSL frontend, the SET*_DX10
instructions save us four instructions for most branch decisions that
use floating-point comparisons.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174609
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Thu, 7 Feb 2013 14:02:33 +0000 (14:02 +0000)]
R600: Add tests for unsupported condition codes.
All of the le and lt variants are unsupported.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174608
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Thu, 7 Feb 2013 14:02:27 +0000 (14:02 +0000)]
R600: Fix assembly name for SETGT_INT
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174607
91177308-0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Thu, 7 Feb 2013 10:57:42 +0000 (10:57 +0000)]
FDE::dumpHeader(): Forgot to fix one more formatting. It affected bigendian hosts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174602
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Thu, 7 Feb 2013 07:01:54 +0000 (07:01 +0000)]
Remove this testcase until I can figure out how to properly conditionalize it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174591
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Thu, 7 Feb 2013 06:26:55 +0000 (06:26 +0000)]
Another attempt at getting the XFAIL line right for this test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174588
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Silva [Thu, 7 Feb 2013 05:56:46 +0000 (05:56 +0000)]
[ReleaseNotes] tidy up organization and formatting
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174587
91177308-0d34-0410-b5e6-
96231b3b80d8
Nadav Rotem [Thu, 7 Feb 2013 05:44:58 +0000 (05:44 +0000)]
Update Release notes regarding TTI.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174586
91177308-0d34-0410-b5e6-
96231b3b80d8
Nadav Rotem [Thu, 7 Feb 2013 05:42:31 +0000 (05:42 +0000)]
Document the loop vectorizer changes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174585
91177308-0d34-0410-b5e6-
96231b3b80d8
Reed Kotler [Thu, 7 Feb 2013 04:34:51 +0000 (04:34 +0000)]
Make sure we call externals from libraries properly when -static.
For example, when we are doing mips16 hard float or soft float.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174583
91177308-0d34-0410-b5e6-
96231b3b80d8
Sean Silva [Thu, 7 Feb 2013 04:30:39 +0000 (04:30 +0000)]
tblgen: Diagnose duplicate includes.
A double inclusion will pretty much always be an error in TableGen, so
there's no point going on just to die with "def already defined" or
whatnot.
I'm not too thrilled about the "public: ... private: ..." to expose the
DependenciesMapTy, but I really didn't see a better way to keep that
type centralized. It's a smell that indicates that some refactoring is
needed to make this code more loosely coupled.
This should avoid all bugs of the same nature as PR15189.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174582
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Gottesman [Thu, 7 Feb 2013 04:12:57 +0000 (04:12 +0000)]
Moved some comments due to the recent refactoring of ObjCARC.
1. Moved a comment from ObjCARCOpts.cpp -> ObjCARCContract.cpp.
2. Removed a comment from ObjCARCOpts.cpp that was already moved to
ObjCARCAliasAnalysis.h/.cpp.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174581
91177308-0d34-0410-b5e6-
96231b3b80d8
Reed Kotler [Thu, 7 Feb 2013 03:49:51 +0000 (03:49 +0000)]
Enable jumps when in -static mode.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174580
91177308-0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Thu, 7 Feb 2013 02:02:27 +0000 (02:02 +0000)]
DWARFDebugFrame.cpp: Fix formatting on i686 hosts.
FIXME: Are they really truncated to i32 from i64 unconditionally?
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174574
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Thu, 7 Feb 2013 01:43:18 +0000 (01:43 +0000)]
80-col
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174572
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Ilseman [Thu, 7 Feb 2013 01:40:15 +0000 (01:40 +0000)]
Preserve fast-math flags after reassociation and commutation. Update test cases
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174571
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Ilseman [Thu, 7 Feb 2013 01:27:13 +0000 (01:27 +0000)]
whitespace
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174569
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Thu, 7 Feb 2013 01:24:22 +0000 (01:24 +0000)]
[Object][ELF] Do the actual devirtualization.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174568
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Thu, 7 Feb 2013 01:17:23 +0000 (01:17 +0000)]
[Object][ELF] Devirtualize and simplify dynamic table iteration.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174566
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Thu, 7 Feb 2013 00:54:05 +0000 (00:54 +0000)]
Fix CMake detection of various cmath functions, and XFAIL the test on platforms that are known to be missing them.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174564
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Thu, 7 Feb 2013 00:21:34 +0000 (00:21 +0000)]
Conditionalize constant folding of math intrinsics on the availability of an implementation on the host. This is a little bit unfortunate, but until someone decides to implement a full libm for APFloat, we don't have a better way to get this functionality.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174561
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Wed, 6 Feb 2013 22:43:31 +0000 (22:43 +0000)]
Signficantly generalize our ability to constant fold floating point intrinsics, including ones on half types.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174555
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Wed, 6 Feb 2013 22:34:46 +0000 (22:34 +0000)]
Fix typo
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174553
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Wed, 6 Feb 2013 22:28:53 +0000 (22:28 +0000)]
[Support][ErrorOr] Add support for convertable types.
Thanks to Andrew, David, and Aaron for helping fix this.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174552
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Wed, 6 Feb 2013 22:17:40 +0000 (22:17 +0000)]
Add a comment to the test that points to the source from which the input object
file was generated.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174551
91177308-0d34-0410-b5e6-
96231b3b80d8
Joe Abbey [Wed, 6 Feb 2013 22:14:06 +0000 (22:14 +0000)]
Code Custodian (trivial whitespace cleanup)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174550
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Wed, 6 Feb 2013 21:53:56 +0000 (21:53 +0000)]
Clean up multiple skeleton compile units if we have multiple compile
units coming in.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174548
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Wed, 6 Feb 2013 21:53:53 +0000 (21:53 +0000)]
Remove some dead code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174547
91177308-0d34-0410-b5e6-
96231b3b80d8
Akira Hatanaka [Wed, 6 Feb 2013 21:50:15 +0000 (21:50 +0000)]
[mips] Make NOP a pseudo instruction and expand it to "sll $zero, $zero, 0".
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174546
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Wed, 6 Feb 2013 20:55:06 +0000 (20:55 +0000)]
Add a test for checking the current .debug_frame dumping capability.
The test is a binary placed in test/DebugInfo/Inputs, with a source C
file used for reference/reproducing. The source's first line is a clang
build command for reproducing the binary.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174543
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Wed, 6 Feb 2013 20:43:57 +0000 (20:43 +0000)]
This is a follow-up on r174446, now taking Atom processors into
account. Atoms use LEA for updating SP in prologs/epilogs, and the
exact LEA opcode depends on the data model.
Also reapplying the test case which was added and then reverted
(because of Atom failures), this time specifying explicitly the CPU in
addition to the triple. The test case now checks all variations (data
mode, cpu Atom vs. Core).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174542
91177308-0d34-0410-b5e6-
96231b3b80d8
Guy Benyei [Wed, 6 Feb 2013 20:40:38 +0000 (20:40 +0000)]
Canonicalize line endings to Linux style also when the --strict-whitespace flag is in use. This flag is supposed to affect horizontal whitespaces only.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174541
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Wed, 6 Feb 2013 20:05:44 +0000 (20:05 +0000)]
Improve comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174536
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Schmidt [Wed, 6 Feb 2013 17:33:58 +0000 (17:33 +0000)]
PPC calling convention cleanup.
Most of PPCCallingConv.td is used only by the 32-bit SVR4 ABI. Rename
things to clarify this. Also delete some code that's been commented out
for a long time.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174526
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Wed, 6 Feb 2013 17:32:29 +0000 (17:32 +0000)]
R600: Support for indirect addressing v4
Only implemented for R600 so far. SI is missing implementations of a
few callbacks used by the Indirect Addressing pass and needs code to
handle frame indices.
At the moment R600 only supports array sizes of 16 dwords or less.
Register packing of vector types is currently disabled, which means that a
vec4 is stored in T0_X, T1_X, T2_X, T3_X, rather than T0_XYZW. In order
to correctly pack registers in all cases, we will need to implement an
analysis pass for R600 that determines the correct vector width for each
array.
v2:
- Add support for i8 zext load from stack.
- Coding style fixes
v3:
- Don't reserve registers for indirect addressing when it isn't
being used.
- Fix bug caused by LLVM limiting the number of SubRegIndex
declarations.
v4:
- Fix 64-bit defines
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174525
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Wed, 6 Feb 2013 16:43:33 +0000 (16:43 +0000)]
Implement external weak (ELF) symbols on AArch64
Weakly defined symbols should evaluate to 0 if they're undefined at
link-time. This is impossible to do with the usual address generation
patterns, so we should use a literal pool entry to materlialise the
address.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174518
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Wed, 6 Feb 2013 16:20:31 +0000 (16:20 +0000)]
Add some comments to new frame entries
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174515
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Wed, 6 Feb 2013 09:13:13 +0000 (09:13 +0000)]
Add AArch64 CRC32 instructions
These instructions are a late addition to the architecture, and may
yet end up behind an optional attribute, but for now they're available
at all times.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174496
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Wed, 6 Feb 2013 09:04:56 +0000 (09:04 +0000)]
Add icache prefetch operations to AArch64
This adds hints to the various "prfm" instructions so that they can
affect the instruction cache as well as the data cache.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174495
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Wed, 6 Feb 2013 06:52:58 +0000 (06:52 +0000)]
Initial submission for the attribute group feature.
Attribute groups are of the form:
#0 = attributes { noinline "no-sse" "cpu"="cortex-a8" alignstack=4 }
Target-dependent attributes are represented as strings. Attributes can have
optional values associated with them. E.g., the "cpu" attribute has the value
"cortex-a8".
Target-independent attributes are listed as enums inside the attribute classes.
Multiple attribute groups can be referenced by the same object. In that case,
the attributes are merged together.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174493
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Wed, 6 Feb 2013 06:50:38 +0000 (06:50 +0000)]
Remove extra blank line between closing curly brace and 'else'
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174492
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Wed, 6 Feb 2013 06:48:10 +0000 (06:48 +0000)]
Remove unused private field to suppress a build warning.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174491
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Wed, 6 Feb 2013 06:22:58 +0000 (06:22 +0000)]
Alphabetize the function attributes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174490
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Wed, 6 Feb 2013 06:00:11 +0000 (06:00 +0000)]
ARM: Use MCTargetAsmParser::validateTargetOperandClass().
Use the validateTargetOperandClass() hook to match literal '#0' operands in
InstAlias definitions. Previously this required per-instruction C++ munging of the
operand list, but not is handled as a natural part of the matcher. Much better.
No additional tests are required, as the pre-existing tests for these instructions
exercise the new behaviour as being functionally equivalent to the old.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174488
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Wed, 6 Feb 2013 06:00:06 +0000 (06:00 +0000)]
Allow targets to add custom asm operand matching logic.
For example, ARM has several instructions with a literal '#0' immediate in the syntax
that's not represented as an actual operand. The asm matcher is expected a token
operand, but the parser will have created an immediate operand. This is currently
handled by dedicated per-instruction C++ munging of the ParsedAsmOperand list, but
will be better handled by this hook.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174487
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Wed, 6 Feb 2013 05:37:46 +0000 (05:37 +0000)]
Failing builds because a private class member is not being used after
initialization is one of the reasons I consider -werror to be shoddy.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174485
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Wed, 6 Feb 2013 03:15:00 +0000 (03:15 +0000)]
Remove this test in the meantime, since it won't pass on Atom. Atom uses lea
to move the stack pointer in prologs/epilogs. I will fix the test and add it
back later.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174484
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Wed, 6 Feb 2013 03:08:02 +0000 (03:08 +0000)]
Add virtual desctructor to FrameEntry to avoid error on delete-non-virtual-dtor
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174483
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Wed, 6 Feb 2013 02:06:33 +0000 (02:06 +0000)]
Tweak check to avoid integer overflow (for insanely large alignments)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174482
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Wed, 6 Feb 2013 01:33:42 +0000 (01:33 +0000)]
Add a 'StringRef' version of hasAttribute.
Fix the 'operator==' and 'hasAttributes' queries to take into account
target-dependent attributes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174481
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Wed, 6 Feb 2013 01:16:00 +0000 (01:16 +0000)]
Add methods to merge an AttrBuilder into another builder.
This is useful when parsing an object that references multiple attribute groups.
N.B. If both builders have alignments specified, then they should match!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174480
91177308-0d34-0410-b5e6-
96231b3b80d8
Manman Ren [Wed, 6 Feb 2013 00:59:41 +0000 (00:59 +0000)]
Attempt to recover gdb bot after r174445.
Failure: undefined symbol 'Lline_table_start0'.
Root-cause: we use a symbol subtraction to calculate at_stmt_list, but
the line table entries are not dumped in the assembly.
Fix: use zero instead of a symbol subtraction for Compile Unit 0.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174479
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Wed, 6 Feb 2013 00:20:38 +0000 (00:20 +0000)]
Fix some formatting & add comments, following Eric's review
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174473
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 5 Feb 2013 23:48:36 +0000 (23:48 +0000)]
Add the target-dependent (string) attributes from the AttrBuilder to the AttributeSet.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174467
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Tue, 5 Feb 2013 23:37:18 +0000 (23:37 +0000)]
Add missing file to CMake list
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174465
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Tue, 5 Feb 2013 23:31:48 +0000 (23:31 +0000)]
Test for r174446
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174464
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Tue, 5 Feb 2013 23:30:58 +0000 (23:30 +0000)]
Initial support for DWARF CFI parsing and dumping in LLVM
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174463
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Tue, 5 Feb 2013 23:26:02 +0000 (23:26 +0000)]
Be consistent about the field name - AddressSize, not PointerSize. Add
a setter and fix some comments.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174462
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Tue, 5 Feb 2013 22:59:42 +0000 (22:59 +0000)]
Preprocess Apple llvmCore headers to reflect NDEBUG setting. <rdar://
12568983>
If an Apple llvmCore build is done without assertions, and a client uses
the llvmCore headers with assertions enabled, or vice versa, then things will
break because some of the structure sizes in the API are different. Use the
unifdef tool to make the headers unconditionally match the way the llvmCore
libraries were built.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174460
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Trick [Tue, 5 Feb 2013 22:50:20 +0000 (22:50 +0000)]
Revert "[Support][ErrorOr] Add support for convertable types."
This reverts commit
a33e1fafac7fedb1b080ef07ddf9ad6ddff3a830.
This unit test crashes on Darwon. It needs to be temporarily reverted
to unblock the test infrastructure.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174458
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 5 Feb 2013 22:37:24 +0000 (22:37 +0000)]
Convert to storing the attribute's internals as enums, integers, and strings.
The stuff we're handing are all enums (Attribute::AttrKind), integers and
strings. Don't convert them to Constants, which is an unnecessary step here. The
rest of the changes are mostly mechanical.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174456
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Tue, 5 Feb 2013 21:53:29 +0000 (21:53 +0000)]
Make sure the correct opcodes are used to SUB and ADD the stack
pointer in function prologs/epilogs. The opcodes should depend on the
data model (LP64 vs. ILP32) rather than the architecture bit-ness.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174446
91177308-0d34-0410-b5e6-
96231b3b80d8
Manman Ren [Tue, 5 Feb 2013 21:52:47 +0000 (21:52 +0000)]
Dwarf: support for LTO where a single object file can have multiple line tables
We generate one line table for each compilation unit in the object file.
Reviewed by Eric and Kevin.
rdar://problem/
13067005
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174445
91177308-0d34-0410-b5e6-
96231b3b80d8
Akira Hatanaka [Tue, 5 Feb 2013 21:18:11 +0000 (21:18 +0000)]
[mips] Do not use function CC_MipsN_VarArg unless the function being analyzed
is a vararg function.
The original code was examining flag OutputArg::IsFixed to determine whether
CC_MipsN_VarArg or CC_MipsN should be called. This is not correct, since this
flag is often set to false when the function being analyzed is a non-variadic
function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174442
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Tue, 5 Feb 2013 20:27:22 +0000 (20:27 +0000)]
[objdump,readobj] Document the purpose and goals of each tool.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174439
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Tue, 5 Feb 2013 20:22:40 +0000 (20:22 +0000)]
InstCombine: Fix and simplify the inttoptr side too.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174438
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Gottesman [Tue, 5 Feb 2013 19:39:44 +0000 (19:39 +0000)]
Added missing newline to end of test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174433
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Gottesman [Tue, 5 Feb 2013 19:32:18 +0000 (19:32 +0000)]
Removed explicit inline as per the LLVM style guide.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174432
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Tue, 5 Feb 2013 19:24:39 +0000 (19:24 +0000)]
Reapply r174343, with a fix for a scary DAG combine bug where it failed to differentiate between the alignment of the
base point of a load, and the overall alignment of the load. This caused infinite loops in DAG combine with the
original application of this patch.
ORIGINAL COMMIT LOG:
When the target-independent DAGCombiner inferred a higher alignment for a load,
it would replace the load with one with the higher alignment. However, it did
not place the new load in the worklist, which prevented later DAG combines in
the same phase (for example, target-specific combines) from ever seeing it.
This patch corrects that oversight, and updates some tests whose output changed
due to slightly different DAGCombine outputs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174431
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Tue, 5 Feb 2013 19:21:56 +0000 (19:21 +0000)]
InstCombine: Harden code to work with vectors of pointers and simplify it a bit.
Found by running instcombine on a fabricated test case for the constant folder.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174430
91177308-0d34-0410-b5e6-
96231b3b80d8
Jyotsna Verma [Tue, 5 Feb 2013 19:20:45 +0000 (19:20 +0000)]
Hexagon: Use TFR_cond with cmpb.[eq,gt,gtu] to handle
zext( set[ne,eq,gt,ugt] (...) ) type of dag patterns.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174429
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Tue, 5 Feb 2013 19:04:36 +0000 (19:04 +0000)]
ConstantFolding: Fix a crash when encoutering a truncating inttoptr.
This was introduced in r173293.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174424
91177308-0d34-0410-b5e6-
96231b3b80d8
Arnold Schwaighofer [Tue, 5 Feb 2013 18:46:41 +0000 (18:46 +0000)]
Loop Vectorizer: Refactor code to compute vectorized memory instruction cost
Introduce a helper class that computes the cost of memory access instructions.
No functionality change intended.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174422
91177308-0d34-0410-b5e6-
96231b3b80d8
Jyotsna Verma [Tue, 5 Feb 2013 18:23:51 +0000 (18:23 +0000)]
Hexagon: Add testcase for post-increment store instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174419
91177308-0d34-0410-b5e6-
96231b3b80d8
Chad Rosier [Tue, 5 Feb 2013 18:23:10 +0000 (18:23 +0000)]
[SjLj Prepare] When demoting an invoke instructions to the stack, if the normal
edge is critical, then split it so we can insert the store.
rdar://
13126179
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@174418
91177308-0d34-0410-b5e6-
96231b3b80d8