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.
llvm-svn: 238943
Daniel Jasper [Wed, 3 Jun 2015 17:08:40 +0000 (17:08 +0000)]
clang-format: [JS] Let fat arrows have 'Equality' precedence.
This fixes a regression in literal formatting:
Before:
aaaaaaaaaaaaa = {
aaaaaaaaaaaaaaaaaaaaaaaaaaaa: (
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa,
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa) =>
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa,
};
After:
var
aaaaaaaaaaaaaaaaaaaa = {
aaaaaaaaaaaaaaaaaaaaaaaaaaaa:
(
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa,
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa) =>
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa,
};
Also apply no-else-after-return policy.
llvm-svn: 238942
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.
llvm-svn: 238941
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.
llvm-svn: 238940
Frederic Riss [Wed, 3 Jun 2015 16:57:07 +0000 (16:57 +0000)]
[dsymutil] Reflow option declarations to be more readable.
llvm-svn: 238939
Douglas Katzman [Wed, 3 Jun 2015 16:56:50 +0000 (16:56 +0000)]
Fix misleading comment. NFC
llvm-svn: 238938
Rui Ueyama [Wed, 3 Jun 2015 16:50:41 +0000 (16:50 +0000)]
Fix typo.
llvm-svn: 238937
Rui Ueyama [Wed, 3 Jun 2015 16:44:00 +0000 (16:44 +0000)]
COFF: Change OutputSections' type from vector<unique_ptr<T>> to vector<T*>.
This is mainly for readability. OutputSection objects are still owned
by the writer using SpecificBumpPtrAllocator.
llvm-svn: 238936
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.
llvm-svn: 238935
Jonathan Peyton [Wed, 3 Jun 2015 16:23:36 +0000 (16:23 +0000)]
Remove unused variable anonym from kmp_atomic.c
There is an anonym variable inside a macro that is declared and defined
but never used. This patch removes it.
http://lists.cs.uiuc.edu/pipermail/openmp-dev/2015-June/000666.html
Patch by Jack Howarth and Jonathan Peyton
llvm-svn: 238934
Diego Novillo [Wed, 3 Jun 2015 16:22:12 +0000 (16:22 +0000)]
Fix typo in comment. NFC.
llvm-svn: 238933
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
llvm-svn: 238932
Marshall Clow [Wed, 3 Jun 2015 16:15:55 +0000 (16:15 +0000)]
Add 'is_always_equal' tests for scoped_allocator. Found that I had typed '||' where I meant '&&' in the code; fixed that, too
llvm-svn: 238931
Tobias Grosser [Wed, 3 Jun 2015 15:45:19 +0000 (15:45 +0000)]
[doc] Rename -polly-detect-only= to -polly-only-func=
llvm-svn: 238930
Tobias Grosser [Wed, 3 Jun 2015 15:14:58 +0000 (15:14 +0000)]
Lower signed-divisions without rounding to ashr instructions
llvm-svn: 238929
Russell Gallop [Wed, 3 Jun 2015 15:09:13 +0000 (15:09 +0000)]
[utils] Improvements to check_cfc.py to work better with some build systems.
Recognise options to output dependency files and don't perform checks.
Report input file name when reporting a check failure so it is more obvious in large build logs.
Differential Revision: http://reviews.llvm.org/D10183
llvm-svn: 238928
Tobias Grosser [Wed, 3 Jun 2015 14:43:01 +0000 (14:43 +0000)]
Only convert power-of-two floor-division with non-negative denominator
floord(a,b) === a ashr log_2 (b) holds for positive and negative a's, but
shifting only makes sense for positive values of b. The previous patch did
not consider this as isl currently always produces postive b's. To avoid future
surprises, we check that b is positive and only then apply the optimization.
We also now correctly check the return value of the dyn-cast.
No additional test case, as isl currently does not produce negative
denominators.
Reported-by: David Majnemer <david.majnemer@gmail.com>
llvm-svn: 238927
Russell Gallop [Wed, 3 Jun 2015 14:33:57 +0000 (14:33 +0000)]
[utils] Add exact check to check_cfc.py dash_s_no_change.
Files compiled with -via-file-asm should be byte for byte identical. This
change improves the checking on dash_s_no_change to detect non-code
differences. If there is a difference, the check goes on to compare code and
debug to try and be more informative.
llvm-svn: 238926
Daniel Sanders [Wed, 3 Jun 2015 14:17:18 +0000 (14:17 +0000)]
[arm] Fix r238921. We must handle Constraint_i too.
llvm-svn: 238925
Asaf Badouh [Wed, 3 Jun 2015 13:42:46 +0000 (13:42 +0000)]
minor test fix
llvm-svn: 238924
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
llvm-svn: 238923
Manuel Klimek [Wed, 3 Jun 2015 13:10:41 +0000 (13:10 +0000)]
Allow replacements created from token ranges to specify language options.
The default language options will lead to incorrect replacements in C++
code, for example when trying to replace nested name specifiers ending
in "::".
llvm-svn: 238922
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
llvm-svn: 238921
Elena Demikhovsky [Wed, 3 Jun 2015 12:05:03 +0000 (12:05 +0000)]
AVX-512: More code improvements in shuffles, NFC
llvm-svn: 238919
Elena Demikhovsky [Wed, 3 Jun 2015 11:21:01 +0000 (11:21 +0000)]
AVX-512: VSHUFPD instruction selection - code improvements
llvm-svn: 238918
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)
llvm-svn: 238917
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.
llvm-svn: 238916
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
llvm-svn: 238915
Sagar Thakur [Wed, 3 Jun 2015 10:14:24 +0000 (10:14 +0000)]
[MIPS][lldb-server] Add 32-bit register context and read/write FP registers on mips64
- Added support for read/write FP registers in FR1 mode.
- Added 32 bit register context for mips32.
Reviewers: clayborg, tberghammer, jaydeep
Subscribers: emaste, nitesh.jain, bhushan, mohit.bhakkad, lldb-commits
Differential Revision: http://reviews.llvm.org/D10029
llvm-svn: 238914
Enrico Pertoso [Wed, 3 Jun 2015 10:12:40 +0000 (10:12 +0000)]
Append CXXDefaultInitExpr's wrapped expression to the CFG when visiting a constructor initializer
Summary:
This patch is part of http://llvm-reviews.chandlerc.com/D2181.
In-class initializers are appended to the CFG when CFGBuilder::addInitializer is called.
Reviewers: jordan_rose, rsmith
Reviewed By: jordan_rose
Subscribers: cfe-commits, klimek
Differential Revision: http://reviews.llvm.org/D2370
llvm-svn: 238913
Vladimir Sukharev [Wed, 3 Jun 2015 10:11:42 +0000 (10:11 +0000)]
Fix typo in cross-compilation docs: "-fpu" -> "-mfpu"
Reviewers: rengolin
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D10209
llvm-svn: 238912
Daniel Jasper [Wed, 3 Jun 2015 09:26:03 +0000 (09:26 +0000)]
clang-format: Properly reset BreakBeforeParameter when wrapping
operators to the new line.
Before:
LOG_IF(aaa == //
bbb)
<< a
<< b;
After:
LOG_IF(aaa == //
bbb)
<< a << b;
llvm-svn: 238911
Enrico Pertoso [Wed, 3 Jun 2015 09:10:58 +0000 (09:10 +0000)]
Fixes a typo in a comment.
llvm-svn: 238910
Daniel Jasper [Wed, 3 Jun 2015 08:57:36 +0000 (08:57 +0000)]
clang-format: [JS] More aggressively keep array literals on one line.
Before:
var aaaaa: List<SomeThing> = [
new SomeThingAAAAAAAAAAAA(),
new SomeThingBBBBBBBBB()
];
After:
var aaaaa: List<SomeThing> =
[new SomeThingAAAAAAAAAAAA(), new SomeThingBBBBBBBBB()];
llvm-svn: 238909
Vasileios Kalintiris [Wed, 3 Jun 2015 08:51:30 +0000 (08:51 +0000)]
Remove stray semicolon. NFC.
llvm-svn: 238908
Daniel Jasper [Wed, 3 Jun 2015 08:43:18 +0000 (08:43 +0000)]
clang-format: [JS] Fix bug in type colon detection.
Before, this couldn't be formatted at all:
class X {
subs = {
'b': {
'c': 1,
},
};
}
llvm-svn: 238907
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
llvm-svn: 238906
Tobias Grosser [Wed, 3 Jun 2015 06:31:30 +0000 (06:31 +0000)]
Translate power-of-two floor-division into ashr
Power-of-two floor divisions can be translated into an arithmetic shift
operation. This allows us to replace a complex lowering that requires division
operations:
%pexp.fdiv_q.0 = sub i64 %21, 128
%pexp.fdiv_q.1 = add i64 %pexp.fdiv_q.0, 1
%pexp.fdiv_q.2 = icmp slt i64 %21, 0
%pexp.fdiv_q.3 = select i1 %pexp.fdiv_q.2, i64 %pexp.fdiv_q.1, i64 %21
%pexp.fdiv_q.4 = sdiv i64 %pexp.fdiv_q.3, 128
with a simple ashr:
%polly.fdiv_q.shr = ashr i64 %21, 7
llvm-svn: 238905
Rafael Espindola [Wed, 3 Jun 2015 05:44:28 +0000 (05:44 +0000)]
Revert "add the -mrecip driver flag and process its options (2nd try)"
This reverts commit r238851.
It depends on a llvm commit that was reverted.
llvm-svn: 238904
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
llvm-svn: 238903
Rui Ueyama [Wed, 3 Jun 2015 05:39:13 +0000 (05:39 +0000)]
COFF: Update README.
Avoid saying this is based on sections because it's not very accurate.
That we don't split section into smaller chunks of data does not mean
that the linker is built on top of that.
In reality, most part of the code do not care about underlying data,
so they are neither based on "atoms" nor sections.
The symbol table only cares about symbol names and their types.
The writer handles list of chunks, which look like just blobs,
and the writer doesn't care what those chunks are backed by.
The only thing that interact with sections is SectionChunk, which is
abstracted away as one type of Chunk.
llvm-svn: 238902
Rui Ueyama [Wed, 3 Jun 2015 05:39:12 +0000 (05:39 +0000)]
COFF: SymbolTable to manage symbols using BumpPtrAllocator.
llvm-svn: 238901
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.
llvm-svn: 238900
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.
llvm-svn: 238899
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.
llvm-svn: 238898
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.
llvm-svn: 238897
Greg Clayton [Wed, 3 Jun 2015 02:02:48 +0000 (02:02 +0000)]
Fixed "format-string" based settings so they can have quotes on them without leaving the quotes in the format string:
(lldb) settings set thread-format "abc"
(lldb) settings set thread-format 'abc'
(lldb) settings set thread-format abc
We strip the quotes before processing the format string and return an "error: mismatched quotes" if mismatched quotes are given.
<rdar://problem/
21210789>
llvm-svn: 238896
Filipe Cabecinhas [Wed, 3 Jun 2015 01:30:13 +0000 (01:30 +0000)]
[BitcodeReader] Diagnose type mismatches with aliases
Bug found with AFL fuzz.
llvm-svn: 238895
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).
llvm-svn: 238894
Greg Clayton [Wed, 3 Jun 2015 00:34:01 +0000 (00:34 +0000)]
Fixed a deadlock that was slowing down processes when they shut down. A 3 second delay could occur sometimes when a process exits, now that delay is gone.
llvm-svn: 238893
David Majnemer [Wed, 3 Jun 2015 00:26:35 +0000 (00:26 +0000)]
[Sema] Make the atomic builtins more efficient by reducing volatility
The parameter types and return type do not need to be volatile just
because the pointer type's pointee type is volatile qualified. This is
an unnecessary pessimization.
llvm-svn: 238892
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
llvm-svn: 238891
Rafael Espindola [Wed, 3 Jun 2015 00:02:40 +0000 (00:02 +0000)]
Avoid a call to getOrCreateSymbol when we already have the symbol.
llvm-svn: 238890
Nick Lewycky [Tue, 2 Jun 2015 23:56:53 +0000 (23:56 +0000)]
Int128 is also a built-in preconstructed type.
llvm-svn: 238889
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.
llvm-svn: 238888
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.
llvm-svn: 238887
Greg Clayton [Tue, 2 Jun 2015 22:43:29 +0000 (22:43 +0000)]
Fix LLDB so that it can correctly track down dependent shared libraries that use @rpath.
<rdar://problem/8371885>
llvm-svn: 238886
Douglas Katzman [Tue, 2 Jun 2015 22:40:27 +0000 (22:40 +0000)]
Fix typo in tutorial.
llvm-svn: 238885
Sanjoy Das [Tue, 2 Jun 2015 22:33:39 +0000 (22:33 +0000)]
[NFC] Fix spelling in comment.
llvm-svn: 238884
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
llvm-svn: 238883
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
llvm-svn: 238882
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
llvm-svn: 238881
Marshall Clow [Tue, 2 Jun 2015 22:26:29 +0000 (22:26 +0000)]
Revert changes inadvertantly committed
llvm-svn: 238880
Marshall Clow [Tue, 2 Jun 2015 22:25:23 +0000 (22:25 +0000)]
Move uncaught_exeption() definition inside the #ifdef block like uncaught_exceptions()
llvm-svn: 238879
Jonathan Peyton [Tue, 2 Jun 2015 22:21:37 +0000 (22:21 +0000)]
Get rid of some dead code.
Some old references to RML and IOMP which aren't used anywhere are deleted.
http://lists.cs.uiuc.edu/pipermail/openmp-dev/2015-June/000664.html
Patch by Jack Howarth and Jonathan Peyton
llvm-svn: 238878
David Majnemer [Tue, 2 Jun 2015 22:15:12 +0000 (22:15 +0000)]
[MSVC Compatibility] Permit static_cast from void-ptr to function-ptr
The MSVC 2013 and 2015 implementation of std::atomic is specialized for
pointer types. The member functions are implemented using a static_cast
from void-ptr to function-ptr which is not allowed in the standard.
Permit this conversion if -fms-compatibility is present.
This fixes PR23733.
llvm-svn: 238877
Douglas Katzman [Tue, 2 Jun 2015 22:06:32 +0000 (22:06 +0000)]
Correct DriverInternals.rst: ccc-print-options is gone.
Was removed in svn r189802.
llvm-svn: 238876
Daniel Jasper [Tue, 2 Jun 2015 22:06:07 +0000 (22:06 +0000)]
clang-format: [JS] Always add space after fat arrow.
Before:
return () =>[];
After:
return () => [];
llvm-svn: 238875
Tim Northover [Tue, 2 Jun 2015 21:59:04 +0000 (21:59 +0000)]
Tests: disable test of /proc filesystem on Darwin.
We don't have it. I'm not entirely sure "Posix" is a good name for that
directory, but perhaps we should see how it develops.
llvm-svn: 238874
Daniel Jasper [Tue, 2 Jun 2015 21:57:51 +0000 (21:57 +0000)]
clang-format: [JS] Array literal detection fix #4.
llvm-svn: 238873
Chaoren Lin [Tue, 2 Jun 2015 21:54:22 +0000 (21:54 +0000)]
Update TestConcurrentEvents to use UnixSignals instead of python signals.
Reviewers: clayborg, ovyalov
Reviewed By: ovyalov
Subscribers: lldb-commits
Differential Revision: http://reviews.llvm.org/D10195
llvm-svn: 238872
Greg Clayton [Tue, 2 Jun 2015 21:42:31 +0000 (21:42 +0000)]
Fixed the logic to determine the TRIPLE_VERSION correctly when it isn't specified.
llvm-svn: 238871
Marshall Clow [Tue, 2 Jun 2015 21:40:58 +0000 (21:40 +0000)]
Fix breakage that I introduced in r238848
llvm-svn: 238870
Greg Clayton [Tue, 2 Jun 2015 21:38:10 +0000 (21:38 +0000)]
Added the ability for the "make" command to take a triple:
% cd lldb/test/lang/c/array_types
% make TRIPLE=x86_64-apple-ios
% make clean
% make TRIPLE=x86_64-apple-ios8.1
% make clean
% make TRIPLE=armv7-apple-ios
% make clean
% make TRIPLE=armv7-apple-ios8.1
% make clean
The TRIPLE variable will automatically set the following variables:
SDKROOT if it isn't specified manually
ARCH will be set to the architecture from the triple
CFLAGS will include the extras needed for the triple which are set in TRIPLE_CFLAGS
TRIPLE_VENDOR set to the triple vendor ("apple" in the above cases)
TRIPLE_OS set to the triple OS ("ios" in the above cases)
TRIPLE_VERSION set to the version that was specified, or automatically set to the SDK version if it is missing
This allows you to change directory into any test case on MacOSX and quickly build for desktop:
% make
iOS simulator:
% make TRIPLE=x86_64-apple-ios
or iOS device:
% make TRIPLE=armv7-apple-ios
llvm-svn: 238869
Rafael Espindola [Tue, 2 Jun 2015 21:30:13 +0000 (21:30 +0000)]
Pass a MCSymbolELF to a few ELF only functions. NFC.
llvm-svn: 238868
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.
llvm-svn: 238867
Filipe Cabecinhas [Tue, 2 Jun 2015 21:25:03 +0000 (21:25 +0000)]
CHECK-LABEL-ize test. NFC
llvm-svn: 238866
Filipe Cabecinhas [Tue, 2 Jun 2015 21:25:00 +0000 (21:25 +0000)]
clang-format a few functions. NFC
llvm-svn: 238865
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.
llvm-svn: 238864
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
llvm-svn: 238863
Jim Ingham [Tue, 2 Jun 2015 20:26:13 +0000 (20:26 +0000)]
Fix up some comments to be more explicit. Remove some long-commented out code.
llvm-svn: 238862
Andrea Di Biagio [Tue, 2 Jun 2015 19:34:40 +0000 (19:34 +0000)]
[x86-64 ABI] Fix for PR23082: an assertion failure when passing/returning a wrapper union in a full YMM register.
This patch fixes an assertion failure in method
'X86_64ABIInfo::GetByteVectorType'.
Method 'GetByteVectorType' (in TargetInfo.cpp) is responsible
for mapping a QualType 'Ty' (for an argument or return value) to an LLVM IR
type that, according to the ABI, must be passed in a XMM/YMM vector register.
When selecting the IR vector type, method 'GetByteVectorType' always tries to
choose the "best" IR vector type for the 'Ty' in input. In particular, if Ty
is a wrapper structure, it keeps unwrapping it until it finds a vector type VTy.
That VTy is the "preferred IR type".
However, function 'isSingleElementStructure' (used to unwrap structures) does
not know how to look through union types. So, before this patch, if Ty was in
a nest of wrapper structures with at least two union types, we would have
triggered an assertion failure (added at revision 230971).
With this patch, if method 'GetByteVectorType' fails to find the preferred
vector type, we just return a valid (although potentially 'less friendly')
vector type based on the type size. So, rather than asserting on an 'unexpected'
'Ty' in input, we conservatively return vector type <2 x double> if Ty is 16
bytes, or <4 x double> if Ty is 32 bytes.
Differential Revision: http://reviews.llvm.org/D10190
llvm-svn: 238861
Oleksiy Vyalov [Tue, 2 Jun 2015 19:29:48 +0000 (19:29 +0000)]
Fix PlatformAndroid::PutFile to support relative destination paths.
llvm-svn: 238860
Chaoren Lin [Tue, 2 Jun 2015 19:07:26 +0000 (19:07 +0000)]
Use wildcard instead of relying on shell globbing.
Reviewers: clayborg, zturner
Subscribers: lldb-commits
Differential Revision: http://reviews.llvm.org/D10194
llvm-svn: 238859
Tim Northover [Tue, 2 Jun 2015 18:37:20 +0000 (18:37 +0000)]
AArch64: fix typo in SMIN far atomics and add tests
llvm-svn: 238858
Chaoren Lin [Tue, 2 Jun 2015 18:31:57 +0000 (18:31 +0000)]
Check that debugger is valid before enumerating targets.
Reviewers: sivachandra
Subscribers: lldb-commits
Differential Revision: http://reviews.llvm.org/D10192
llvm-svn: 238857
Ed Maste [Tue, 2 Jun 2015 18:29:42 +0000 (18:29 +0000)]
TestGlobalVariables no longer fails on FreeBSD
It has passed since ~ r223393.
llvm.org/21599
llvm-svn: 238856
Sanjay Patel [Tue, 2 Jun 2015 18:02:13 +0000 (18:02 +0000)]
add missing dependency for CodeGen lib
This looks to be exposed on some bots by r238851.
llvm-svn: 238855
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.
llvm-svn: 238854
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.
llvm-svn: 238853
Chaoren Lin [Tue, 2 Jun 2015 17:01:13 +0000 (17:01 +0000)]
Use new get_signal_number utility function for tests.
Summary:
This fixes TestLldbGdbServer and TestSendSignal from Windows to Android.
This change depends on D10171.
Reviewers: clayborg, ovyalov
Reviewed By: clayborg, ovyalov
Subscribers: tberghammer, lldb-commits
Differential Revision: http://reviews.llvm.org/D10172
llvm-svn: 238852
Sanjay Patel [Tue, 2 Jun 2015 16:55:12 +0000 (16:55 +0000)]
add the -mrecip driver flag and process its options (2nd try)
The first try to land this (r238055) was reverted due to bot failures
caused by the LLVM part of the patch. That was hopefully fixed by r238788,
and the LLVM patch was resubmitted at r238842.
This is the front-end counterpart to D8982.
The -mrecip option interface is based on maintaining compatibility with gcc:
https://gcc.gnu.org/onlinedocs/gcc-4.9.2/gcc/i386-and-x86-64-Options.html#index-mrecip_003dopt-1627
https://gcc.gnu.org/onlinedocs/gcc-4.9.2/gcc/RS_002f6000-and-PowerPC-Options.html#index-mrecip-2289
...while adding more functionality (allowing users to specify the number of refinement steps for each
estimate type).
Differential Revision: http://reviews.llvm.org/D8989
llvm-svn: 238851
Chaoren Lin [Tue, 2 Jun 2015 16:46:28 +0000 (16:46 +0000)]
Added utility function to get correct signal number from remote platform.
Summary:
This change adds a utility that uses the `kill -l` command to get the
correct signal number. Falls back to using `SBUnixSignals`, and finally
`signal.SIG<signal>` if all else fails.
Reviewers: tberghammer, clayborg, ovyalov
Reviewed By: clayborg, ovyalov
Subscribers: tberghammer, lldb-commits
Differential Revision: http://reviews.llvm.org/D10171
llvm-svn: 238850
Chaoren Lin [Tue, 2 Jun 2015 16:43:19 +0000 (16:43 +0000)]
Fix OBJCOPY and AR for Android.
Summary:
Previously, OBJCOPY was empty because of the missing comma,
and ar was just `ar`.
Reviewers: ovyalov, tberghammer
Subscribers: tberghammer, lldb-commits
Differential Revision: http://reviews.llvm.org/D10175
llvm-svn: 238849
Marshall Clow [Tue, 2 Jun 2015 16:34:03 +0000 (16:34 +0000)]
Implement the first part of N4258 - allocator_traits<X>::is_always_equal. Also fixes PR#23723
llvm-svn: 238848
Jonathan Peyton [Tue, 2 Jun 2015 16:19:44 +0000 (16:19 +0000)]
Remove unused KMP_IOMP_NAME macro from kmp.h
Getting rid of more iomp references.
http://lists.cs.uiuc.edu/pipermail/openmp-dev/2015-June/000659.html
llvm-svn: 238847
Marshall Clow [Tue, 2 Jun 2015 15:33:38 +0000 (15:33 +0000)]
Implement uncaught_exceptions() using the newly added hooks in libc++abi, when available
llvm-svn: 238846
Daniel Jasper [Tue, 2 Jun 2015 15:31:37 +0000 (15:31 +0000)]
clang-format: Don't try to detect C++ lambdas in other languages.
llvm-svn: 238845
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
llvm-svn: 238844
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.
llvm-svn: 238843