Asaf Badouh [Thu, 30 Jul 2015 06:52:26 +0000 (06:52 +0000)]
[X86][AVX512BW] Remove whitespaces
llvm-svn: 243623
Mohit K. Bhakkad [Thu, 30 Jul 2015 05:45:56 +0000 (05:45 +0000)]
[LLDB][MIPS] Added expected failure for "test disassembler settings"
Patch by Nitesh Jain
Reviewers: clayborg, ovyalov.
Subscribers: jaydeep, bhushan, mohit.bhakkad, sagar, emaste, lldb-commits.
Differential Revision: http://reviews.llvm.org/D11562
llvm-svn: 243622
Ilia K [Thu, 30 Jul 2015 05:39:31 +0000 (05:39 +0000)]
Clean up test/tools/lldb-mi/variable/main.cpp after r243619
llvm-svn: 243621
Mohit K. Bhakkad [Thu, 30 Jul 2015 05:38:11 +0000 (05:38 +0000)]
[LLDB][MIPS] To handle SI_KERNEL generated for invalid 64 bit address
Patch by Nitesh Jain
Reviewers: clayborg, ovyalov.
Subscribers: jaydeep, bhushan, mohit.bhakkad, sagar, emaste, lldb-commits.
Differential Revision: http://reviews.llvm.org/D11176
llvm-svn: 243620
Ilia K [Thu, 30 Jul 2015 05:32:41 +0000 (05:32 +0000)]
Fix bug in expression display when determining if a pointer should be treated as a string
Summary:
Currently if the "first child" of the pointer is a char type then the pointer is displayed as a string. This test succeeds incorrectly when the pointer is to a structured type with a char type as its first field. Fix this by switching the test to retrieve the pointee type and checking that it is a char type.
Reviewers: abidh, ChuckR, ki.stfu
Subscribers: greggm, lldb-commits
Differential Revision: http://reviews.llvm.org/D11488
llvm-svn: 243619
Jaydeep Patil [Thu, 30 Jul 2015 05:06:51 +0000 (05:06 +0000)]
[LLDB][MIPS] Create Unix Signals based on target architecture
SUMMARY:
The patch creates Unix Signals based on target architecture. For MIPS it creates MipsLinuxSignals.
Reviewers: clayborg
Subscribers: mohit.bhakkad, sagar, lldb-commits
Differential Revision: http://reviews.llvm.org/D11455
llvm-svn: 243618
Adam Nemet [Thu, 30 Jul 2015 04:21:13 +0000 (04:21 +0000)]
[LoopVer] Add missing std::move
The reason I was passing this vector by value in the constructor so that
I wouldn't have to copy when initializing the corresponding member but
then I forgot the std::move.
The use-case is LoopDistribution which filters the checks then
std::moves it to LoopVersioning's constructor. With this interface we
can avoid any copies.
llvm-svn: 243616
Nico Weber [Thu, 30 Jul 2015 03:41:05 +0000 (03:41 +0000)]
Revert r243604, it (very likely) caused PR24312.
llvm-svn: 243615
Richard Smith [Thu, 30 Jul 2015 03:37:16 +0000 (03:37 +0000)]
Remove some noise "this->"s left behind by r243213.
llvm-svn: 243614
Adam Nemet [Thu, 30 Jul 2015 03:29:16 +0000 (03:29 +0000)]
[LDist] Filter the checks locally rather than in LAA, NFC
Before, we were passing the pointer partitions to LAA. Now, we get all
the checks from LAA and filter out the checks within partitions in
LoopDistribution.
This effectively concludes the steps to move filtering memchecks from
LAA into its clients. There is still some cleanup left to remove the
unused interfaces in LAA that still take PtrPartition.
(Moving this functionality to LoopDistribution also requires
needsChecking on pointers to be made public.)
llvm-svn: 243613
Richard Smith [Thu, 30 Jul 2015 03:17:16 +0000 (03:17 +0000)]
[modules] Remove redundant information written into DeclContext name lookup tables. We don't need to store the data length twice.
llvm-svn: 243612
Kostya Serebryany [Thu, 30 Jul 2015 02:33:45 +0000 (02:33 +0000)]
[libFuzzer] implement strncmp hook for data-flow-guided fuzzing (w/ and w/o dfsan), add a test
llvm-svn: 243611
Kostya Serebryany [Thu, 30 Jul 2015 02:32:51 +0000 (02:32 +0000)]
[sanitizer] add a weak hook for strncmp interceptor, both to dfsan and other sanitizers. Hide the declaration and the calls in better macros
llvm-svn: 243610
Lang Hames [Thu, 30 Jul 2015 02:05:37 +0000 (02:05 +0000)]
[MCJIT] Fix a memory leak in a unit test that was introduced in r243589.
llvm-svn: 243609
Hans Wennborg [Thu, 30 Jul 2015 01:45:17 +0000 (01:45 +0000)]
[CMake] Pass -march=i686 when targeting i686 (PR24222)
Clang will not define __i686__, even when the target triple is i686,
without -march=i686.
With this patch, the compiler-rt build will successfully detect that
Clang can target i686.
The open_memstream.cc test is a little funny. Before my patch, it
was invoked with "-m32 -m64". To make it work after my -march
change, I had to add '-march=x86-64'.
Differential Revision: http://reviews.llvm.org/D11618
llvm-svn: 243604
Kostya Serebryany [Thu, 30 Jul 2015 01:34:58 +0000 (01:34 +0000)]
[libFuzzer] implement memcmp hook for data-flow-guided fuzzing (w/o dfsan), extend the memcmp fuzzer test
llvm-svn: 243603
Sean Silva [Thu, 30 Jul 2015 01:21:56 +0000 (01:21 +0000)]
Remove bad test.
We currently don't canonicalize paths in the preprocessed files.
But we do when writing to PCH.
This causes a discrepancy on Windows with the test below.
This test fails even on unix if you change the test to use
`%S//preprocess.h`.
I am led to conclude that the invariant that this test was intending to
test has not been upheld for a while (and may never have been).
llvm-svn: 243602
Kostya Serebryany [Thu, 30 Jul 2015 01:19:17 +0000 (01:19 +0000)]
[sanitizer] add a weak hook for memcmp interceptor, to be used primarily for fuzzing. More hooks will be added later. So far this is a Linux-only feature
llvm-svn: 243601
Sean Silva [Thu, 30 Jul 2015 00:52:32 +0000 (00:52 +0000)]
Attempt to make clang-x64-ninja-win7 happy.
It looks like we were somehow relying somewhere on removing 'foo/./bar'
but *not* 'foo/../foo/bar'. Currently investigating.
llvm-svn: 243600
Alexey Samsonov [Thu, 30 Jul 2015 00:50:40 +0000 (00:50 +0000)]
[Sanitizer] Replace diagnostic string literal to workaround CMake 2.8 bug.
Let me tell you a story. Suppose you want to build your project (e.g. LLVM)
with CMake 2.8, Clang and AddressSanitizer. You also want to ensure that
Clang is fresh enough and check that CMAKE_CXX_COMPILER_VERSION is 3.1+.
This check would fail - CMake would fail to correctly calculate compiler
version if you pass CMAKE_CXX_FLAGS=-fsanitize=address.
The problem is funky compiler version calculation in
CMakeDetermineCompilerId.cmake module: it compiles the sample source
file with provided compiler and compile flags, runs "strings" and greps
for "INFO:" ASCII strings contained on the executable to fetch
"INFO:compiler", "INFO:compiler_version" etc. It limits the output of
grep to just 4 lines.
Unfortunately, if your executable was built with ASan, it would also contain
an ASCII string
INFO: %s ignores mlock/mlockall/munlock/munlockall
and INFO:compiler_version string would never be parsed.
All of the above actually happened after r243574 when we tried to
configure libcxx with just-built Clang with TSan/MSan, and the version
check mentioned above failed in HandleLLVMOptions.cmake
(╯°□°)╯.~.┻━┻
llvm-svn: 243599
Pete Cooper [Thu, 30 Jul 2015 00:40:42 +0000 (00:40 +0000)]
Prefix make_reverse_iterator with llvm namespace.
This was fallout from r243581. Turns out C++14 has make_reverse_iterator.
Thanks to Filipe and David for the quick fix suggestion.
llvm-svn: 243598
Sean Silva [Thu, 30 Jul 2015 00:26:34 +0000 (00:26 +0000)]
Avoid failure to canonicalize '..'.
Also fix completely broken and untested code which was hiding the
primary bug. The !LLVM_ON_UNIX branch of the ifdef was actually a no-op.
I ran into this in the wild. It was causing failures in our SDK build.
Ideally we'd have a perfect llvm::sys::fs::canonical, but at least this
is a step in the right direction, and fixes an obviously broken case.
In some sense the test case I've added here is an integration test. We
should have these routines thoroughly unit tested in llvm::sys::fs.
llvm-svn: 243597
Sanjay Patel [Thu, 30 Jul 2015 00:04:21 +0000 (00:04 +0000)]
push fast-math check for machine-combiner reassociations into instruction-type check; NFC
This makes it simpler to add instruction types that don't depend on fast-math.
llvm-svn: 243596
Kostya Serebryany [Wed, 29 Jul 2015 23:53:08 +0000 (23:53 +0000)]
[asan,tsan,msan] move the memcmp interceptor from asan/tsan to sanitizer_common. This may potentially lead to more reports from msan as it now sees the reads inside memcmp. To disable, use the flag intercept_memcmp=0. Likewise, it may potentially cause new races to appear due to more strict memcmp checking (flag strict_memcmp=1)
llvm-svn: 243595
Richard Trieu [Wed, 29 Jul 2015 23:47:19 +0000 (23:47 +0000)]
Fix -Wredundant-move warning.
Without DR1579 implemented, the only case for -Wredundant-move is for a
parameter being returned with the same type as the function return type. Also
include a check to verify that the move constructor will be used by matching
nodes in the AST dump.
llvm-svn: 243594
Eric Fiselier [Wed, 29 Jul 2015 23:46:55 +0000 (23:46 +0000)]
Revert recent CMake changes again due to failing compiler-rt builds
llvm-svn: 243593
Richard Smith [Wed, 29 Jul 2015 23:38:25 +0000 (23:38 +0000)]
[modules] When performing redeclaration lookup for a using declaration, prefer
UsingShadowDecls over other declarations of the same entity in the lookup
results. This ensures that we build correct redeclaration chains for the
UsingShadowDecls (otherwise we could see assertions and other misbehavior in
modules builds, when merging combines multiple redeclaration chains for the
same entity from the same module into one chain).
llvm-svn: 243592
Eric Fiselier [Wed, 29 Jul 2015 23:23:18 +0000 (23:23 +0000)]
Attempt to fix build issues introduced by
r243574
llvm-svn: 243591
Matthias Braun [Wed, 29 Jul 2015 23:22:48 +0000 (23:22 +0000)]
IR: Implement Value::mergeUseLists() iteratively
This avoids stack overflows when the the compiler does not perform tail call
elimination. Apparently this happens for MSVC with the /Ob2 switch which
may be used by external code including this header.
Reported by and based on a patch from Jean-Francois Riendeau.
Related to rdar://
21900756
llvm-svn: 243590
Lang Hames [Wed, 29 Jul 2015 23:12:33 +0000 (23:12 +0000)]
[MCJIT] Fix PR20656 by teaching MCJIT to honor ExecutionEngine's global mapping.
This is important for users of the C API who can't supply custom symbol
resolvers yet.
llvm-svn: 243589
Rui Ueyama [Wed, 29 Jul 2015 22:53:29 +0000 (22:53 +0000)]
Remove unused #includes.
llvm-svn: 243588
Rui Ueyama [Wed, 29 Jul 2015 22:38:27 +0000 (22:38 +0000)]
COFF: Suppress "Duplicate entry" warning of lib.exe
We create a module-definition file and give that to lib.exe to
create an import library file. A module-definition has to be
syntactically and semantically correct, of course.
There was a case that we created a module-definition file that
lib.exe would complain for duplicate entries. If a user gives
an unmangled and mangled name for the same symbol, we would end
up having two duplicate lines for the mangled name in a module-
definition file.
This patch fixes that issue by uniquefying entries by mangled
symbol name.
llvm-svn: 243587
Nick Lewycky [Wed, 29 Jul 2015 22:38:23 +0000 (22:38 +0000)]
Fix typo in unused variable name.
llvm-svn: 243586
Nick Lewycky [Wed, 29 Jul 2015 22:32:47 +0000 (22:32 +0000)]
Fix typo "fuction" noticed in comments in AssumptionCache.h, and also all the other files that have the same typo. All comments, no functionality change! (Merely a "fuctionality" change.)
Bonus change to remove emacs major mode marker from SystemZMachineFunctionInfo.cpp because emacs already knows it's C++ from the extension. Also fix typo "appeary" in AMDGPUMCAsmInfo.h.
llvm-svn: 243585
Frederic Riss [Wed, 29 Jul 2015 22:29:50 +0000 (22:29 +0000)]
[dsymutil] Re-add command line option -v this time printing the version.
llvm-svn: 243584
Frederic Riss [Wed, 29 Jul 2015 22:29:46 +0000 (22:29 +0000)]
[dsymutil] Use option categories.
Prevent all the unrelated LLVM options to appear in the -help output
by introducing a tool specific option category. As a drive-by improve
the wording of the help message.
llvm-svn: 243583
Frederic Riss [Wed, 29 Jul 2015 22:29:34 +0000 (22:29 +0000)]
[dsymutil] Rename -v option to -verbose
The dsymutil-classic -v option dumps the tool version rather than
putting it in verbose mode. Rename -v to -verbose and update the
tests that use it (in the process removing it from a few tests that
didn't require it anymore since the -dump-debug-map option was
introduced).
A followup commit will reintroduce the -v option that dumps the
version.
llvm-svn: 243582
Pete Cooper [Wed, 29 Jul 2015 22:19:09 +0000 (22:19 +0000)]
Reapply "Add reverse(ContainerTy) range adapter."
This reverts commit r243567, which ultimately reapplies r243563.
The fix here was to use std::enable_if for overload resolution. Thanks to David
Blaikie for lots of help on this, and for the extra tests!
Original commit message follows:
For cases where we needed a foreach loop in reverse over a container,
we had to do something like
for (const GlobalValue *GV : make_range(TypeInfos.rbegin(),
TypeInfos.rend())) {
This provides a convenience method which shortens this to
for (const GlobalValue *GV : reverse(TypeInfos)) {
There are 2 versions of this, with a preference to the rbegin() version.
The first uses rbegin() and rend() to construct an iterator_range.
The second constructs an iterator_range from the begin() and end() methods
wrapped in std::reverse_iterator's.
Reviewed by David Blaikie.
llvm-svn: 243581
Oleksiy Vyalov [Wed, 29 Jul 2015 22:18:16 +0000 (22:18 +0000)]
Make DWARF at_comp_dir symbolic links configurable via plugin.symbol-file.dwarf.comp-dir-symlink-paths setting.
http://reviews.llvm.org/D11586
llvm-svn: 243580
Michael J. Spencer [Wed, 29 Jul 2015 22:14:50 +0000 (22:14 +0000)]
[ELF2] Templatize addChunk and handle section flags.
llvm-svn: 243579
Eric Christopher [Wed, 29 Jul 2015 22:09:48 +0000 (22:09 +0000)]
Rename hasCompatibleFunctionAttributes->areInlineCompatible based
on suggestions. Currently the function is only used for inline purposes
and this is more descriptive for the use.
llvm-svn: 243578
Simon Pilgrim [Wed, 29 Jul 2015 21:44:27 +0000 (21:44 +0000)]
[X86][SSE] Keep 32-bit target i64 vector shifts on SSE unit.
This patch improves the 32-bit target i64 constant matching to detect the shuffle vector splats that are introduced by i64 vector shift vectorization (D8416).
Differential Revision: http://reviews.llvm.org/D11327
llvm-svn: 243577
Tim Northover [Wed, 29 Jul 2015 21:34:32 +0000 (21:34 +0000)]
AArch64: use 32-bit MOV rather than UBFX to truncate registers.
It's potentially more efficient on Cyclone, and from the optimization guides &
schedulers looks like it has no effect on Cortex-A53 or A57. In general you'd
expect a MOV to be about the most efficient instruction with its semantics,
even though the official "UXTW" alias is really a UBFX.
llvm-svn: 243576
Alex Lorenz [Wed, 29 Jul 2015 21:09:09 +0000 (21:09 +0000)]
MIR Serialization: Serialize the frame info's save and restore points.
This commit serializes the save and restore machine basic block references from
the machine frame information class.
llvm-svn: 243575
Eric Fiselier [Wed, 29 Jul 2015 21:07:28 +0000 (21:07 +0000)]
Recommit r243503 "[libcxx] Cleanup CMake configuration and integrate with LLVM"
This change was reverted in r243550 because it broke clang-format builds
(see PR24306).
This patch recommits a fixed version of the original.
llvm-svn: 243574
Rui Ueyama [Wed, 29 Jul 2015 21:01:15 +0000 (21:01 +0000)]
COFF: Fix command line option spelling.
llvm-svn: 243573
Alex Lorenz [Wed, 29 Jul 2015 20:57:11 +0000 (20:57 +0000)]
MIR Parser: Extract the code that parses MBB references into a new method. NFC.
This commit extracts the code that's used by the class 'MIRParserImpl' to parse
the machine basic block references into a new method named 'parseMBBReference'.
llvm-svn: 243572
Davide Italiano [Wed, 29 Jul 2015 20:55:04 +0000 (20:55 +0000)]
[SemaAccess] Provide meaningful message when we hit llvm_unreachable().
llvm-svn: 243571
Rui Ueyama [Wed, 29 Jul 2015 20:48:02 +0000 (20:48 +0000)]
Remove astyle-options.
We have our own code formatting tool, clang-format.
I believe no one is using "astyle" to format the code.
llvm-svn: 243570
Simon Pilgrim [Wed, 29 Jul 2015 20:31:45 +0000 (20:31 +0000)]
[X86][SSE] Vectorize i64 ASHR operations
This patch vectorizes the v2i64/v4i64 ASHR shift operations - the last remaining integer vector shifts that are still being transferred to/from the scalar unit to be completed.
Differential Revision: http://reviews.llvm.org/D11439
llvm-svn: 243569
Rui Ueyama [Wed, 29 Jul 2015 20:29:15 +0000 (20:29 +0000)]
COFF: Ignore /ThrowNew command line option.
This command line option is added since MSVC 2015. Our wild guess is
that the flag is for LTCG and we can safely ignore that.
llvm-svn: 243568
Pete Cooper [Wed, 29 Jul 2015 20:29:10 +0000 (20:29 +0000)]
Revert "Add reverse(ContainerTy) range adapter."
This reverts commit r243563.
The GCC buildbots were extremely unhappy about this. Reverting while
we discuss a better way of doing overload resolution.
llvm-svn: 243567
David Blaikie [Wed, 29 Jul 2015 20:26:23 +0000 (20:26 +0000)]
[opaque pointers] Remove use of PointerType::getElementType in favor of GEPOperator::getSourceElementType
llvm-svn: 243566
Rui Ueyama [Wed, 29 Jul 2015 20:25:40 +0000 (20:25 +0000)]
COFF: Add /safeseh command line option.
If /safeseh is specified, all input files must be compatible with Safe SEH.
llvm-svn: 243565
Evgeniy Stepanov [Wed, 29 Jul 2015 20:17:21 +0000 (20:17 +0000)]
[asan] XFAIL 1 test on Android.
The test uses source file relative paths which does not work when the
test is executed on a remote device.
llvm-svn: 243564
Pete Cooper [Wed, 29 Jul 2015 20:00:39 +0000 (20:00 +0000)]
Add reverse(ContainerTy) range adapter.
For cases where we needed a foreach loop in reverse over a container,
we had to do something like
for (const GlobalValue *GV : make_range(TypeInfos.rbegin(),
TypeInfos.rend())) {
This provides a convenience method which shortens this to
for (const GlobalValue *GV : reverse(TypeInfos)) {
There are 2 versions of this, with a preference to the rbegin() version.
The first uses rbegin() and rend() to construct an iterator_range.
The second constructs an iterator_range from the begin() and end() methods
wrapped in std::reverse_iterator's.
Reviewed by David Blaikie.
llvm-svn: 243563
Alexey Samsonov [Wed, 29 Jul 2015 19:36:08 +0000 (19:36 +0000)]
[ASan] Disable dynamic alloca and UAR detection in presence of returns_twice calls.
Summary:
returns_twice (most importantly, setjmp) functions are
optimization-hostile: if local variable is promoted to register, and is
changed between setjmp() and longjmp() calls, this update will be
undone. This is the reason why "man setjmp" advises to mark all these
locals as "volatile".
This can not be enough for ASan, though: when it replaces static alloca
with dynamic one, optionally called if UAR mode is enabled, it adds a
whole lot of SSA values, and computations of local variable addresses,
that can involve virtual registers, and cause unexpected behavior, when
these registers are restored from buffer saved in setjmp.
To fix this, just disable dynamic alloca and UAR tricks whenever we see
a returns_twice call in the function.
Reviewers: rnk
Subscribers: llvm-commits, kcc
Differential Revision: http://reviews.llvm.org/D11495
llvm-svn: 243561
Rui Ueyama [Wed, 29 Jul 2015 19:25:00 +0000 (19:25 +0000)]
COFF: ARM: Fix relocations to thumb code.
Windows ARM is the thumb ARM environment, and pointers to thumb code
needs to have its LSB set. When we apply relocations, we need to
adjust the LSB if it points to an executable section.
llvm-svn: 243560
Rui Ueyama [Wed, 29 Jul 2015 19:24:58 +0000 (19:24 +0000)]
COFF: ARM: Fix DLL import table.
The previous test was testing -flavor link. This patch correctly
tests link2 and fixes a bug that we didn't emit import thunks.
llvm-svn: 243559
Colin LeMahieu [Wed, 29 Jul 2015 19:21:13 +0000 (19:21 +0000)]
[llvm-objdump] Inverting logic to match the word "predicate". Returning true when we want it rather than when we want to discard it.
llvm-svn: 243558
Rui Ueyama [Wed, 29 Jul 2015 19:17:15 +0000 (19:17 +0000)]
COFF: Fix seh.test.
seh.test was testing -flavor link. This should have been testing
-flavor link2.
llvm-svn: 243557
Colin LeMahieu [Wed, 29 Jul 2015 19:08:10 +0000 (19:08 +0000)]
[llvm-objdump] Merging MachO DumpSections in to FilterSections. Simplifying some predicate logic.
llvm-svn: 243556
Jingyue Wu [Wed, 29 Jul 2015 18:59:09 +0000 (18:59 +0000)]
Roll forward r242871
r242871 missed one place that should be guarded with isPhysicalReg. This patch
fixes that.
llvm-svn: 243555
Alex Lorenz [Wed, 29 Jul 2015 18:57:23 +0000 (18:57 +0000)]
MIR Serialization: Serialize the '.cfi_def_cfa' CFI instruction.
llvm-svn: 243554
Alex Lorenz [Wed, 29 Jul 2015 18:51:21 +0000 (18:51 +0000)]
MIR Parser: Parse multiple LHS register machine operands.
llvm-svn: 243553
Douglas Katzman [Wed, 29 Jul 2015 18:39:14 +0000 (18:39 +0000)]
Use the AddAllArgs overload which accepts an ArrayRef of OptSpecifier.
Differential Revision: http://reviews.llvm.org/D11599
llvm-svn: 243552
Greg Clayton [Wed, 29 Jul 2015 18:37:25 +0000 (18:37 +0000)]
Centralize where we update the source file contents in SourceManager::GetFile() in case APIs are called that don't update the source.
The following functions were the only functions that updates the source file:
SourceManager::File::DisplaySourceLines()
SourceManager::File::FindLinesMatchingRegex()
But there we API calls that were using the SourceManager::File and asking it questions, like "is line 12 valid" and that might respond incorrectly if the source file had been updated.
<rdar://problem/
21269402>
llvm-svn: 243551
Hans Wennborg [Wed, 29 Jul 2015 18:32:21 +0000 (18:32 +0000)]
Revert r243503 "[libcxx] Cleanup CMake configuration and integrate with LLVM"
This caused clang-format to stop linking on Mac; see PR24306.
llvm-svn: 243550
Sanjay Patel [Wed, 29 Jul 2015 18:24:18 +0000 (18:24 +0000)]
move DAGCombiner's allowableAlignment() helper function into the TLI
Making allowableAlignment() more accessible was suggested as a predecessor patch
for D10662, so I've pulled it into TargetLowering. This let's us remove 4 instances
of duplicate logic in LegalizeDAG.
There's a subtle functional change in the implementation: the existing
allowableAlignment() code was using getPrefTypeAlignment() when checking
alignment with the DataLayout and assumed that was fast. In this implementation,
we use getABITypeAlignment() and assume that is fast. See the TODO comment or the
discussion in the Phab review for future improvements in this implementation
(don't use the data layout at all).
There are no regression test changes from this difference, and I'm not sure how to
expose it via a test. I think we actually do want to provide the 'Fast' param when
checking this from DAGCombiner::MergeConsecutiveStores(). Ie, we shouldn't merge
stores if the new stores are not going to be fast. But that change will require
fixing allowsMisalignedMemoryAccess() overrides as noted in D10662.
Differential Revision: http://reviews.llvm.org/D10905
llvm-svn: 243549
Evgeniy Stepanov [Wed, 29 Jul 2015 18:22:25 +0000 (18:22 +0000)]
[asan] Remove special case mapping on Android/AArch64.
ASan shadow on Android starts at address 0 for both historic and
performance reasons. This is possible because the platform mandates
-pie, which makes lower memory region always available.
This is not such a good idea on 64-bit platforms because of MAP_32BIT
incompatibility.
This patch changes Android/AArch64 mapping to be the same as that of
Linux/AAarch64.
llvm-svn: 243548
Peter Collingbourne [Wed, 29 Jul 2015 18:12:45 +0000 (18:12 +0000)]
CFI: Update tests for various bit vector sizes following lowerbitsets optzns.
Also add a test to ensure that this doesn't regress.
Differential Revision: http://reviews.llvm.org/D11584
llvm-svn: 243547
Peter Collingbourne [Wed, 29 Jul 2015 18:12:36 +0000 (18:12 +0000)]
LowerBitSets: Add debugging output.
Differential Revision: http://reviews.llvm.org/D11583
llvm-svn: 243546
Michael Zolotukhin [Wed, 29 Jul 2015 18:10:33 +0000 (18:10 +0000)]
[Unroll] Handle SwitchInst properly.
Previously successor selection was simply wrong.
llvm-svn: 243545
Michael Zolotukhin [Wed, 29 Jul 2015 18:10:29 +0000 (18:10 +0000)]
[Unroll] Don't crash when simplified branch condition is undef.
llvm-svn: 243544
Michael Zolotukhin [Wed, 29 Jul 2015 18:10:23 +0000 (18:10 +0000)]
Rename test full-unroll-bad-geps.ll to full-unroll-crashers.ll.
No reason to limit it only to GEP-related crashes. More tests are to
come here.
llvm-svn: 243543
Lang Hames [Wed, 29 Jul 2015 18:07:48 +0000 (18:07 +0000)]
Fix typos in comments. NFC.
llvm-svn: 243542
Jim Ingham [Wed, 29 Jul 2015 17:51:36 +0000 (17:51 +0000)]
Add a function to make a mutex-protected copy of a breakpoint site's
owners list, so the StopInfo machinery can get the list of owners without
some other thread being able to mess up the list by deleting/disabline one of its
locations in the process of doing so.
<rdar://problem/
18685197>
llvm-svn: 243541
Bruno Cardoso Lopes [Wed, 29 Jul 2015 17:46:47 +0000 (17:46 +0000)]
Revert "[PeepholeOptimizer] Look through PHIs to find additional register sources"
Reported to Broke some internal tests: PR24303
This reverts commit r243486.
llvm-svn: 243540
Douglas Katzman [Wed, 29 Jul 2015 17:34:41 +0000 (17:34 +0000)]
Add an ArgList::AddAllArgs that accepts a vector of OptSpecifier.
This lifts the somewhat arbitrary restriction on 3 OptSpecifiers.
Differential Revision: http://reviews.llvm.org/D11597
llvm-svn: 243539
Richard Trieu [Wed, 29 Jul 2015 17:03:34 +0000 (17:03 +0000)]
Disable -Wpessimizing-move and -Wredundant-move in template instantiations.
Dependent types can throw off the analysis for these warnings, possibly giving
conflicting warnings and fix-its. Disabling the warning in template
instantiations will prevent this problem, and will still catch the
non-dependent cases in templates.
llvm-svn: 243538
Tim Northover [Wed, 29 Jul 2015 16:39:56 +0000 (16:39 +0000)]
AArch64: use AddressingModes.h accessors for compare shifts
No functional change because "lsl #12" is actually encoded as 12, but one less
bug if someone ever decides to change that for the giggles.
llvm-svn: 243536
Rui Ueyama [Wed, 29 Jul 2015 16:30:45 +0000 (16:30 +0000)]
COFF: Fix SECREL and SECTION relocations.
SECREL should sets the 32-bit offset of the target from the beginning
of *target's* output section. Previously, the offset from the beginning
of source's output section was used instead.
SECTION means the target section's index, and not the source section's
index. This patch fixes that issue too.
llvm-svn: 243535
Rui Ueyama [Wed, 29 Jul 2015 16:30:40 +0000 (16:30 +0000)]
ELF2: Use DenseMap instead of std::map for a symbol table.
We use DenseMap for COFF too.
llvm-svn: 243534
Rui Ueyama [Wed, 29 Jul 2015 16:30:34 +0000 (16:30 +0000)]
COFF: Remove unused command line option.
llvm-svn: 243533
Rui Ueyama [Wed, 29 Jul 2015 16:30:31 +0000 (16:30 +0000)]
COFF: Set load config table entry on non-x86.
llvm-svn: 243532
Hans Wennborg [Wed, 29 Jul 2015 16:29:06 +0000 (16:29 +0000)]
test-release.sh: Add option for building the OpenMP run-time
This isn't part of the official release process, but provides a convenient way
to build binaries for those who want to experiment with it. Hopefully the run-
time can be part of the regular build and release process for 3.8.
Differential Revision: http://reviews.llvm.org/D11494
llvm-svn: 243531
Marshall Clow [Wed, 29 Jul 2015 16:25:45 +0000 (16:25 +0000)]
Fix a self-move bug in inplace_merge. Thanks to Ted and Dexon for the report and the suggested fix.
llvm-svn: 243530
Reid Kleckner [Wed, 29 Jul 2015 16:19:40 +0000 (16:19 +0000)]
Delete unused <dbghelp.h> include
llvm-svn: 243529
Aaron Ballman [Wed, 29 Jul 2015 15:57:49 +0000 (15:57 +0000)]
Reverting r243386 because it has serious post-commit concerns that have not been addressed. Also reverts r243389, which relied on this commit.
llvm-svn: 243527
Colin LeMahieu [Wed, 29 Jul 2015 15:45:39 +0000 (15:45 +0000)]
[llvm-objdump] Added -j flag to filter sections that are operated on.
llvm-svn: 243526
Yaron Keren [Wed, 29 Jul 2015 15:42:28 +0000 (15:42 +0000)]
In case of an existing GlobalVariable, the comdat is created using the name of the
new GV (usually NAME.1) instead of the correct NAME of the old GV. Moving comdat
creation after GV replacement solves this. Patch + testcase.
Reviewed by Reid Kleckner.
http://reviews.llvm.org/D11594
llvm-svn: 243525
Yaron Keren [Wed, 29 Jul 2015 15:28:02 +0000 (15:28 +0000)]
Make this test target x86_64-pc-windows-gnu as well.
llvm-svn: 243523
Jingyue Wu [Wed, 29 Jul 2015 15:26:11 +0000 (15:26 +0000)]
Temporarily revert r242871
PR24299
llvm-svn: 243522
Tamas Berghammer [Wed, 29 Jul 2015 15:15:42 +0000 (15:15 +0000)]
Fix read/write context in EmulateInstructionARM strd/ldrd
llvm-svn: 243521
Tamas Berghammer [Wed, 29 Jul 2015 15:14:37 +0000 (15:14 +0000)]
Remove non-utf-8 characters from EmulateInstructionARM
llvm-svn: 243520
Bill Schmidt [Wed, 29 Jul 2015 14:31:57 +0000 (14:31 +0000)]
[PPC] Fix PR24216: Don't generate splat for misaligned shuffle mask
Given certain shuffle-vector masks, LLVM emits splat instructions
which splat the wrong bytes from the source register. The issue is
that the function PPC::isSplatShuffleMask() in PPCISelLowering.cpp
does not ensure that the splat pattern found is requesting bytes that
are aligned on an EltSize boundary. This patch detects this situation
as not a valid splat mask, resulting in a permute being generated
instead of a splat.
Patch and test case by Tyler Kenney, cleaned up a bit by me.
This is a simple bug fix that would be good to incorporate into 3.7.
llvm-svn: 243519
Akira Hatanaka [Wed, 29 Jul 2015 14:25:58 +0000 (14:25 +0000)]
[AArch64] Pass subtarget feature "+strict-align".
This commit changes the driver to save subtarget feature "+strict-align"
to the IR instead of using backend option "aarch64-strict-align". This is
needed for LTO.
rdar://problem/
21529937
llvm-svn: 243518
Yaron Keren [Wed, 29 Jul 2015 14:21:47 +0000 (14:21 +0000)]
Remove unnecessary variable.
llvm-svn: 243517
Akira Hatanaka [Wed, 29 Jul 2015 14:17:26 +0000 (14:17 +0000)]
[AArch64] Define subtarget feature strict-align.
This commit defines subtarget feature strict-align and uses it instead of
cl::opt -aarch64-strict-align to decide whether strict alignment should be
forced.
rdar://problem/
21529937
llvm-svn: 243516
Tobias Grosser [Wed, 29 Jul 2015 13:52:05 +0000 (13:52 +0000)]
Do not detect scops that are delinearized to arrays with "undef" size
Such codes are not interesting to optimize and most likely never appear in the
normal compilation flow. However, they show up during test case reduction with
bugpoint and trigger -- without this change -- an assert in
polly::MemoryAccess::foldAccess(). It is better to detect them in
ScopDetection itself and just bail out.
Contributed-by: Utpal Bora <cs14mtech11017@iith.ac.in>
Reviewers: grosser
Subscribers: pollydev, llvm-commits
Differential Revision: http://reviews.llvm.org/D11425
llvm-svn: 243515