Zachary Turner [Tue, 10 Feb 2015 22:56:21 +0000 (22:56 +0000)]
Add missing function and header include.
llvm-svn: 228758
Oleksiy Vyalov [Tue, 10 Feb 2015 22:49:57 +0000 (22:49 +0000)]
Extract attach core logic from SBTarget::Attach* methods into unified SBTarget::AttachToProcess and make it work with platform for remote attach purposes.
http://reviews.llvm.org/D7471
llvm-svn: 228757
Zachary Turner [Tue, 10 Feb 2015 22:47:14 +0000 (22:47 +0000)]
Oops. Don't call Windows functions on non-windows.
llvm-svn: 228756
Zachary Turner [Tue, 10 Feb 2015 22:43:25 +0000 (22:43 +0000)]
Rewrite llvm-pdbdump in terms of LLVMDebugInfoPDB.
This makes llvm-pdbdump available on all platforms, although it
will currently fail to create a dumper if there is no PDB reader
implementation for the current platform.
It implements dumping of compilands and children, which is less
information than was previously available, but it has to be
rewritten from scratch using the new set of interfaces, so the
rest of the functionality will be added back in subsequent commits.
llvm-svn: 228755
David Majnemer [Tue, 10 Feb 2015 22:00:34 +0000 (22:00 +0000)]
X86: @llvm.frameaddress should defer to SelectionDAG for Win CFI
llvm-svn: 228754
Rui Ueyama [Tue, 10 Feb 2015 21:40:51 +0000 (21:40 +0000)]
GNU: Rename parseZOption because it actually parses only -z max-page-size.
llvm-svn: 228753
Zachary Turner [Tue, 10 Feb 2015 21:40:29 +0000 (21:40 +0000)]
Fix build due to mismatched function signatures.
llvm-svn: 228752
Simon Atanasyan [Tue, 10 Feb 2015 21:38:25 +0000 (21:38 +0000)]
[Object] Reformat the code with clang-format
No functional changes.
llvm-svn: 228751
Rui Ueyama [Tue, 10 Feb 2015 21:28:52 +0000 (21:28 +0000)]
Unittest: Do s/_context/_ctx/g.
llvm-svn: 228750
Rui Ueyama [Tue, 10 Feb 2015 21:27:31 +0000 (21:27 +0000)]
GNU: Add --no-export-dynamic command line option.
llvm-svn: 228749
David Majnemer [Tue, 10 Feb 2015 21:22:05 +0000 (21:22 +0000)]
X86: Make @llvm.frameaddress work correctly with Windows unwind codes
Simply loading or storing the frame pointer is not sufficient for
Windows targets. Instead, create a synthetic frame object that we will
lower later. References to this synthetic object will be replaced with
the correct reference to the frame address.
llvm-svn: 228748
Zachary Turner [Tue, 10 Feb 2015 21:17:52 +0000 (21:17 +0000)]
Provide DIA implementation of DebugInfoPDB.
This implements DebugInfoPDB when the DIA SDK is present on the system.
Specifically, this means that the following conditions are met:
1) You are building on Windows.
2) You are building with MSVC.
3) Visual Studio did not corrupt the installation of DIA due to a
known issue with side-by-side installations of VS2012 and VS2013.
If all of these conditions are true, you will be able to pass a value
of PDB_Reader::DIA to PDB::createPdbReader().
There are no tests for this yet, as any test will be in the form of a
lit test which tests the llvm-pdbdump.exe, which still needs to be
rewritten in terms of this library.
llvm-svn: 228747
Eric Christopher [Tue, 10 Feb 2015 21:15:06 +0000 (21:15 +0000)]
Reformat (and remove some tabs) to make debugging this code a
little easier to step through.
llvm-svn: 228746
Aaron Ballman [Tue, 10 Feb 2015 21:13:04 +0000 (21:13 +0000)]
Now use the __debugbreak intrinsic instead of calling RaiseException; it requires no forward declares and still calls VEH.
llvm-svn: 228745
Vince Harron [Tue, 10 Feb 2015 21:09:04 +0000 (21:09 +0000)]
Fix 'process launch -i' for remote processes
We want to forward stdin when stdio is not disabled and when we're not
redirecting stdin from a file.
renamed m_stdio_disable to m_stdin_forward and inverted value because
that's what we want to remember.
There was previously a bug that if you redirected stdin from a file,
stdout and stderr would also be redirected to /dev/null
Adds support for remote target to TestProcessIO.py
Fixes ProcessIOTestCase.test_stdin_redirection_with_dwarf for remote
Linux targets
llvm-svn: 228744
Rui Ueyama [Tue, 10 Feb 2015 20:57:43 +0000 (20:57 +0000)]
Driver: move non-positional parameters out of switch. NFC.
llvm-svn: 228743
Daniel Jasper [Tue, 10 Feb 2015 20:49:05 +0000 (20:49 +0000)]
Fix overly prescriptive test that broken on Mac after r228725.
llvm-svn: 228742
Nico Weber [Tue, 10 Feb 2015 20:43:54 +0000 (20:43 +0000)]
fix docs typo
llvm-svn: 228741
Kuba Brecka [Tue, 10 Feb 2015 20:37:57 +0000 (20:37 +0000)]
Fix ASan's Noinst unit tests
We currently skip all "Noinst" unit tests on OS X, which was probably caused when we removed the "allow_reexec" flag. The MaybeReexec function fails to re-execute when the runtime is linked statically, because there is no dylib to use. This patch adds an explicit DisableReexec function that is used from asan_noinst_test.cc and the runtime then doesn't try to re-execute.
Reviewed at http://reviews.llvm.org/D7493
llvm-svn: 228740
Bill Schmidt [Tue, 10 Feb 2015 20:36:08 +0000 (20:36 +0000)]
[PowerPC] Remove the --no-tls-optimize workaround from the clang driver
llvm-svn: 228739
Aaron Ballman [Tue, 10 Feb 2015 20:13:52 +0000 (20:13 +0000)]
Changing the status code generated by LLVM_BUILTIN_TRAP on Windows to be something categorized as a valid error code. Fixes crashing uses (such as not --crash) with existing sys::Wait behavior.
llvm-svn: 228738
Anton Yartsev [Tue, 10 Feb 2015 20:13:08 +0000 (20:13 +0000)]
[analyzer] Pass actual state to alloc/dealloc handling functions.
The state obtained from CheckerContext::getState() may be outdated by the time the alloc/dealloc handling function is called (e.g. the state was modified but the transition was not performed). State argument was added to all alloc/dealloc handling functions in order to get the latest state and to allow sequential calls to those functions.
llvm-svn: 228737
Andrey Churbanov [Tue, 10 Feb 2015 20:10:21 +0000 (20:10 +0000)]
Fixed memory corruption problem.
llvm-svn: 228736
Pete Cooper [Tue, 10 Feb 2015 19:53:38 +0000 (19:53 +0000)]
Check for backtraces in tests which are verifying pretty stack traces from a crashing clang.
PrettyStackTrace now requires the ENABLE_BACKTRACES option. We need to check for that here or these tests fail llvm-lit.
Reviewed by chandlerc
llvm-svn: 228735
Andrey Churbanov [Tue, 10 Feb 2015 19:53:13 +0000 (19:53 +0000)]
Updated the kmp_omp_struct_info_t structure used by debuggers.
llvm-svn: 228734
Andrew Kaylor [Tue, 10 Feb 2015 19:52:43 +0000 (19:52 +0000)]
Adding support for llvm.eh.begincatch and llvm.eh.endcatch intrinsics and beginning the documentation of native Windows exception handling.
Differential Revision: http://reviews.llvm.org/D7398
llvm-svn: 228733
Alexey Samsonov [Tue, 10 Feb 2015 19:50:20 +0000 (19:50 +0000)]
[UBSan] Reduce the number of getCallerLocation() calls.
getCallerLocation() is expensive as it issues a call to symbolizer.
(In fact, this function has a memory leak at the moment, but this
will be fixed in the nearest future). We should only call it if
we're actually going to print an error report, in particular,
once for every reported source location.
__ubsan_handle_type_mismatch: call getCallerLocation() only if
provided source location is invalid, and only if the report is not
deduplicated.
__ubsan_handle_float_cast_overflow: call getSourceLocation with
correct CallerPC (the one in user code, not in UBSan handler). Source
location for this check is not currently emitted by frontend.
llvm-svn: 228732
Tim Northover [Tue, 10 Feb 2015 19:49:18 +0000 (19:49 +0000)]
DeadArgElim: arguments affect all returned sub-values by default.
Unless we meet an insertvalue on a path from some value to a return, that value
will be live if *any* of the return's components are live, so all of those
components must be added to the MaybeLiveUses.
Previously we were deleting arguments if sub-value 0 turned out to be dead.
llvm-svn: 228731
Andrey Churbanov [Tue, 10 Feb 2015 19:47:09 +0000 (19:47 +0000)]
OpenMP 4.0 standard function omp_is_initial_device() implemented.
llvm-svn: 228730
Greg Clayton [Tue, 10 Feb 2015 19:43:15 +0000 (19:43 +0000)]
Don't crash when evaluating a DWARF expression has a DW_OP_bra with nothing on the value stack.
<rdar://problem/
18919125>
llvm-svn: 228729
Bill Schmidt [Tue, 10 Feb 2015 19:31:55 +0000 (19:31 +0000)]
Fix up r228725, missed change in PPCSubtarget definition
llvm-svn: 228728
Andrey Churbanov [Tue, 10 Feb 2015 19:31:17 +0000 (19:31 +0000)]
Added comment on format of local labels in asm code
llvm-svn: 228727
Duncan P. N. Exon Smith [Tue, 10 Feb 2015 19:13:46 +0000 (19:13 +0000)]
IR: Add MDNode::replaceWithPermanent()
Add new API for converting temporaries that may self-reference.
Self-referencing nodes are not allowed to be uniqued, so sending them
into `replaceWithUniqued()` is dangerous (and this commit adds
assertions that prevent it).
`replaceWithPermanent()` has similar semantics to `get()` followed by
calls to `replaceOperandWith()`. In particular, if there's a
self-reference, it returns a distinct node; otherwise, it returns a
uniqued one. Like `replaceWithUniqued()` and `replaceWithDistinct()`
(well, it calls out to them) it mutates the temporary node in place if
possible, only calling `replaceAllUsesWith()` on a uniquing collision.
llvm-svn: 228726
Bill Schmidt [Tue, 10 Feb 2015 19:09:05 +0000 (19:09 +0000)]
[PowerPC] Fix reverted patch r227976 to avoid register assignment issues
See full discussion in http://reviews.llvm.org/D7491.
We now hide the add-immediate and call instructions together in a
separate pseudo-op, which is tagged to define GPR3 and clobber the
call-killed registers. The PPCTLSDynamicCall pass prior to RA now
expands this op into the two separate addi and call ops, with explicit
definitions of GPR3 on both instructions, and explicit clobbers on the
call instruction. The pass is now marked as requiring and preserving
the LiveIntervals and SlotIndexes analyses, and fixes these up after
the replacement sequences are introduced.
Self-hosting has been verified on LE P8 and BE P7 with various
optimization levels, etc. It has also been verified with the
--no-tls-optimize flag workaround removed.
llvm-svn: 228725
David Majnemer [Tue, 10 Feb 2015 19:01:47 +0000 (19:01 +0000)]
X86: Emit Win64 SaveXMM opcodes at the right offset in the right order
Walk the instructions marked FrameSetup and consider any stores of XMM
registers to the stack as needing a SaveXMM opcode.
This fixes PR22521.
Differential Revision: http://reviews.llvm.org/D7527
llvm-svn: 228724
Rui Ueyama [Tue, 10 Feb 2015 18:59:37 +0000 (18:59 +0000)]
Use override rather than virtual.
llvm-svn: 228723
Rui Ueyama [Tue, 10 Feb 2015 18:55:39 +0000 (18:55 +0000)]
GNU: Use StringRef::empty instead of a boolean flag.
This local variable name did not follow the style guide,
and it is not actually needed.
llvm-svn: 228722
Andrey Churbanov [Tue, 10 Feb 2015 18:51:52 +0000 (18:51 +0000)]
Added CFI directives to asm code in order to have correct backtraces in gdb.
llvm-svn: 228721
Dan Albert [Tue, 10 Feb 2015 18:46:57 +0000 (18:46 +0000)]
Make ABI header not found a warning, not an error.
Since we've added a new header to libc++abi (__cxxabi_config.h), we
now have a case where we might not always find all the ABI headers:
building libc++ against the system's libc++abi on Darwin.
Since this isn't actually a fatal error, degrade it to a warning.
llvm-svn: 228720
Hal Finkel [Tue, 10 Feb 2015 18:45:02 +0000 (18:45 +0000)]
[PowerPC] Support the (old) cntlz instruction alias
Some old assembly code uses the cntlz alias for cntlzw, binutils supports this,
and we should too. Fixes PR22519.
llvm-svn: 228719
Andrey Churbanov [Tue, 10 Feb 2015 18:37:43 +0000 (18:37 +0000)]
The usage of tt_state flag is replaced by an array of two task_team pointers.
llvm-svn: 228718
Rui Ueyama [Tue, 10 Feb 2015 18:34:46 +0000 (18:34 +0000)]
Driver: use hasArg instead of getLastArg if return value is not used.
llvm-svn: 228717
Chaoren Lin [Tue, 10 Feb 2015 18:30:34 +0000 (18:30 +0000)]
Failsafe directory for shared objects and support executables.
llvm-svn: 228716
Chaoren Lin [Tue, 10 Feb 2015 18:30:31 +0000 (18:30 +0000)]
Adding x86 to supported architectures on x86_64.
llvm-svn: 228715
Hafiz Abid Qadeer [Tue, 10 Feb 2015 18:12:44 +0000 (18:12 +0000)]
Fix build on Windows which was broken by a recent commit.
This file MICmnStreamStdinLinux.cpp is wrongly added in the windows build.
It has no use there. CMakeList.txt for lldb-mi needs to be re-factored to
include the right file for each build. This is quick fix to un-break the build.
llvm-svn: 228714
Michael Zolotukhin [Tue, 10 Feb 2015 17:54:54 +0000 (17:54 +0000)]
Add a test case for new unrolling heuristics.
THe heuristics were added in r228265 and r228434.
llvm-svn: 228713
Eric Fiselier [Tue, 10 Feb 2015 17:32:49 +0000 (17:32 +0000)]
Add pragma system header to some experimental headers and add newlines to files.
llvm-svn: 228712
Eric Fiselier [Tue, 10 Feb 2015 17:20:18 +0000 (17:20 +0000)]
Fix more issues exposed by -pedantic-errors in c++03 mode
llvm-svn: 228711
Sylvestre Ledru [Tue, 10 Feb 2015 17:16:13 +0000 (17:16 +0000)]
Fix the LLDB build under Debian Kfreebsd
Summary:
I don't know if there is a better way for the change in source/Host/freebsd/ThisThread.cpp
Reviewers: emaste
Subscribers: hansw, emaste, lldb-commits
Differential Revision: http://reviews.llvm.org/D7441
llvm-svn: 228710
Hafiz Abid Qadeer [Tue, 10 Feb 2015 17:10:39 +0000 (17:10 +0000)]
Fix multiple problems of lldb-mi blocking on input monitoring and needing a return.
Summary:
One of the problem is reported here.
http://llvm.org/bugs/show_bug.cgi?id=22411
A fix was committed for this problem that works only for OSX. This revision
extends that fix to other system. The select system call has some limitation with
multi-threaded application which have been addresses here.
LLDB-mi exits if quit command is given but needs an extra retur if -gdb-exit is
given. That issue has also been addressed.
Reviewers: ki.stfu, emaste
Reviewed By: ki.stfu
Subscribers: lldb-commits
Differential Revision: http://reviews.llvm.org/D7529
llvm-svn: 228709
Colin LeMahieu [Tue, 10 Feb 2015 16:59:36 +0000 (16:59 +0000)]
[Hexagon] Adding vector load with post-increment instructions. Adding decoder function for 64bit control register class.
llvm-svn: 228708
Greg Clayton [Tue, 10 Feb 2015 16:53:40 +0000 (16:53 +0000)]
Fixed a problem where we might omit some breakpoints when using DWARF in .o files.
The problem occurred when we had incorrect address ranges in the debug map that included the padding between functions causing the end address of a line table entry to fall into an inlinked (next function) address range.
<rdar://problem/
19721144>
llvm-svn: 228707
Eric Fiselier [Tue, 10 Feb 2015 16:51:29 +0000 (16:51 +0000)]
Remove use of zero length arrays in tests. Get tests passing with -pedantic-errors
llvm-svn: 228706
Eric Fiselier [Tue, 10 Feb 2015 16:48:45 +0000 (16:48 +0000)]
[libcxx] Fix PR 22468 - std::function<void()> does not accept non-void-returning functions
Summary:
The bug can be found here: http://llvm.org/bugs/show_bug.cgi?id=22468
`__invoke_void_return_wrapper` is needed to properly handle calling a function that returns a value but where the std::function return type is void. Without this '-Wsystem-headers' will cause `function::operator()(...)` to not compile.
Reviewers: eugenis, K-ballo, mclow.lists
Reviewed By: mclow.lists
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D7444
llvm-svn: 228705
Eric Fiselier [Tue, 10 Feb 2015 16:46:42 +0000 (16:46 +0000)]
[libcxx] Properly convert the count arguments to the *_n algorithms before use.
Summary:
The requirement on the `Size` type passed to *_n algorithms is that it is convertible to an integral type. This means we can't use a variable of type `Size` directly. Instead we need to convert it to an integral type first. The problem is finding out what integral type to convert it to. `__convert_to_integral` figures out what integral type to convert it to and performs the conversion, It also promotes the resulting integral type so that it is at least as big as an integer. `__convert_to_integral` also has a special case for converting enums. This should only work on non-scoped enumerations because it does not apply an explicit conversion from the enum to its underlying type.
Reviewers: chandlerc, mclow.lists
Reviewed By: mclow.lists
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D7449
llvm-svn: 228704
Zoran Jovanovic [Tue, 10 Feb 2015 16:36:20 +0000 (16:36 +0000)]
[mips][microMIPS] Implement movep instruction
Differential Revision: http://reviews.llvm.org/D7465
llvm-svn: 228703
Timur Iskhodzhanov [Tue, 10 Feb 2015 16:29:05 +0000 (16:29 +0000)]
[ASan/Win] NFC, just minor simplification of the code
llvm-svn: 228702
Timur Iskhodzhanov [Tue, 10 Feb 2015 16:17:01 +0000 (16:17 +0000)]
[ASan/Win] Add the executable's directory to the symbol search path
This should fix symbolization in those cases when the .exe file is moved together with the .pdb
llvm-svn: 228701
Jonas Paulsson [Tue, 10 Feb 2015 15:34:29 +0000 (15:34 +0000)]
Two comment typo fixes in lib/CodeGen/SelectionDAG/DAGCombiner.cpp.
llvm-svn: 228700
Paul Robinson [Tue, 10 Feb 2015 15:30:02 +0000 (15:30 +0000)]
Explicitly initialize a flag in a default constructor.
Works around a Visual C++ issue.
Patch by Douglas Yung!
llvm-svn: 228699
Eric Fiselier [Tue, 10 Feb 2015 15:17:46 +0000 (15:17 +0000)]
Fix use of C++11 extensions in C++03 code.
llvm-svn: 228698
Bradley Smith [Tue, 10 Feb 2015 15:16:49 +0000 (15:16 +0000)]
[ARM] Add tests for armv6s[-]m being an alias to armv6[-]m
llvm-svn: 228697
Bradley Smith [Tue, 10 Feb 2015 15:15:08 +0000 (15:15 +0000)]
[ARM] Add armv6s[-]m as an alias to armv6[-]m
llvm-svn: 228696
John Thompson [Tue, 10 Feb 2015 14:58:07 +0000 (14:58 +0000)]
Fixed module-map-checker to recurse umbrella dirs when collecting headers.
llvm-svn: 228695
Samuel Benzaquen [Tue, 10 Feb 2015 14:46:45 +0000 (14:46 +0000)]
Add translationUnitDecl matcher.
Summary: Add translationUnitDecl matcher.
Reviewers: alexfh
Subscribers: klimek, cfe-commits
Differential Revision: http://reviews.llvm.org/D7512
llvm-svn: 228694
John Thompson [Tue, 10 Feb 2015 14:45:30 +0000 (14:45 +0000)]
Renamed module.map to module.modulemap (modularize).
llvm-svn: 228693
John Thompson [Tue, 10 Feb 2015 14:29:16 +0000 (14:29 +0000)]
Renamed module.map to module.modulemap.
llvm-svn: 228692
Aaron Ballman [Tue, 10 Feb 2015 14:28:11 +0000 (14:28 +0000)]
Re-committing r228628 with a fix for 64-bit builds.
On Windows, we now use RaiseException to generate the kind of trap we require (one which calls our vectored exception handler), and fall back to using a volatile write to simulate a trap elsewhere.
llvm-svn: 228691
Renato Golin [Tue, 10 Feb 2015 14:15:58 +0000 (14:15 +0000)]
Fix typo in cmake example docs
Patch by Vinicius Tinti.
llvm-svn: 228690
John Thompson [Tue, 10 Feb 2015 13:51:17 +0000 (13:51 +0000)]
The -I option needs a space, apparently, from the actual implementation.
llvm-svn: 228689
Simon Pilgrim [Tue, 10 Feb 2015 13:22:57 +0000 (13:22 +0000)]
[X86][AVX2] Missing AVX2 memory folding instructions
Added most of the missing vector folding patterns for AVX2 (as well as fixing the vpermpd and verpmq patterns)
Differential Revision: http://reviews.llvm.org/D7492
llvm-svn: 228688
Jozef Kolek [Tue, 10 Feb 2015 13:20:51 +0000 (13:20 +0000)]
[mips][microMIPS] Add disassembler tests for 16-bit instructions BREAK16 and SDBBP16
Differential Revision: http://reviews.llvm.org/D7443
llvm-svn: 228687
Jonas Paulsson [Tue, 10 Feb 2015 13:03:32 +0000 (13:03 +0000)]
Bugfix for missed dependency from store to load in buildSchedGraph().
Background: When handling underlying objects for a store, the vector
of previous mem uses, mapped to the same Value, is afterwards cleared
(regardless of ThisMayAlias). This means that during handling of the
next store using the same Value, adjustChainDeps() must be called,
otherwise a dependency might be missed.
For example, three spill/reload (NonAliasing) memory accesses using
the same Value 'a', with different offsets:
SU(2): store @a
SU(1): store @a, Offset:1
SU(0): load @a
In this case we have:
* SU(1) does not need a dep against SU(0). Therefore,SU(0) ends up in
RejectMemNodes and is removed from the mem-uses list (AliasMemUses
or NonAliasMemUses), as this list is cleared.
* SU(2) needs a dep against SU(0). Therefore, SU(2) must check
RejectMemNodes by calling adjustChainDeps().
Previously, for store SUs, adjustChainDeps() was only called if
MayAlias was true, missing the S(2) to S(0) dependency in the case
above. The fix is to always call adjustChainDeps(), regardless of
MayAlias, since this applies both for AliasMemUses and
NonAliasMemUses.
No testcase found for any in-tree target.
llvm-svn: 228686
Simon Pilgrim [Tue, 10 Feb 2015 12:57:17 +0000 (12:57 +0000)]
[X86][XOP] Added XOP memory folding patterns + tests
This patch adds the complete AMD Bulldozer XOP instruction set to the memory folding pattern tables for stack folding, etc.
Note: Many of the XOP instructions have multiple table entries as it can fold loads from different sources.
Differential Revision: http://reviews.llvm.org/D7484
llvm-svn: 228685
Jozef Kolek [Tue, 10 Feb 2015 12:41:13 +0000 (12:41 +0000)]
[mips][microMIPS] Fix disassembling of 16-bit microMIPS instructions LWM16 and SWM16
Differential Revision: http://reviews.llvm.org/D7436
llvm-svn: 228683
Andrea Di Biagio [Tue, 10 Feb 2015 12:04:41 +0000 (12:04 +0000)]
[X86][FastIsel] Avoid introducing legacy SSE instructions if the target has AVX.
This patch teaches X86FastISel how to select AVX instructions for scalar
float/double convert operations.
Before this patch, X86FastISel always selected legacy SSE instructions
for FPExt (from float to double) and FPTrunc (from double to float).
For example:
\code
define double @foo(float %f) {
%conv = fpext float %f to double
ret double %conv
}
\end code
Before (with -mattr=+avx -fast-isel) X86FastIsel selected a CVTSS2SDrr which is
legacy SSE:
cvtss2sd %xmm0, %xmm0
With this patch, X86FastIsel selects a VCVTSS2SDrr instead:
vcvtss2sd %xmm0, %xmm0, %xmm0
Added test fast-isel-fptrunc-fpext.ll to check both the register-register and
the register-memory float/double conversion variants.
Differential Revision: http://reviews.llvm.org/D7438
llvm-svn: 228682
Ilia K [Tue, 10 Feb 2015 12:02:03 +0000 (12:02 +0000)]
Add thread-id field in *stopped notification (MI)
Summary:
Add thread-id field in *stopped notification (MI) + tests
All tests pass on OS X
Reviewers: zturner, clayborg, abidh
Reviewed By: clayborg
Subscribers: lldb-commits, zturner, clayborg, abidh
Differential Revision: http://reviews.llvm.org/D7501
llvm-svn: 228681
Denis Protivensky [Tue, 10 Feb 2015 09:31:42 +0000 (09:31 +0000)]
[ELF][ARM] Add veneer generation to branch instructions
When calling ARM code from Thumb and vice versa,
a veneer that switches instruction set should be generated.
Added veneer generation for ARM_JUMP24 ARM_THM_JUMP24 instructions.
Differential Revision: http://reviews.llvm.org/D7502
llvm-svn: 228680
Gabor Horvath [Tue, 10 Feb 2015 09:14:26 +0000 (09:14 +0000)]
[clang-tidy] Checker for inaccurate use of erase() method.
Algorithms like remove() does not actually remove any element from the
container but returns an iterator to the first redundant element at the end
of the container. These redundant elements must be removed using the
erase() method. This check warns when not all of the elements will be
removed due to using an inappropriate overload.
Reviewer: alexfh
Differential Revision: http://reviews.llvm.org/D7496
llvm-svn: 228679
James Molloy [Tue, 10 Feb 2015 09:09:04 +0000 (09:09 +0000)]
Fix __ldrexd arm intrinsic.
The parameter definition of this API is const volatile __int64*, but it is not defined correctly in clang. Move the 'CD' to the correct location.
Bug tracked here: http://llvm.org/bugs/show_bug.cgi?id=21004
Patch by Daniel Jump!
llvm-svn: 228678
Chandler Carruth [Tue, 10 Feb 2015 08:07:32 +0000 (08:07 +0000)]
Revert r228556: InstCombine: propagate nonNull through assume
This commit isn't using the correct context, and is transfoming calls
that are operands to loads rather than calls that are operands to an
icmp feeding into an assume. I've replied on the original review thread
with a very reduced test case and some thoughts on how to rework this.
llvm-svn: 228677
Lang Hames [Tue, 10 Feb 2015 07:35:39 +0000 (07:35 +0000)]
[Orc] Fix a bug in the LazyEmittingLayer - capture names by value (as
std::strings) rather than StringRefs in JITSymbol get-address lambda.
Capturing a StringRef by-value is still effectively capturing a reference, which
is no good here because the referenced string may be gone by the time the lambda
is being evaluated the original value may be gone. Make sure to capture a
std::string instead.
No test case: This bug doesn't manifest under OrcMCJITReplacement, since it
keeps IR modules (from which the StringRefs are sourced) alive permanently.
llvm-svn: 228676
Lang Hames [Tue, 10 Feb 2015 07:26:19 +0000 (07:26 +0000)]
[Orc] Add missing casserts header to JITSymbol.h.
llvm-svn: 228675
Ilia K [Tue, 10 Feb 2015 06:35:58 +0000 (06:35 +0000)]
Add tests for -interpreter-exec command (MI)
llvm-svn: 228674
Bob Wilson [Tue, 10 Feb 2015 06:33:04 +0000 (06:33 +0000)]
Do not force "-static" for aarch64 iOS kernel/kext assembly code.
Somehow a check for aarch64 was added to the Darwin toolchain's
isKernelStatic function as part of the initial commit for Apple's
arm64 target (r205100). That check was not in any of Apple's internal
code and no one here knows where it came from. It has been harmless
because "-static" does not change much, if anything, for arm64 iOS code,
but it makes no sense to keep this check.
llvm-svn: 228673
Craig Topper [Tue, 10 Feb 2015 06:29:28 +0000 (06:29 +0000)]
[X86] Preserve mem refs on newly created 'Store' node instead of 'Load' node when handling store unfolding.
Bug spotted by Steve King.
I have no idea how to test this.
llvm-svn: 228672
Craig Topper [Tue, 10 Feb 2015 05:10:50 +0000 (05:10 +0000)]
[X86] Remove unnecessary alignment checks from the load folding tables.
llvm-svn: 228671
Zachary Turner [Tue, 10 Feb 2015 05:04:37 +0000 (05:04 +0000)]
Teach llvm_add_library() to find include dirs.
Since header files are not compilation units, CMake does not require
you to specify them in the CMakeLists.txt file. As a result, unless a
header file is explicitly added, CMake won't know about it, and when
generating IDE-based projects, CMake won't put the header files into
the IDE project. LLVM currently tries to deal with this in two ways:
1) It looks for all .h files that are in the project directory, and
adds those.
2) llvm_add_library() understands the ADDITIONAL_HEADERS argument,
which allows one to list an arbitrary list of headers.
This patch takes things one step further. It adds the ability for
llvm_add_library() to take an ADDITIONAL_HEADER_DIRS argument, which
will specify a list of folders which CMake will glob for header files.
Furthermore, it will glob not only for .h files, but also for .inc
files.
Included in this CL is an update to one of the existing users of
ADDITIONAL_HEADERS to use this new argument instead, to serve as an
illustration of how this cleans up the CMake.
The big advantage of this new approach is that until now, there was no
way for the IDE projects to locate the header files that are in the
include tree. In other words, if you are in, for example,
lib/DebugInfo/DWARF, the corresponding includes for this project will
be located under include/llvm/DebugInfo/DWARF. Now, in the
CMakeLists.txt for lib/DebugInfo/DWARF, you can simply write:
ADDITIONAL_HEADER_DIRS
../../include/llvm/DebugInfo/DWARF
as an argument to llvm_add_library(), and all header files will get
added to the IDE project.
Differential Revision: http://reviews.llvm.org/D7460
Reviewed By: Chris Bieneman
llvm-svn: 228670
Zachary Turner [Tue, 10 Feb 2015 05:04:25 +0000 (05:04 +0000)]
Define HAVE_DIA_SDK on Windows when DIA is present.
This allows all CMake projects, as well as C++ code, to detect if
and when DIA SDK is available for use so that we can enable the
DIA-based PDB reader implementation.
Differential Revision: http://reviews.llvm.org/D7457
Reviewed By: Chandler Carruth
llvm-svn: 228669
Saleem Abdulrasool [Tue, 10 Feb 2015 03:43:33 +0000 (03:43 +0000)]
unwind: improve compilation on Linux with gcc
gcc still defaults to C89 which does not support BCPL style comments. This
splits up the sources list in CMakeLists and selectively adds compile flags for
using C99 which avoids a number of warnings in -Wpedantic mode. NFC.
llvm-svn: 228665
Saleem Abdulrasool [Tue, 10 Feb 2015 03:43:31 +0000 (03:43 +0000)]
unwind: clean up some stray semicolons
Clean up some stray semicolons found by GCC 4.9 -Wpedantic. NFC.
llvm-svn: 228664
Saleem Abdulrasool [Tue, 10 Feb 2015 03:43:28 +0000 (03:43 +0000)]
unwind: clean up -Wundef warnings
The unified register management interfaces had multiple naked macros for
conditional logic. This cleans them up to use the defined() form, avoiding
-Wundef warnings. NFC.
llvm-svn: 228663
Saleem Abdulrasool [Tue, 10 Feb 2015 03:43:23 +0000 (03:43 +0000)]
unwind: fix -Wformat warnings from gcc
Clean up the format specifiers for pedantic compilation with gcc 4.9 on Linux.
NFC.
llvm-svn: 228662
Richard Smith [Tue, 10 Feb 2015 03:28:10 +0000 (03:28 +0000)]
[modules] When determining whether a name from a module replaces a name we
already have, check whether the name from the module is actually newer than the
existing declaration. If it isn't, we might (say) replace a visible declaration
with an injected friend, and thus make it invisible (or lose a default argument
or an array bound).
llvm-svn: 228661
Enrico Granata [Tue, 10 Feb 2015 03:16:55 +0000 (03:16 +0000)]
And make the globbing behavior available via the SB API
llvm-svn: 228660
Enrico Granata [Tue, 10 Feb 2015 03:13:22 +0000 (03:13 +0000)]
Add a test case for the launch via argdumper globbing mechanism
llvm-svn: 228659
Enrico Granata [Tue, 10 Feb 2015 03:06:24 +0000 (03:06 +0000)]
Add a "launch with globber" mode that lets you launch a process after having globbed the command line arguments via argdumper instead of routing via /bin/sh
llvm-svn: 228658
Nick Lewycky [Tue, 10 Feb 2015 02:39:17 +0000 (02:39 +0000)]
Remove non-test files that appear to have been accidentally committed in r228641.
llvm-svn: 228657
Chandler Carruth [Tue, 10 Feb 2015 02:25:56 +0000 (02:25 +0000)]
[x86] Fix PR22524: the DAG combiner was incorrectly handling illegal
nodes when folding bitcasts of constants.
We can't fold things and then check after-the-fact whether it was legal.
Once we have formed the DAG node, arbitrary other nodes may have been
collapsed to it. There is no easy way to go back. Instead, we need to
test for the specific folding cases we're interested in and ensure those
are legal first.
This could in theory make this less powerful for bitcasting from an
integer to some vector type, but AFAICT, that can't actually happen in
the SDAG so its fine. Now, we *only* whitelist specific int->fp and
fp->int bitcasts for post-legalization folding. I've added the test case
from the PR.
(Also as a note, this does not appear to be in 3.6, no backport needed)
llvm-svn: 228656
Duncan P. N. Exon Smith [Tue, 10 Feb 2015 02:25:18 +0000 (02:25 +0000)]
Verifier: reuse getInlinedAt() result, NFC
llvm-svn: 228655