Matt Arsenault [Wed, 3 Jun 2015 20:04:05 +0000 (20:04 +0000)]
R600/SI: Fix tests with triples in them
Only set the triple from the command line options.
Some of these were still testing SI features and using the
old r600-- triple.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238958
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Wed, 3 Jun 2015 19:07:51 +0000 (19:07 +0000)]
add missing dependency on Target lib for tools
This was exposed by r238842 (which was reverted by r238900)
when doing a CMake build with -DBUILD_SHARED_LIBS=ON.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238953
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Wed, 3 Jun 2015 19:03:11 +0000 (19:03 +0000)]
Remove getOrCreateSymbolData. There is no MCSymbolData anymore.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238952
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Wed, 3 Jun 2015 18:26:52 +0000 (18:26 +0000)]
RuntimeDyld: override EH frame registration with trivial version.
llvm-rtdyld was relying on the default memory manager's EH frame registration,
which is host-dependent rather than target-dependent. As a result, big-endian
ELF Mips EH frames were being registered on OS X (and elsewhere). This is a
really bad idea.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238951
91177308-0d34-0410-b5e6-
96231b3b80d8
Colin LeMahieu [Wed, 3 Jun 2015 18:00:45 +0000 (18:00 +0000)]
[Hexagon] Test doesn't work on all platforms. At any rate the uninitialized variable issue was fixed. Removing re-registering ASM backend.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238949
91177308-0d34-0410-b5e6-
96231b3b80d8
Colin LeMahieu [Wed, 3 Jun 2015 17:34:16 +0000 (17:34 +0000)]
[Hexagon] Reapply 238772 OSABI was not correctly set, added empty_elf test to make sure it is.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238947
91177308-0d34-0410-b5e6-
96231b3b80d8
Frederic Riss [Wed, 3 Jun 2015 17:08:42 +0000 (17:08 +0000)]
Revert "[dsymutil] Accept a YAML debug map as input instead of a binary."
This reverts commit r238941 while I figure out the bot issues.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238943
91177308-0d34-0410-b5e6-
96231b3b80d8
Frederic Riss [Wed, 3 Jun 2015 16:57:16 +0000 (16:57 +0000)]
[dsymutil] Accept a YAML debug map as input instead of a binary.
To do this, the user needs to pass the new -y flag.
As it wasn't tested before, the debug map YAML deserialization was
completely buggy (mainly because the DebugMapObject has a dual
mapping that allows to search by name and by address, but only the
StringMap got populated). It's fixed and tested in this commit by
augmenting some test with a 2 stage dwarf link: a frist llvm-dsymutil
reads the debug map and pipes it in a second instance that does the
actual link without touching the initial binary.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238941
91177308-0d34-0410-b5e6-
96231b3b80d8
Frederic Riss [Wed, 3 Jun 2015 16:57:12 +0000 (16:57 +0000)]
[dsymutil] Replace -parse-only option with -dump-debug-map
As the serialized debug map is becoming a first class citizen, a way
to cleanly dump it is required. We used -parse-only combined with
-v for that purpose before, but it dumps a lot of unrelated debug
stuff. Dumping the debug map was the only use of the -parse-only flag
anyway, so replace it with a more useful option.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238940
91177308-0d34-0410-b5e6-
96231b3b80d8
Frederic Riss [Wed, 3 Jun 2015 16:57:07 +0000 (16:57 +0000)]
[dsymutil] Reflow option declarations to be more readable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238939
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Wed, 3 Jun 2015 16:30:24 +0000 (16:30 +0000)]
ARM: Thumb2 LDRD/STRD supports independent input/output regs
The existing code would unnecessarily break LDRD/STRD apart with
non-adjacent registers, on thumb2 this is not necessary.
Ideally on thumb2 we shouldn't match for ldrd/strd pre-regalloc anymore
as there is not reason to set register hints anymore, changing that is
something for a future patch however.
Differential Revision: http://reviews.llvm.org/D9694
Recommiting after the revert in r238821, the buildbot still failed with
the patch removed so there seems to be another reason for the breakage.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238935
91177308-0d34-0410-b5e6-
96231b3b80d8
Diego Novillo [Wed, 3 Jun 2015 16:22:12 +0000 (16:22 +0000)]
Fix typo in comment. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238933
91177308-0d34-0410-b5e6-
96231b3b80d8
Igor Laevsky [Wed, 3 Jun 2015 16:18:58 +0000 (16:18 +0000)]
[Statepoints] Mark statepoint intrinsic with Throws attribute
Differential Revision: http://reviews.llvm.org/D10215
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238932
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Sanders [Wed, 3 Jun 2015 14:17:18 +0000 (14:17 +0000)]
[arm] Fix r238921. We must handle Constraint_i too.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238925
91177308-0d34-0410-b5e6-
96231b3b80d8
Asaf Badouh [Wed, 3 Jun 2015 13:41:48 +0000 (13:41 +0000)]
re-apply 238809
AVX-512: Implemented GETEXP instruction for KNL and SKX
Added rounding mode modifier for SQRTPS/PD
Added tests for encoding and intrinsics.
CR:
http://reviews.llvm.org/D9991
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238923
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Sanders [Wed, 3 Jun 2015 12:33:56 +0000 (12:33 +0000)]
[arm] Distinguish the /U[qytnms]/, 'Uv', 'Q', and 'm' inline assembly memory constraints.
Summary:
But still handle them the same way since I don't know how they differ on
this target.
Of these, /U[qytnms]/ do not have backend tests but are accepted by clang.
No functional change intended.
Reviewers: t.p.northover
Reviewed By: t.p.northover
Subscribers: t.p.northover, aemerson, llvm-commits
Differential Revision: http://reviews.llvm.org/D8203
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238921
91177308-0d34-0410-b5e6-
96231b3b80d8
Elena Demikhovsky [Wed, 3 Jun 2015 12:05:03 +0000 (12:05 +0000)]
AVX-512: More code improvements in shuffles, NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238919
91177308-0d34-0410-b5e6-
96231b3b80d8
Elena Demikhovsky [Wed, 3 Jun 2015 11:21:01 +0000 (11:21 +0000)]
AVX-512: VSHUFPD instruction selection - code improvements
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238918
91177308-0d34-0410-b5e6-
96231b3b80d8
Elena Demikhovsky [Wed, 3 Jun 2015 10:56:40 +0000 (10:56 +0000)]
AVX-512: Implemented SHUFF32x4/SHUFF64x2/SHUFI32x4/SHUFI64x2 instructions for SKX and KNL.
Added tests for encoding.
By Igor Breger (igor.breger@intel.com)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238917
91177308-0d34-0410-b5e6-
96231b3b80d8
Elena Demikhovsky [Wed, 3 Jun 2015 10:30:57 +0000 (10:30 +0000)]
X86: Added MPX feature and bound registers.
IntelĀ® Memory Protection Extensions (IntelĀ® MPX) is a new feature in Skylake.
It is a part of KNL and SKX sets. It is also a part of Skylake client.
I added definition of %bnd0 - %bnd3 registers, each register is a pair of 64-bit integers.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238916
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Sanders [Wed, 3 Jun 2015 10:27:28 +0000 (10:27 +0000)]
Re-commit r238838, r238844 with fix for host/target endian mismatch and windows buildbot.
The windows buildbot originally failed because the check expressions are
evaluated as 64-bit values, even for 32-bit symbols. Fixed this by comparing
bottom 32-bits of the expressions.
The host/target endian mismatch issue is that it's invalid to read/write target
values using a host pointer without taking care of endian differences between
the target and host. Most (if not all) instances of
reinterpret_cast<uint32_t*>() in the RuntimeDyld are examples of this bug.
This has been fixed for Mips using the endian aware read/write functions.
The original commits were:
r238838:
[mips] Add RuntimeDyld tests for currently supported O32 relocations.
Reviewers: petarj, vkalintiris
Reviewed By: vkalintiris
Subscribers: vkalintiris, llvm-commits
Differential Revision: http://reviews.llvm.org/D10126
r238844:
[mips][mcjit] Add support for R_MIPS_PC32.
Summary:
This allows us to resolve relocations for DW_EH_PE_pcrel TType encodings
in the exception handling LSDA.
Also fixed a nearby typo.
Reviewers: petarj, vkalintiris
Reviewed By: vkalintiris
Subscribers: vkalintiris, llvm-commits
Differential Revision: http://reviews.llvm.org/D10127
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238915
91177308-0d34-0410-b5e6-
96231b3b80d8
Vasileios Kalintiris [Wed, 3 Jun 2015 08:51:30 +0000 (08:51 +0000)]
Remove stray semicolon. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238908
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Wed, 3 Jun 2015 08:32:36 +0000 (08:32 +0000)]
[X86] Removed (unused) FSRL x86 operation
This patch removes the old X86ISD::FSRL op - which allowed float vectors to use the byte right shift operations (causing a domain switch....).
Since the refactoring of the shuffle lowering code this no longer has any use.
Differential Revision: http://reviews.llvm.org/D10169
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238906
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Wed, 3 Jun 2015 05:39:59 +0000 (05:39 +0000)]
This reverts commit r238838, r238844 and r238888.
Trying to bring back a windows bot:
http://lab.llvm.org:8011/builders/clang-x86-win2008-selfhost/builds/1224/steps/ninja%20check%202/logs/FAIL%3A%20LLVM%3A%3AELF_O32_PIC_relocations.s
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238903
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Wed, 3 Jun 2015 05:32:44 +0000 (05:32 +0000)]
Revert "make reciprocal estimate code generation more flexible by adding command-line options (2nd try)"
This reverts commit r238842.
It broke -DBUILD_SHARED_LIBS=ON build.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238900
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Wed, 3 Jun 2015 05:14:22 +0000 (05:14 +0000)]
Fix the interpretation of a 0 st_name.
The ELF spec is very clear:
-----------------------------------------------------------------------------
If the value is non-zero, it represents a string table index that gives the
symbol name. Otherwise, the symbol table entry has no name.
--------------------------------------------------------------------------
In particular, a st_name of 0 most certainly doesn't mean that the symbol has
the same name as the section.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238899
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Wed, 3 Jun 2015 04:48:06 +0000 (04:48 +0000)]
Move to llvm-objdump a large amount of code to that is only used there.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238898
91177308-0d34-0410-b5e6-
96231b3b80d8
Justin Bogner [Wed, 3 Jun 2015 02:48:09 +0000 (02:48 +0000)]
llvm-cov: Make llvm-cov --version DTRT
In r233132 we started requiring a subcommand in llvm-cov, but this
made `llvm-cov --version` invalid, which is kind of silly. Print
version information in this case, as most people would expect.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238897
91177308-0d34-0410-b5e6-
96231b3b80d8
Filipe Cabecinhas [Wed, 3 Jun 2015 01:30:13 +0000 (01:30 +0000)]
[BitcodeReader] Diagnose type mismatches with aliases
Bug found with AFL fuzz.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238895
91177308-0d34-0410-b5e6-
96231b3b80d8
Filipe Cabecinhas [Wed, 3 Jun 2015 01:30:08 +0000 (01:30 +0000)]
[Bitcode] Minimize the test to not conflict with others
Source for the test:
@bloom = global <3 x i32> <i32 0, i32 1, i32 42>
Plus bit twiddling to set the vector numelts to 0 (in the bc file).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238894
91177308-0d34-0410-b5e6-
96231b3b80d8
Filipe Cabecinhas [Wed, 3 Jun 2015 00:05:30 +0000 (00:05 +0000)]
[BitcodeReader] Check vector size before trying to create a VectorType
Bug found with AFL fuzz
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238891
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Wed, 3 Jun 2015 00:02:40 +0000 (00:02 +0000)]
Avoid a call to getOrCreateSymbol when we already have the symbol.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238890
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Tue, 2 Jun 2015 23:56:53 +0000 (23:56 +0000)]
Int128 is also a built-in preconstructed type.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238889
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Sanders [Tue, 2 Jun 2015 23:20:40 +0000 (23:20 +0000)]
[mips] XFAIL ELF_O32_PIC_relocations.s for big-endian mips
The test exposes pre-existing bugs when the endian of the host and target do
not match.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238888
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Tue, 2 Jun 2015 22:52:13 +0000 (22:52 +0000)]
Clarify when we can avoid creating names for temp symbols.
Some temporary symbols are created by MC itself. These symbols are never used
for lookup and are never included in the object symbol table, so we can
avoid creating a name for them.
Other temporaries are created by CodeGen or by the user by explicitly asking
for a name starting with .L (or L on MachO).
These temporaries behave like regular symbols, we just try to avoid including
them in the object symbol table, but sometimes they end up there:
const char *foo() {
return "abc" + 3;
}
will have a relocation pointing to a .L symbol.
It just so happens that almost all MC created temporary has the AlwaysAddSuffix
option and CodeGen/user created ones don't.
One interesting future optimization would be to use unnamed symbols for
all temporaries, but that would require use an st_name of 0 or
having the object writer create the names if a symbol does end up in the
symbol table.
No testcase since this just avoid creating a few extra names for MC created
temporaries.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238887
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjoy Das [Tue, 2 Jun 2015 22:33:39 +0000 (22:33 +0000)]
[NFC] Fix spelling in comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238884
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjoy Das [Tue, 2 Jun 2015 22:33:37 +0000 (22:33 +0000)]
[RewriteStatepointsForGC] Strip deref info after rewriting.
Summary:
Once a gc.statepoint has been rewritten to relocate live references, the
SSA values represent physical pointers instead of logical references.
Logical dereferencability does not imply physical dereferencability and
after RewriteStatepointsForGC has run any attributes that imply
dereferencability of the logical references need to be stripped.
This current approach is conservative, and can be made more precise
later if needed. For starters, we need to strip dereferencable
attributes only from pointers that live in the GC address space.
Reviewers: reames, pgavlin
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D10105
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238883
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjoy Das [Tue, 2 Jun 2015 22:33:34 +0000 (22:33 +0000)]
[NFCI] Change RewriteStatepointsForGC to a ModulePass.
Summary:
A later change that has RewriteStatepointsForGC change function
attributes throughout the module depends on this.
Reviewers: reames, pgavlin
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D10104
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238882
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjoy Das [Tue, 2 Jun 2015 22:33:30 +0000 (22:33 +0000)]
[SelectionDAG] Fix PR23603.
Summary:
LLVM's MI level notion of invariant_load is different from LLVM's IR
level notion of invariant_load with respect to dereferenceability. The
IR notion of invariant_load only guarantees that all *non-faulting*
invariant loads result in the same value. The MI notion of invariant
load guarantees that the load can be legally moved to any location
within its containing function. The MI notion of invariant_load is
stronger than the IR notion of invariant_load -- an MI invariant_load is
an IR invariant_load + a guarantee that the location being loaded from
is dereferenceable throughout the function's lifetime.
Reviewers: hfinkel, reames
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D10075
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238881
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Tue, 2 Jun 2015 21:30:13 +0000 (21:30 +0000)]
Pass a MCSymbolELF to a few ELF only functions. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238868
91177308-0d34-0410-b5e6-
96231b3b80d8
Filipe Cabecinhas [Tue, 2 Jun 2015 21:25:08 +0000 (21:25 +0000)]
[IR/AsmWriter] Output escape sequences if the first character isdigit()
If the first character in a metadata attachment's name is a digit, it has
to be output using an escape sequence, otherwise it's not valid text IR.
Removed an over-zealous assert from LLVMContext which didn't allow this.
The rule should only apply to text IR. Actual names can have any sequence
of non-NUL bytes.
Also added some documentation on accepted names.
Bug found with AFL fuzz.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238867
91177308-0d34-0410-b5e6-
96231b3b80d8
Filipe Cabecinhas [Tue, 2 Jun 2015 21:25:03 +0000 (21:25 +0000)]
CHECK-LABEL-ize test. NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238866
91177308-0d34-0410-b5e6-
96231b3b80d8
Filipe Cabecinhas [Tue, 2 Jun 2015 21:25:00 +0000 (21:25 +0000)]
clang-format a few functions. NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238865
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Tue, 2 Jun 2015 20:38:46 +0000 (20:38 +0000)]
Merge MCELF.h into MCSymbolELF.h.
Now that we have a dedicated type for ELF symbol, these helper functions can
become member function of MCSymbolELF.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238864
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Sanders [Tue, 2 Jun 2015 20:32:50 +0000 (20:32 +0000)]
[mips] Make TTypeEncoding indirect to allow .eh_frame to be read-only.
Summary:
Following on from r209907 which made personality encodings indirect, do the
same for TType encodings. This fixes the case where a try/catch block needs
to generate references to, for example, std::exception in the
.gcc_except_table.
Previous attempts at committing this broke the buildbots due to bugs in IAS.
These bugs have now been fixed so trying again.
Reviewers: petarj
Reviewed By: petarj
Subscribers: srhines, joerg, tberghammer, llvm-commits
Differential Revision: http://reviews.llvm.org/D9669
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238863
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Tue, 2 Jun 2015 18:37:20 +0000 (18:37 +0000)]
AArch64: fix typo in SMIN far atomics and add tests
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238858
91177308-0d34-0410-b5e6-
96231b3b80d8
Duncan P. N. Exon Smith [Tue, 2 Jun 2015 17:17:44 +0000 (17:17 +0000)]
DebugInfo: Really support 2^16 arguments in a subprogram
As a follow-up to r235955, actually support up to 65535 arguments in a
subprogram. r235955 missed assembly support, having only tested the new
limit via C++ unit tests. Code patch by Amjad Aboud.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238854
91177308-0d34-0410-b5e6-
96231b3b80d8
Duncan P. N. Exon Smith [Tue, 2 Jun 2015 17:13:25 +0000 (17:13 +0000)]
DebugInfo: Rename testcases from MD* to DI*, NFC
As a follow-up to r236120, rename testcases to match the new names.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238853
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Sanders [Tue, 2 Jun 2015 15:28:29 +0000 (15:28 +0000)]
[mips][mcjit] Add support for R_MIPS_PC32.
Summary:
This allows us to resolve relocations for DW_EH_PE_pcrel TType encodings
in the exception handling LSDA.
Also fixed a nearby typo.
Reviewers: petarj, vkalintiris
Reviewed By: vkalintiris
Subscribers: vkalintiris, llvm-commits
Differential Revision: http://reviews.llvm.org/D10127
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238844
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Tue, 2 Jun 2015 15:28:27 +0000 (15:28 +0000)]
Push constness through LoopInfo::isLoopHeader and clean it up a bit.
NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238843
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Tue, 2 Jun 2015 15:28:15 +0000 (15:28 +0000)]
make reciprocal estimate code generation more flexible by adding command-line options (2nd try)
The first try (r238051) to land this was reverted due to bot failures
that were hopefully addressed by r238788.
This patch adds a TargetRecip class for processing many recip codegen possibilities.
The class is intended to handle both command-line options to llc as well
as options passed in from a front-end such as clang with the -mrecip option.
The x86 backend is updated to use the new functionality.
Only -mcpu=btver2 with -ffast-math should see a functional change from this patch.
All other x86 CPUs continue to *not* use reciprocal estimates by default with -ffast-math.
Differential Revision: http://reviews.llvm.org/D8982
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238842
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Sanders [Tue, 2 Jun 2015 15:01:25 +0000 (15:01 +0000)]
[mips] Add RuntimeDyld tests for currently supported O32 relocations.
Reviewers: petarj, vkalintiris
Reviewed By: vkalintiris
Subscribers: vkalintiris, llvm-commits
Differential Revision: http://reviews.llvm.org/D10126
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238838
91177308-0d34-0410-b5e6-
96231b3b80d8
Elena Demikhovsky [Tue, 2 Jun 2015 14:12:54 +0000 (14:12 +0000)]
AVX-512: Implemented VRANGESD and VRANGESS instructions for SKX Implemented DAG lowering for all these forms.
Added tests for encoding.
By Igor Breger (igor.breger@intel.com)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238834
91177308-0d34-0410-b5e6-
96231b3b80d8
Elena Demikhovsky [Tue, 2 Jun 2015 13:43:18 +0000 (13:43 +0000)]
AVX-512: Shorten implementation of lowerV16X32VectorShuffle()
using lowerVectorShuffleWithSHUFPS() and other shuffle-helpers routines.
Added matching of VALIGN instruction.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238830
91177308-0d34-0410-b5e6-
96231b3b80d8
Vasileios Kalintiris [Tue, 2 Jun 2015 13:14:46 +0000 (13:14 +0000)]
[mips] Add support for dynamic stack realignment.
Summary:
With this change we are able to realign the stack dynamically, whenever it
contains objects with alignment requirements that are larger than the
alignment specified from the given ABI.
We have to use the $fp register as the frame pointer when we perform
dynamic stack realignment. In complex stack frames, with variably-sized
objects, we reserve additionally the callee-saved register $s7 as the
base pointer in order to reference locals.
Reviewers: dsanders
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D8633
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238829
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Tue, 2 Jun 2015 12:05:27 +0000 (12:05 +0000)]
Simplify now that we always use an alignment of 2 for ELF files.
This saves 123144 bytes out of llvm-nm on powerpc64le.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238824
91177308-0d34-0410-b5e6-
96231b3b80d8
Renato Golin [Tue, 2 Jun 2015 11:47:30 +0000 (11:47 +0000)]
Revert "ARM: Thumb2 LDRD/STRD supports independent input/output regs"
This reverts commit r238795, as it broke the Thumb2 self-hosting buildbot.
Since self-hosting issues with Clang are hard to investigate, I'm taking the
liberty to revert now, so we can investigate it offline.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238821
91177308-0d34-0410-b5e6-
96231b3b80d8
Vladimir Sukharev [Tue, 2 Jun 2015 10:58:41 +0000 (10:58 +0000)]
[AArch64] Add v8.1a atomic instructions
Patch by: Tom Coxon
Reviewers: t.p.northover
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D8501
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238818
91177308-0d34-0410-b5e6-
96231b3b80d8
Toma Tabacu [Tue, 2 Jun 2015 10:34:10 +0000 (10:34 +0000)]
[mips] [IAS] Reformat mips-expansions.s. NFC.
Summary:
Make mips-expansions.s more readable by grouping the instructions with their respective CHECK's.
This test is going to get a lot bigger soon and it will become essentially unreadable if the current formatting is kept.
I've also made the comments more useful and accurate, and I've restricted the RUN lines to under 80 columns.
Reviewers: dsanders
Reviewed By: dsanders
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D10089
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238817
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Sanders [Tue, 2 Jun 2015 10:09:08 +0000 (10:09 +0000)]
[mips] Test both %dtprel_hi and %dtprel_lo instead of testing %dtprel_hi twice.
The second %dtprel_hi is used on an addiu so it looks like a copy/paste error.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238815
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Sanders [Tue, 2 Jun 2015 10:02:00 +0000 (10:02 +0000)]
[mips] Expand tabs in test/MC/Mips/mips-relocations.s
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238814
91177308-0d34-0410-b5e6-
96231b3b80d8
Toma Tabacu [Tue, 2 Jun 2015 09:48:04 +0000 (09:48 +0000)]
[mips] [IAS] Add support for the .set softfloat/hardfloat directives.
Summary: These directives are used to set the current value of the SoftFloat feature.
Reviewers: dsanders
Reviewed By: dsanders
Subscribers: llvm-commits, mpf
Differential Revision: http://reviews.llvm.org/D9074
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238813
91177308-0d34-0410-b5e6-
96231b3b80d8
Elena Demikhovsky [Tue, 2 Jun 2015 08:28:57 +0000 (08:28 +0000)]
AVX-512: Implemented VFIXUPIMMSD and VFIXUPIMMSS instructions for KNL
Implemented DAG lowering for all these forms.
Added tests for encoding.
By Igor Breger (igor.breger@intel.com)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238811
91177308-0d34-0410-b5e6-
96231b3b80d8
Asaf Badouh [Tue, 2 Jun 2015 07:45:19 +0000 (07:45 +0000)]
revert 238809
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238810
91177308-0d34-0410-b5e6-
96231b3b80d8
Asaf Badouh [Tue, 2 Jun 2015 07:18:14 +0000 (07:18 +0000)]
AVX-512: Implemented GETEXP instruction for KNL and SKX
Added rounding mode modifier for SQRTPS/PD
Added tests for encoding and intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238809
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Tue, 2 Jun 2015 06:19:28 +0000 (06:19 +0000)]
[TableGen] Use range-based for loops. NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238808
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Tue, 2 Jun 2015 06:19:25 +0000 (06:19 +0000)]
Fix typo in comment. NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238807
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Tue, 2 Jun 2015 04:15:57 +0000 (04:15 +0000)]
[TableGen] Rename ListInit::getSize to just 'size' to be more consistent.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238806
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Tue, 2 Jun 2015 04:15:51 +0000 (04:15 +0000)]
[TableGen] Use range-based for loops. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238805
91177308-0d34-0410-b5e6-
96231b3b80d8
Davide Italiano [Tue, 2 Jun 2015 01:52:28 +0000 (01:52 +0000)]
[RuntimeDydlELF] Use range-based loop.
Differential Revision: http://reviews.llvm.org/D10165
Reviewed by: rafael
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238804
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Tue, 2 Jun 2015 00:25:12 +0000 (00:25 +0000)]
Create a MCSymbolELF.
This create a MCSymbolELF class and moves SymbolSize since only ELF
needs a size expression.
This reduces the size of MCSymbol from 56 to 48 bytes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238801
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Mon, 1 Jun 2015 23:55:06 +0000 (23:55 +0000)]
MC: Tidy up LOH naming a bit. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238800
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Mon, 1 Jun 2015 23:55:02 +0000 (23:55 +0000)]
MC: Tidy up formatting a bit. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238799
91177308-0d34-0410-b5e6-
96231b3b80d8
David Majnemer [Mon, 1 Jun 2015 23:45:25 +0000 (23:45 +0000)]
[Support] Simplify Triple::getOSVersion
Those who are interested in the Android version can use
getEnvironmentVersion instead of getOSVersion.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238798
91177308-0d34-0410-b5e6-
96231b3b80d8
David Majnemer [Mon, 1 Jun 2015 23:38:09 +0000 (23:38 +0000)]
[ADT] Add Triple::getEnvironmentVersion
This allows us to extract version numbers from the environment.
getOSVersion is currently overloaded for that purpose, this allows us to
clean it up.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238796
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Mon, 1 Jun 2015 23:27:08 +0000 (23:27 +0000)]
ARM: Thumb2 LDRD/STRD supports independent input/output regs
The existing code would unnecessarily break LDRD/STRD apart with
non-adjacent registers, on thumb2 this is not necessary.
Ideally on thumb2 we shouldn't match for ldrd/strd pre-regalloc anymore
as there is not reason to set register hints anymore, changing that is
something for a future patch however.
Differential Revision: http://reviews.llvm.org/D9694
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238795
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Mon, 1 Jun 2015 22:31:17 +0000 (22:31 +0000)]
AArch64: Use CMP;CCMP sequences for and/or/setcc trees.
Previously CCMP/FCCMP instructions were only used by the
AArch64ConditionalCompares pass for control flow. This patch uses them
for SELECT like instructions as well by matching patterns in ISelLowering.
PR20927, rdar://
18326194
Differential Revision: http://reviews.llvm.org/D8232
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238793
91177308-0d34-0410-b5e6-
96231b3b80d8
Alexei Starovoitov [Mon, 1 Jun 2015 22:24:36 +0000 (22:24 +0000)]
[bpf] fix build
fix breakage due to r238634
Patch by Vijay Subramanian.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238792
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Mon, 1 Jun 2015 22:24:01 +0000 (22:24 +0000)]
Move the name pointer out of Value into a map that lives on the
LLVMContext. Production builds of clang do not set names on most
Value's, so this is wasted space on almost all subclasses of Value.
This reduces the size of all Value subclasses by 8 bytes on 64 bit
hosts.
The one tricky part of this change is averting compile time regression
by keeping Value::hasName() fast. This required stealing bits out of
NumOperands.
With this change, peak memory usage on verify-uselistorder-nodbg.lto.bc
is decreased by approximately 2.3% (~3MB absolute on my machine).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238791
91177308-0d34-0410-b5e6-
96231b3b80d8
Frederic Riss [Mon, 1 Jun 2015 22:03:05 +0000 (22:03 +0000)]
[dsymutil] Remove extraneous std::move of local in return statement.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238790
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Arsenault [Mon, 1 Jun 2015 21:58:24 +0000 (21:58 +0000)]
R600/SI: Don't hardcode pointer type
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238789
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Mon, 1 Jun 2015 21:56:56 +0000 (21:56 +0000)]
add missing dependency for ExecutionEngine lib
This appears to be masked most of the time, but the problem
was exposed on some bots by r238051.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238788
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Mon, 1 Jun 2015 21:26:26 +0000 (21:26 +0000)]
LiveRangeEdit: Fix liveranges not shrinking on subrange kill.
If a dead instruction we may not only have a last-use in the main live
range but also in a subregister range if subregisters are tracked. We
need to partially rebuild live ranges in both cases.
The testcase only broke when subregister liveness was enabled. I
commited it in the current form because there is currently no flag to
enable/disable subregister liveness.
This fixes PR23720.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238785
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Mon, 1 Jun 2015 21:26:23 +0000 (21:26 +0000)]
ARMLoadStoreOptimizer: Fix doxygen comments; NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238784
91177308-0d34-0410-b5e6-
96231b3b80d8
Frederic Riss [Mon, 1 Jun 2015 21:25:53 +0000 (21:25 +0000)]
[dsymutil] Remove unnecessary ';'
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238783
91177308-0d34-0410-b5e6-
96231b3b80d8
Frederic Riss [Mon, 1 Jun 2015 21:12:45 +0000 (21:12 +0000)]
[dsymutil] Use YAMLIO to dump debug map.
Doing so will allow us to also accept a YAML debug map in input as using
YAMLIO gives us the parsing for free. Being able to have textual debug
maps will in turn allow much more control over the tests, because 1/
no need to check-in a binary containing the debug map and 2/ it will allow
to use the same objects/IR files with made-up debug-maps to test
different scenari.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238781
91177308-0d34-0410-b5e6-
96231b3b80d8
Peter Collingbourne [Mon, 1 Jun 2015 20:08:30 +0000 (20:08 +0000)]
Make the C++ LTO API easier to use from C++ clients.
Start using C++ types such as StringRef and MemoryBuffer in the C++ LTO
API. In doing so, clarify the ownership of the native object file: the caller
now owns it, not the LTOCodeGenerator. The C libLTO library has been modified
to use a derived class of LTOCodeGenerator that owns the object file.
Differential Revision: http://reviews.llvm.org/D10114
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238776
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Mon, 1 Jun 2015 19:20:47 +0000 (19:20 +0000)]
Revert "[Hexagon] Adding basic ELF relocation generation and testing advanced relaxation codepath."
This reverts commit r238748.
It broke the msan bot:
http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-fast/builds/4372/steps/check-llvm%20msan/logs/stdio
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238772
91177308-0d34-0410-b5e6-
96231b3b80d8
Arnold Schwaighofer [Mon, 1 Jun 2015 17:50:03 +0000 (17:50 +0000)]
lit: Allow configurations to restrict the set of tests to run
By setting limit_to_features to a non empty list of features a configuration can
restrict the set of tests to run to only include tests that require a feature in
this list.
rdar://
21082253
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238766
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Mon, 1 Jun 2015 17:26:30 +0000 (17:26 +0000)]
Disable MachineSink on convergent operations, similar to how IR Sink is
restricted. No test because no in-tree target currently has convergent
MachineInstr's.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238763
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Mon, 1 Jun 2015 17:20:31 +0000 (17:20 +0000)]
Teach the IR Sink pass to (conservatively) respect convergent annotations.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238762
91177308-0d34-0410-b5e6-
96231b3b80d8
Vasileios Kalintiris [Mon, 1 Jun 2015 16:40:45 +0000 (16:40 +0000)]
[mips][FastISel] Implement bswap.
Summary: Implement bswap intrinsic for MIPS FastISel. It's very different for misp32 r1/r2 .
Based on a patch by Reed Kotler.
Test Plan:
bswap1.ll
test-suite
Reviewers: dsanders, rkotler
Subscribers: llvm-commits, rfuhler
Differential Revision: http://reviews.llvm.org/D7219
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238760
91177308-0d34-0410-b5e6-
96231b3b80d8
Vasileios Kalintiris [Mon, 1 Jun 2015 16:36:01 +0000 (16:36 +0000)]
[mips][FastISel] Implement intrinsics memset, memcopy & memmove.
Summary:
Implement the intrinsics memset, memcopy and memmove in MIPS FastISel.
Make some needed infrastructure fixes so that this can work.
Based on a patch by Reed Kotler.
Test Plan:
memtest1.ll
The patch passes test-suite for mips32 r1/r2 and at O0/O2
Reviewers: rkotler, dsanders
Subscribers: llvm-commits, rfuhler
Differential Revision: http://reviews.llvm.org/D7158
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238759
91177308-0d34-0410-b5e6-
96231b3b80d8
Vasileios Kalintiris [Mon, 1 Jun 2015 16:17:37 +0000 (16:17 +0000)]
[mips][FastISel] Implement srem/urem and sdiv/udiv instructions.
Summary: Implement the LLVM assembly urem/srem and sdiv/udiv instructions in MIPS FastISel.
Based on a patch by Reed Kotler.
Test Plan:
srem1.ll
div1.ll
test-suite at O0/O2 for mips32 r1/r2
Reviewers: dsanders, rkotler
Subscribers: llvm-commits, rfuhler
Differential Revision: http://reviews.llvm.org/D7028
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238757
91177308-0d34-0410-b5e6-
96231b3b80d8
Vasileios Kalintiris [Mon, 1 Jun 2015 15:56:40 +0000 (15:56 +0000)]
[mips][FastISel] Implement the select statement for MIPS FastISel.
Summary: Implement the LLVM IR select statement for MIPS FastISelsel.
Based on a patch by Reed Kotler.
Test Plan:
"Make check" test included now.
Passes test-suite at O2/O0 mips32 r1/r2.
Reviewers: dsanders, rkotler
Subscribers: llvm-commits, rfuhler
Differential Revision: http://reviews.llvm.org/D6774
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238756
91177308-0d34-0410-b5e6-
96231b3b80d8
Vasileios Kalintiris [Mon, 1 Jun 2015 15:48:09 +0000 (15:48 +0000)]
[mips][FastISel] Clobber HI0/LO0 registers in MUL instructions.
Summary:
The contents of the HI/LO registers are unpredictable after the execution of
the MUL instruction. In addition to implicitly defining these registers in the
MUL instruction definition, we have to mark those registers as dead too.
Without this the fast register allocator is running out of registers when the
MUL instruction is followed by another one that tries to allocate the AC0
register.
Based on a patch by Reed Kotler.
Reviewers: dsanders, rkotler
Subscribers: llvm-commits, rfuhler
Differential Revision: http://reviews.llvm.org/D9825
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238755
91177308-0d34-0410-b5e6-
96231b3b80d8
Hans Wennborg [Mon, 1 Jun 2015 15:37:58 +0000 (15:37 +0000)]
Drop remaining Dragonegg support in release scripts
r236077 and r236081 dropped Dragonegg support from the release scripts
but left some pieces. The most notable change is that Dragonegg won't
be tagged any more.
Patch by David Wiberg <dwiberg@gmail.com>.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238753
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Mon, 1 Jun 2015 15:10:51 +0000 (15:10 +0000)]
Fix relocation selection for foo-. on mips.
This handles only the 32 bit case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238751
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Mon, 1 Jun 2015 14:58:29 +0000 (14:58 +0000)]
Simplify code, NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238750
91177308-0d34-0410-b5e6-
96231b3b80d8
Artur Pilipenko [Mon, 1 Jun 2015 14:53:55 +0000 (14:53 +0000)]
Add isConstant argument to MDBuilder::createTBAAStructTagNode
According to the TBAA description struct-path tag node can have an optional IsConstant field. Add corresponding argument to MDBuilder::createTBAAStructTagNode.
Reviewed By: hfinkel
Differential Revision: http://reviews.llvm.org/D10160
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@238749
91177308-0d34-0410-b5e6-
96231b3b80d8