Renato Golin [Sat, 19 Jan 2013 00:42:16 +0000 (00:42 +0000)]
Fix 80-col and early exit in cost model
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172877
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Sat, 19 Jan 2013 00:03:32 +0000 (00:03 +0000)]
Remove some register allocation order dependencies.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172874
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Kaylor [Fri, 18 Jan 2013 23:40:42 +0000 (23:40 +0000)]
Fixing behavior of ELFObjectFile::getSymbolFileOffset().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172872
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Fri, 18 Jan 2013 23:22:52 +0000 (23:22 +0000)]
Pass NO_MISSING_FIELD_INITIALIZERS to Compiler Flags
configure checks whether -Wno-missing-field-initializers is a valid
compiler flag but it was never actually used in Makefile.rules.
Enable it to avoid some ridiculous warnings from gcc.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172870
91177308-0d34-0410-b5e6-
96231b3b80d8
Nadav Rotem [Fri, 18 Jan 2013 23:10:30 +0000 (23:10 +0000)]
On Sandybridge loading unaligned 256bits using two XMM loads (vmovups and vinsertf128) is faster than using a single vmovups instruction.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172868
91177308-0d34-0410-b5e6-
96231b3b80d8
Jordan Rose [Fri, 18 Jan 2013 23:05:41 +0000 (23:05 +0000)]
Use hexDigitValue in LLLexer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172866
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Gottesman [Fri, 18 Jan 2013 23:02:45 +0000 (23:02 +0000)]
Improved comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172864
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Gottesman [Fri, 18 Jan 2013 23:00:33 +0000 (23:00 +0000)]
Fixed typo in comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172863
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 18 Jan 2013 22:11:33 +0000 (22:11 +0000)]
Split out DW_OP_addr for the split debug info DWARF5 proposal.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172857
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 18 Jan 2013 21:56:07 +0000 (21:56 +0000)]
If the attributes don't exist, just bail for now.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172854
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 18 Jan 2013 21:53:16 +0000 (21:53 +0000)]
Use AttributeSet accessor methods instead of Attribute accessor methods.
Further encapsulation of the Attribute object. Don't allow direct access to the
Attribute object as an aggregate.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172853
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 18 Jan 2013 21:50:24 +0000 (21:50 +0000)]
Remove unused parameter. Also use the AttributeSet query methods instead of the Attribute query methods.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172852
91177308-0d34-0410-b5e6-
96231b3b80d8
Jordan Rose [Fri, 18 Jan 2013 21:45:30 +0000 (21:45 +0000)]
Add llvm::hexDigitValue to convert single characters to hex.
This is duplicated in a couple places in the codebase. Adopt this in APFloat.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172851
91177308-0d34-0410-b5e6-
96231b3b80d8
Jack Carter [Fri, 18 Jan 2013 21:20:38 +0000 (21:20 +0000)]
This is a resubmittal. For some reason it broke the bots yesterday
but I cannot reproduce the problem and have scrubed my sources and
even tested with llvm-lit -v --vg.
Support for Mips register information sections.
Mips ELF object files have a section that is dedicated
to register use info. Some of this information such as
the assumed Global Pointer value is used by the linker
in relocation resolution.
The register info file is .reginfo in o32 and .MIPS.options
in 64 and n32 abi files.
This patch contains the changes needed to create the sections,
but leaves the actual register accounting for a future patch.
Contributer: Jack Carter
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172847
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Fri, 18 Jan 2013 21:15:53 +0000 (21:15 +0000)]
R600: Proper insert S_WAITCNT instructions
Some instructions like memory reads/writes are executed
asynchronously, so we need to insert S_WAITCNT instructions
to block before accessing their results. Previously we have
just inserted S_WAITCNT instructions after each async
instruction, this patch fixes this and adds a prober
insertion pass.
Patch by: Christian König
Tested-by: Michel Dänzer <michel.daenzer@amd.com>
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
Signed-off-by: Christian König <deathsimple@vodafone.de>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172846
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Fri, 18 Jan 2013 21:15:50 +0000 (21:15 +0000)]
R600: Optimize and cleanup KILL on SI
We shouldn't insert KILL optimization if we don't have a
kill instruction at all.
Patch by: Christian König
Tested-by: Michel Dänzer <michel.daenzer@amd.com>
Reviewed-by: Tom Stellard <thomas.stellard@amd.com>
Signed-off-by: Christian König <deathsimple@vodafone.de>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172845
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 18 Jan 2013 21:11:39 +0000 (21:11 +0000)]
Push some more methods down to hide the use of the Attribute class.
Because the Attribute class is going to stop representing a collection of
attributes, limit the use of it as an aggregate in favor of using AttributeSet.
This replaces some of the uses for querying the function attributes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172844
91177308-0d34-0410-b5e6-
96231b3b80d8
Jack Carter [Fri, 18 Jan 2013 20:15:06 +0000 (20:15 +0000)]
This is a resubmittal. For some reason it broke the bots yesterday
but I cannot reproduce the problem and have scrubed my sources and
even tested with llvm-lit -v --vg.
Removal of redundant code and formatting fixes.
Contributers: Jack Carter/Vladimir Medic
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172842
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 18 Jan 2013 20:08:09 +0000 (20:08 +0000)]
[Linker] Zap a dead typedef.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172841
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Fri, 18 Jan 2013 19:45:22 +0000 (19:45 +0000)]
Silence GCC warning about dropping off a non-void function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172839
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 18 Jan 2013 19:37:11 +0000 (19:37 +0000)]
[Linker] Kill Linker::LoadObject which is dead, and drop the BitReader dependency again.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172838
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 18 Jan 2013 19:37:00 +0000 (19:37 +0000)]
[MC/Mach-O] Implement integrated assembler support for linker options.
- Also, fixup syntax errors in LangRef and missing newline in the MCAsmStreamer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172837
91177308-0d34-0410-b5e6-
96231b3b80d8
Dmitri Gribenko [Fri, 18 Jan 2013 19:27:43 +0000 (19:27 +0000)]
Documentation: remove all mentions of DejaGNU and Tcl
We don't have DejaGNU tests now.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172836
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Fri, 18 Jan 2013 19:01:34 +0000 (19:01 +0000)]
Streamline the mentions of grep and FileCheck in TestingGuide.rst
grep is now only mentioned once in a sentence that explicitly says it's
deprecated. For FileCheck, there's no reason to repeat part of the
documentation that exists in CommandGuide/FileCheck.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172835
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Fri, 18 Jan 2013 15:03:03 +0000 (15:03 +0000)]
The IR linker still depends on the bitcode reader.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172824
91177308-0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Fri, 18 Jan 2013 14:52:02 +0000 (14:52 +0000)]
llvm/test/CodeGen/X86/Atomics-64.ll: Tweak for 2nd RUN not to overwrite %t. It sometimes causes spurious failure on lit win32.
Feel free to prune or suppress each output.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172823
91177308-0d34-0410-b5e6-
96231b3b80d8
Alexey Samsonov [Fri, 18 Jan 2013 12:49:06 +0000 (12:49 +0000)]
80 columns
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172813
91177308-0d34-0410-b5e6-
96231b3b80d8
Will Dietz [Fri, 18 Jan 2013 11:29:21 +0000 (11:29 +0000)]
Move Blacklist.h to include/ to enable use from clang.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172806
91177308-0d34-0410-b5e6-
96231b3b80d8
Manuel Klimek [Fri, 18 Jan 2013 10:18:50 +0000 (10:18 +0000)]
Add basic command line parsing to TestMain.
Summary:
This allows unit tests for components that use Support/Debug.h to print
debug information from test runs by specifying -debug when running the
test.
CC: llvm-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D301
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172801
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Fri, 18 Jan 2013 08:41:28 +0000 (08:41 +0000)]
Calculate vector element size more directly for VINSERTF128/VEXTRACTF128 immediate handling. Also use MVT since this only called on legal types during pattern matching.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172797
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Fri, 18 Jan 2013 07:27:20 +0000 (07:27 +0000)]
Minor formatting fix. No functional change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172795
91177308-0d34-0410-b5e6-
96231b3b80d8
Dmitri Gribenko [Fri, 18 Jan 2013 06:57:01 +0000 (06:57 +0000)]
Remove support for Tcl test format since nobody uses it
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172794
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Fri, 18 Jan 2013 06:50:59 +0000 (06:50 +0000)]
Spelling fix: extened->extended. Trailing whitespace in same function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172793
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Fri, 18 Jan 2013 06:44:29 +0000 (06:44 +0000)]
Make more use of is128BitVector/is256BitVector in place of getSizeInBits() == 128/256.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172792
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Fri, 18 Jan 2013 05:30:07 +0000 (05:30 +0000)]
Check for less than 0 in shuffle mask instead of -1. It's more consistent with other code related to shuffles and easier to implement in compiled code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172788
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Fri, 18 Jan 2013 05:09:16 +0000 (05:09 +0000)]
Remove trailing whitespace. Remove new lines between closing brace and 'else'
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172784
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Gottesman [Fri, 18 Jan 2013 03:08:39 +0000 (03:08 +0000)]
Fixed 80+ violation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172782
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 18 Jan 2013 01:26:07 +0000 (01:26 +0000)]
[MC/Mach-O] Add support for linker options in Mach-O files.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172779
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 18 Jan 2013 01:25:48 +0000 (01:25 +0000)]
[MC/Mach-O] Add AsmParser support for .linker_option directive.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172778
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 18 Jan 2013 01:25:33 +0000 (01:25 +0000)]
[MC] Expose ParseEscapedString to target AsmParser implementations.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172777
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 18 Jan 2013 01:25:25 +0000 (01:25 +0000)]
[MC] Fix 80-col violas.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172776
91177308-0d34-0410-b5e6-
96231b3b80d8
Chad Rosier [Fri, 18 Jan 2013 00:50:59 +0000 (00:50 +0000)]
[ms-inline asm] Make the error message more generic now that we support the
'SIZE' and 'LENGTH' operators.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172773
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Thu, 17 Jan 2013 22:05:18 +0000 (22:05 +0000)]
[Linker] Drop some now-dead component dependencies.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172759
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Thu, 17 Jan 2013 21:28:46 +0000 (21:28 +0000)]
Reverting r171325 & r172363. This was causing a mis-compile on the self-hosted LTO build bots.
Okay, here's how to reproduce the problem:
1) Build a Release (or Release+Asserts) version of clang in the normal way.
2) Using the clang & clang++ binaries from (1), build a Release (or
Release+Asserts) version of the same sources, but this time enable LTO ---
specify the `-flto' flag on the command line.
3) Run the ARC migrator tests:
$ arcmt-test --args -triple x86_64-apple-darwin10 -fsyntax-only -x objective-c++ ./src/tools/clang/test/ARCMT/cxx-rewrite.mm
You'll see that the output isn't correct (the whitespace is off).
The mis-compile is in the function `RewriteBuffer::RemoveText' in the
clang/lib/Rewrite/Core/Rewriter.cpp file. When that function and RewriteRope.cpp
are compiled with LTO and the `arcmt-test' executable is regenerated, you'll see
the error. When those files are not LTO'ed, then the output of the `arcmt-test'
is fine.
It is *really* hard to get a testcase out of this. I'll file a PR with what I
have currently.
--- Reverse-merging r172363 into '.':
U include/llvm/Analysis/MemoryBuiltins.h
U lib/Analysis/MemoryBuiltins.cpp
--- Reverse-merging r171325 into '.':
U test/Transforms/InstCombine/objsize.ll
G include/llvm/Analysis/MemoryBuiltins.h
G lib/Analysis/MemoryBuiltins.cpp
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172756
91177308-0d34-0410-b5e6-
96231b3b80d8
Aaron Ballman [Thu, 17 Jan 2013 20:04:28 +0000 (20:04 +0000)]
Reverting back to the fallback instead of using the 64-bit popcnt instruction as it doesn't exist on all x64 CPU architectures.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172751
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Thu, 17 Jan 2013 19:52:25 +0000 (19:52 +0000)]
[Linker] Drop support for IR-level extended linking support (archives, etc.).
- This code is dead, and the "right" way to get this support is to use the
platform-specific linker-integrated LTO mechanisms, or the forthcoming LLVM
linker.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172749
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Schmidt [Thu, 17 Jan 2013 19:46:51 +0000 (19:46 +0000)]
Restore reverted test case, this time with REQUIRES: asserts
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172747
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Schmidt [Thu, 17 Jan 2013 19:39:36 +0000 (19:39 +0000)]
Remove bad test case
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172746
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Schmidt [Thu, 17 Jan 2013 19:34:57 +0000 (19:34 +0000)]
This patch fixes PR13626 by providing i128 support in the return
calling convention. 128-bit integers are now properly returned
in GPR3 and GPR4 on PowerPC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172745
91177308-0d34-0410-b5e6-
96231b3b80d8
Chad Rosier [Thu, 17 Jan 2013 19:21:48 +0000 (19:21 +0000)]
[ms-inline asm] Add support for the 'SIZE' and 'LENGTH' operators.
Part of rdar://
12576868
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172743
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Thu, 17 Jan 2013 18:57:32 +0000 (18:57 +0000)]
[docs] Get rid of some UTF8 characters (non-breaking space maybe).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172741
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Thu, 17 Jan 2013 18:57:21 +0000 (18:57 +0000)]
[utils] Update find-rev utility to take a branch argument (name of the git-svn
branch).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172740
91177308-0d34-0410-b5e6-
96231b3b80d8
Jyotsna Verma [Thu, 17 Jan 2013 18:42:37 +0000 (18:42 +0000)]
Add indexed load/store instructions for offset validation check.
This patch fixes bug 14902 - http://llvm.org/bugs/show_bug.cgi?id=14902
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172737
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Gottesman [Thu, 17 Jan 2013 18:36:17 +0000 (18:36 +0000)]
Added missing const from my last commit.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172736
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Gottesman [Thu, 17 Jan 2013 18:32:34 +0000 (18:32 +0000)]
[ObjCARC] Implemented operator<< for InstructionClass and changed a ``Visited'' Debug message to use it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172735
91177308-0d34-0410-b5e6-
96231b3b80d8
Aaron Ballman [Thu, 17 Jan 2013 18:27:30 +0000 (18:27 +0000)]
Reverting back to the fallback instead of using popcnt; this instruction doesn't exist on all CPU architectures. Fixes PR14982
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172734
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Schmidt [Thu, 17 Jan 2013 17:45:19 +0000 (17:45 +0000)]
This patch fixes the PPC calling convention to handle returns of
_Complex float and _Complex long double, by simply increasing the
number of floating point registers available for return values.
The test case verifies that the correct registers are loaded.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172733
91177308-0d34-0410-b5e6-
96231b3b80d8
Alexey Samsonov [Thu, 17 Jan 2013 11:12:32 +0000 (11:12 +0000)]
ASan: add optional 'zero-based shadow' option to ASan passes. Always tell the values of shadow scale and offset to the runtime
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172709
91177308-0d34-0410-b5e6-
96231b3b80d8
Elena Demikhovsky [Thu, 17 Jan 2013 09:59:53 +0000 (09:59 +0000)]
Optimization for the following SIGN_EXTEND pairs:
v8i8 -> v8i64,
v8i8 -> v8i32,
v4i8 -> v4i64,
v4i16 -> v4i64
for AVX and AVX2.
Bug 14865.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172708
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Thu, 17 Jan 2013 06:59:42 +0000 (06:59 +0000)]
Combine AVX and SSE forms of MOVSS and MOVSD into the same multiclasses so they get instantiated together.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172704
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Thu, 17 Jan 2013 03:00:04 +0000 (03:00 +0000)]
Fix the assembly and dissassembly of DW_FORM_sec_offset. Found this by
changing both the string of the dwo_name to be correct and the type of
the statement list.
Testcases all around.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172699
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Thu, 17 Jan 2013 02:59:59 +0000 (02:59 +0000)]
Add the DW_AT_GNU_addr_base for the skeleton cu. Add support for
emitting the dwarf32 version of DW_FORM_sec_offset and correct
disassembler support.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172698
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Thu, 17 Jan 2013 01:06:04 +0000 (01:06 +0000)]
Move MachineTraceMetrics.h into include/llvm/CodeGen.
Let targets use it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172688
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Thu, 17 Jan 2013 00:58:38 +0000 (00:58 +0000)]
Provide a place for targets to insert ILP optimization passes.
Move the early if-conversion pass into this group.
ILP optimizations usually need to find the right balance between
register pressure and ILP using the MachineTraceMetrics analysis to
identify critical paths and estimate other costs. Such passes should run
together so they can share dominator tree and loop info analyses.
Besides if-conversion, future passes to run here here could include
expression height reduction and ARM's MLxExpansion pass.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172687
91177308-0d34-0410-b5e6-
96231b3b80d8
Jack Carter [Thu, 17 Jan 2013 00:28:20 +0000 (00:28 +0000)]
This is a resubmittal. For some reason it broke the bots yesterday
but I cannot reproduce the problem and have scrubed my sources and
even tested with llvm-lit -v --vg.
The Mips RDHWR (Read Hardware Register) instruction was not
tested for assembler or dissassembler consumption. This patch
adds that functionality.
Contributer: Vladimir Medic
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172685
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Thu, 17 Jan 2013 00:16:27 +0000 (00:16 +0000)]
[IR] Reserve/define the purpose for the "Linker Options" metadata flags.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172681
91177308-0d34-0410-b5e6-
96231b3b80d8
Lang Hames [Thu, 17 Jan 2013 00:00:49 +0000 (00:00 +0000)]
Update the description of the llvm.fmuladd.* intrinsics to avoid use of the
ambiguous term 'legal'.
Suggested by Andrew Booker. Thanks Andrew!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172680
91177308-0d34-0410-b5e6-
96231b3b80d8
Dmitri Gribenko [Wed, 16 Jan 2013 23:40:37 +0000 (23:40 +0000)]
Documentation: fix a typo 'IEE754'
Reported on IRC by _savage
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172677
91177308-0d34-0410-b5e6-
96231b3b80d8
Aaron Ballman [Wed, 16 Jan 2013 23:17:21 +0000 (23:17 +0000)]
Wrapping __popcnt64 for MSVC so that it's only used on 64-bit builds.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172670
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Wed, 16 Jan 2013 21:38:56 +0000 (21:38 +0000)]
[IR] Add 'Append' and 'AppendUnique' module flag behaviors.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172659
91177308-0d34-0410-b5e6-
96231b3b80d8
Renato Golin [Wed, 16 Jan 2013 21:29:55 +0000 (21:29 +0000)]
Change CostTable model to be global to all targets
Moving the X86CostTable to a common place, so that other back-ends
can share the code. Also simplifying it a bit and commoning up
tables with one and two types on operations.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172658
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Gottesman [Wed, 16 Jan 2013 21:07:18 +0000 (21:07 +0000)]
Added test for r172599 which fixes bugzilla://14584,rdar://
11744105.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172656
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Wed, 16 Jan 2013 20:50:43 +0000 (20:50 +0000)]
[Support] Include the intrisics header and check for definition properly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172655
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Wed, 16 Jan 2013 20:31:35 +0000 (20:31 +0000)]
Make this test X86 only.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172652
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Wed, 16 Jan 2013 20:31:32 +0000 (20:31 +0000)]
Move this to X86.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172651
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Wed, 16 Jan 2013 19:53:47 +0000 (19:53 +0000)]
Add testcase missed yesterday from Paul Robinson.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172646
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Wed, 16 Jan 2013 19:52:12 +0000 (19:52 +0000)]
[Support] Add MSVC intrinsic for CountPopulation.
Patch by Jakub Staszak.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172645
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Wed, 16 Jan 2013 19:51:59 +0000 (19:51 +0000)]
[Support] Update MSVC compiler support in Compiler.h.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172644
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Wed, 16 Jan 2013 19:42:16 +0000 (19:42 +0000)]
Remove unneeded include and empty line
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172642
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Wed, 16 Jan 2013 19:32:36 +0000 (19:32 +0000)]
Some small (and mostly cosmetic) fixes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172640
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Wed, 16 Jan 2013 19:00:21 +0000 (19:00 +0000)]
Clean up some unnecessary headers and forward declarations
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172638
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Wed, 16 Jan 2013 18:56:50 +0000 (18:56 +0000)]
Now that GenericAsmParser was folded into AsmParser, some methods and types can
return into the safe harbor of AsmParser's private areas.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172637
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Wed, 16 Jan 2013 18:39:23 +0000 (18:39 +0000)]
[Linker] Change module flag linking to be more extensible.
- Instead of computing a bunch of buckets of different flag types, just do an
incremental link resolving conflicts as they arise.
- This also has the advantage of making the link result deterministic and not
dependent on map iteration order.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172634
91177308-0d34-0410-b5e6-
96231b3b80d8
Kevin Enderby [Wed, 16 Jan 2013 17:46:23 +0000 (17:46 +0000)]
We want the dwarf AT_producer for assembly source files to match clang's
AT_producer. Which includes clang's version information so we can tell
which version of the compiler was used.
This is the first of two steps to allow us to do that. This is the llvm-mc
change to provide a method to set the AT_producer string. The second step,
coming soon to a clang near you, will have the clang driver pass the value
of getClangFullVersion() via an flag when invoking the integrated assembler
on assembly source files.
rdar://
12955296
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172630
91177308-0d34-0410-b5e6-
96231b3b80d8
Peter Collingbourne [Wed, 16 Jan 2013 17:27:22 +0000 (17:27 +0000)]
Introduce llvm::sys::getProcessTriple() function.
In r143502, we renamed getHostTriple() to getDefaultTargetTriple()
as part of work to allow the user to supply a different default
target triple at configure time. This change also affected the JIT.
However, it is inappropriate to use the default target triple in the
JIT in most circumstances because this will not necessarily match
the current architecture used by the process, leading to illegal
instruction and other such errors at run time.
Introduce the getProcessTriple() function for use in the JIT and
its clients, and cause the JIT to use it. On architectures with a
single bitness, the host and process triples are identical. On other
architectures, the host triple represents the architecture of the
host CPU, while the process triple represents the architecture used
by the host CPU to interpret machine code within the current process.
For example, when executing 32-bit code on a 64-bit Linux machine,
the host triple may be 'x86_64-unknown-linux-gnu', while the process
triple may be 'i386-unknown-linux-gnu'.
This fixes JIT for the 32-on-64-bit (and vice versa) build on non-Apple
platforms.
Differential Revision: http://llvm-reviews.chandlerc.com/D254
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172627
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Wed, 16 Jan 2013 16:52:08 +0000 (16:52 +0000)]
Replace virtual hasFixups with explicit fragment type checks
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172622
91177308-0d34-0410-b5e6-
96231b3b80d8
Evgeniy Stepanov [Wed, 16 Jan 2013 14:41:46 +0000 (14:41 +0000)]
Allow vectors in CreatePointerCast of constants.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172615
91177308-0d34-0410-b5e6-
96231b3b80d8
Evgeniy Stepanov [Wed, 16 Jan 2013 14:38:50 +0000 (14:38 +0000)]
A test for r172535.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172614
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Wed, 16 Jan 2013 13:43:56 +0000 (13:43 +0000)]
Remove unused leftover header (it moved to llvm/IR).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172612
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Wed, 16 Jan 2013 13:25:56 +0000 (13:25 +0000)]
Move test that depends on the x86 target into a target-specific directory.
Should fix the arm buildbot (which only builds the arm target).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172611
91177308-0d34-0410-b5e6-
96231b3b80d8
Alexey Samsonov [Wed, 16 Jan 2013 13:23:28 +0000 (13:23 +0000)]
ASan: wrap mapping scale and offset in a struct and make it a member of ASan passes. Add test for non-default mapping scale and offset. No functionality change
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172610
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Wed, 16 Jan 2013 13:19:59 +0000 (13:19 +0000)]
Remove triple from this test, it makes it fail when X86 TTI is missing.
Without a triple opt falls back to NoTTI which comes closer to LSR's pre-TTI behavior.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172609
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Gottesman [Wed, 16 Jan 2013 06:32:39 +0000 (06:32 +0000)]
[ObjCARC] Turn off ignoring unwind edges in ObjCARC when -fno-objc-arc-exception is enabled due to it's affect on correctness.
Specifically according to the semantics of ARC -fno-objc-arc-exception simply
states that it is expected that the unwind path out of a call *MAY* not release
objects. Thus we can have the situation where a release gets moved into a catch
block which we ignore when we remove a retain/release pair resulting in (even
though we assume the program is exiting anyways) the cleanup code path
potentially blowing up before program exit.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172599
91177308-0d34-0410-b5e6-
96231b3b80d8
Jack Carter [Wed, 16 Jan 2013 01:29:10 +0000 (01:29 +0000)]
reverting 172579
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172594
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Wed, 16 Jan 2013 01:22:23 +0000 (01:22 +0000)]
Define metadata interfaces for describing a static data member
of a class. Emit static data member declarations and definitions
through correctly.
Part of PR14471.
Patch by Paul Robinson!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172590
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Bendersky [Wed, 16 Jan 2013 00:50:52 +0000 (00:50 +0000)]
Use the ExtensionDirectiveHandler type in other places where it makes sense.
Since we already have this type it's a shame to keep dragging a pair of object
and method around explicitly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172584
91177308-0d34-0410-b5e6-
96231b3b80d8
David Greene [Wed, 16 Jan 2013 00:17:38 +0000 (00:17 +0000)]
Use --enable-werror
Use --enable-werror during configure time rather than
--with-extra-options. This is cleaner and easier to read.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172581
91177308-0d34-0410-b5e6-
96231b3b80d8
Dmitri Gribenko [Wed, 16 Jan 2013 00:14:15 +0000 (00:14 +0000)]
Improve r172577 by using the correct type when declaring constants
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172580
91177308-0d34-0410-b5e6-
96231b3b80d8
Jack Carter [Wed, 16 Jan 2013 00:07:45 +0000 (00:07 +0000)]
Akira,
Hope you are feeling better.
The Mips RDHWR (Read Hardware Register) instruction was not
tested for assembler or dissassembler consumption. This patch
adds that functionality.
Contributer: Vladimir Medic
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172579
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Tue, 15 Jan 2013 23:56:56 +0000 (23:56 +0000)]
Split address information for DWARF5 split dwarf proposal. This involves
using the DW_FORM_GNU_addr_index and a separate .debug_addr section which
stays in the executable and is fully linked.
Sneak in two other small changes:
a) Print out the debug_str_offsets.dwo section.
b) Change form we're expecting the entries in the debug_str_offsets.dwo
section to take from ULEB128 to U32.
Add tests for all of this in the fission-cu.ll test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172578
91177308-0d34-0410-b5e6-
96231b3b80d8