David Majnemer [Mon, 14 Jul 2014 20:46:04 +0000 (20:46 +0000)]
Fix a test broken in r212981
@icmp_sdiv_neg1 should have referred to %a instead of %call, it was
renamed at the last second.
llvm-svn: 212983
Joerg Sonnenberger [Mon, 14 Jul 2014 20:40:56 +0000 (20:40 +0000)]
Introduce getCorrespondingUnsignedType() in TargetInfo to work like the
corresponding AST context function, only restricted to basic integer
types. Use this to ensure getUIntPtrType() gives types consistent with
getIntPtrType(). Fix NVPTX backend to give signed intptr_t.
llvm-svn: 212982
David Majnemer [Mon, 14 Jul 2014 20:38:45 +0000 (20:38 +0000)]
InstSimplify: Correct sdiv x / -1
Determining the bounds of x/ -1 would start off with us dividing it by
INT_MIN. Suffice to say, this would not work very well.
Instead, handle it upfront by checking for -1 and mapping it to the
range: [INT_MIN + 1, INT_MAX. This means that the result of our
division can be any value other than INT_MIN.
llvm-svn: 212981
Ben Langmuir [Mon, 14 Jul 2014 20:36:40 +0000 (20:36 +0000)]
XFAIL test that doesn't work on Windows yet
llvm-svn: 212980
Ehsan Akhgari [Mon, 14 Jul 2014 20:28:21 +0000 (20:28 +0000)]
Add support for intercepting thunks of the form
llvm-svn: 212979
Richard Smith [Mon, 14 Jul 2014 19:54:05 +0000 (19:54 +0000)]
In C++98, if an rvalue reference binds to a function lvalue (or an xvalue or an
array prvalue), treat that as a direct binding. Only the class prvalue case
needs to be excluded here; the rest are extensions anyway, so we can treat them
as we would in C++11.
llvm-svn: 212978
Sanjay Patel [Mon, 14 Jul 2014 19:52:36 +0000 (19:52 +0000)]
fixed link
llvm-svn: 212977
David Majnemer [Mon, 14 Jul 2014 19:49:57 +0000 (19:49 +0000)]
InstSimplify: The upper bound of X / C was missing a rounding step
Summary:
When calculating the upper bound of X / -
8589934592, we would perform
the following calculation: Floor[INT_MAX /
8589934592]
However, flooring the result would make us wrongly come to the
conclusion that
1073741824 was not in the set of possible values.
Instead, use the ceiling of the result.
Reviewers: nicholas
Subscribers: llvm-commits
Differential Revision: http://reviews.llvm.org/D4502
llvm-svn: 212976
Ben Langmuir [Mon, 14 Jul 2014 19:45:12 +0000 (19:45 +0000)]
Fix case-sensitivity of inferred framework modules
Just because we can open a directory named "COcoa.framework" doesn't
mean we should provide a "COcoa" module on a case-insensitive filesystem.
llvm-svn: 212975
Alp Toker [Mon, 14 Jul 2014 19:42:55 +0000 (19:42 +0000)]
Fix typos
Also consolidate 'backward compatibility'
llvm-svn: 212974
Justin Bogner [Mon, 14 Jul 2014 19:24:13 +0000 (19:24 +0000)]
Support: Use a range-based for
llvm-svn: 212973
Alp Toker [Mon, 14 Jul 2014 19:16:22 +0000 (19:16 +0000)]
Avoid non-attributive uses of 'unsupported' in diagnostics
We don't have a style guide for diagnostic messages, but convention strongly
favours the forms:
'attribute is not supported', 'unsupported attribute'
We generally avoid:
'attribute is unsupported', 'non-supported attribute'
llvm-svn: 212972
Matt Arsenault [Mon, 14 Jul 2014 18:54:12 +0000 (18:54 +0000)]
Look through addrspacecast when checking isDereferenceablePointer
llvm-svn: 212971
Nick Lewycky [Mon, 14 Jul 2014 18:52:02 +0000 (18:52 +0000)]
Don't eliminate memcpy's when the address of the pointer may itself be relevant. Fixes PR18304. Patch by David Wiberg!
llvm-svn: 212970
Sylvestre Ledru [Mon, 14 Jul 2014 18:34:37 +0000 (18:34 +0000)]
Document the forward of the -u option (r211756)
llvm-svn: 212969
Sylvestre Ledru [Mon, 14 Jul 2014 18:30:23 +0000 (18:30 +0000)]
Document the warning triggered by the unsupported gcc optimization flags (r212805)
llvm-svn: 212968
Bill Wendling [Mon, 14 Jul 2014 18:21:11 +0000 (18:21 +0000)]
Unify the lowering of arguments during SjLj prepare.
The 'select true, %arg, undef' instruction can be used for both aggregate and
non-aggregate arguments.
llvm-svn: 212967
Sanjay Patel [Mon, 14 Jul 2014 18:21:07 +0000 (18:21 +0000)]
fixed typo
llvm-svn: 212966
Reid Kleckner [Mon, 14 Jul 2014 18:19:58 +0000 (18:19 +0000)]
Revert "Improve error recovery around colon."
This reverts commit r212957. It broke the self-host on code like this
from LLVM's option library:
for (auto Arg: filtered(Id0, Id1, Id2))
llvm-svn: 212965
Alp Toker [Mon, 14 Jul 2014 18:11:38 +0000 (18:11 +0000)]
Change the diagnostic group for unsupported gcc optimizations added r212805
Use -Winvalid-command-line-argument here to align with existing gcc opt
diagnostics. Meanwhile -Wunused-command-line-argument is for flags that we
support but were, say, fed into the wrong invocation.
Also tweak wording to make sense with -Werror.
llvm-svn: 212964
Matt Arsenault [Mon, 14 Jul 2014 17:24:38 +0000 (17:24 +0000)]
Use pointer type cast helpers.
llvm-svn: 212963
Matt Arsenault [Mon, 14 Jul 2014 17:24:35 +0000 (17:24 +0000)]
Add CreatePointerBitCastOrAddrSpaceCast to IRBuilder and co.
llvm-svn: 212962
Matt Arsenault [Mon, 14 Jul 2014 17:24:31 +0000 (17:24 +0000)]
Update comments to include addrspacecast
llvm-svn: 212961
Matt Arsenault [Mon, 14 Jul 2014 17:11:20 +0000 (17:11 +0000)]
Remove GCC 3.3 workaround
llvm-svn: 212960
Timur Iskhodzhanov [Mon, 14 Jul 2014 17:04:03 +0000 (17:04 +0000)]
[ASan/Win] Add a test for the case when dll_thunk is linked twice to the same DLL
This is a test case for r212815.
llvm-svn: 212959
Dan Albert [Mon, 14 Jul 2014 17:00:29 +0000 (17:00 +0000)]
Fix for libc++abi when using -Wl,--as-needed.
The cmake files for libc++abi and the unwinder weren't linking against
libpthread or an unwind library. If the tests were linked with
-Wl,--as-needed, these libraries wouldn't be linked, causing them to
fail.
Patch contributed by İsmail Dönmez.
llvm-svn: 212958
Serge Pavlov [Mon, 14 Jul 2014 16:42:20 +0000 (16:42 +0000)]
Improve error recovery around colon.
Recognize additional cases, when '::' is mistyped as ':'.
This is a fix to RP18587 - colons have too much protection in member-declarations.
Differential Revision: http://reviews.llvm.org/D3653
llvm-svn: 212957
Saleem Abdulrasool [Mon, 14 Jul 2014 16:28:13 +0000 (16:28 +0000)]
X86: correct 64-bit atomics on 32-bit
We would emit a libcall for a 64-bit atomic on x86 after SVN r212119. This was
due to the misuse of hasCmpxchg16 to indicate if cmpxchg8b was supported on a
32-bit target. They were added at different times and would result in the
border condition being mishandled.
This fixes the border case to emit the cmpxchg8b instruction for 64-bit atomic
operations on x86 at the cost of restoring a long-standing bug in the codegen.
We emit a cmpxchg8b on all x86 targets even where the CPU does not support this
instruction (pre-Pentium CPUs). Although this bug should be fixed, this was
present prior to SVN r212119 and this change, so this is not really introducing
a regression.
llvm-svn: 212956
Saleem Abdulrasool [Mon, 14 Jul 2014 16:28:09 +0000 (16:28 +0000)]
CodeGen: add missing include
Found during windows unwinding work. This header is indirectly included through
a chain leading through Support/Win64EH.h. Explicitly include the header. NFC.
llvm-svn: 212955
David Majnemer [Mon, 14 Jul 2014 16:27:53 +0000 (16:27 +0000)]
CodeGen: Let arrays be inputs to inline asm
An array showing up in an inline assembly input is accepted in ICC and
GCC 4.8
This fixes PR20201.
Differential Revision: http://reviews.llvm.org/D4382
llvm-svn: 212954
David Majnemer [Mon, 14 Jul 2014 16:20:14 +0000 (16:20 +0000)]
llvm-objdump: Handle BSS sections larger than the object file
The size of the uninitialized sections, like BSS, can exceed the size of
the object file.
Do not attempt to grab the contents of such sections.
llvm-svn: 212953
Kostya Serebryany [Mon, 14 Jul 2014 16:03:13 +0000 (16:03 +0000)]
[tsan] honour XFAIL in tsan/test_output.sh
llvm-svn: 212952
Kostya Serebryany [Mon, 14 Jul 2014 15:52:33 +0000 (15:52 +0000)]
[tsan] add a printf to a test
llvm-svn: 212951
Yi Kong [Mon, 14 Jul 2014 15:32:29 +0000 (15:32 +0000)]
ARM: Add NOP intrinsic mapping in arm_acle.h
llvm-svn: 212950
Simon Atanasyan [Mon, 14 Jul 2014 15:31:47 +0000 (15:31 +0000)]
[Mips] Fix test case expectations due the latest changes in the LLVM.
llvm-svn: 212949
Tim Northover [Mon, 14 Jul 2014 15:31:13 +0000 (15:31 +0000)]
X86: remove temporary atomicrmw used during lowering.
We construct a temporary "atomicrmw xchg" instruction when lowering atomic
stores for widths that aren't supported natively. This isn't on the top-level
worklist though, so it won't be removed automatically and we have to do it
ourselves once that itself has been lowered.
Thanks Saleem for pointing this out!
llvm-svn: 212948
Yi Kong [Mon, 14 Jul 2014 15:20:09 +0000 (15:20 +0000)]
ARM: Implement __builtin_arm_nop intrinsic
This patch implements __builtin_arm_nop intrinsic for AArch32 and AArch64,
which generates hint 0x0, the alias of NOP instruction.
This intrinsic is necessary to implement ACLE __nop intrinsic.
Differential Revision: http://reviews.llvm.org/D4495
llvm-svn: 212947
Daniel Sanders [Mon, 14 Jul 2014 15:05:51 +0000 (15:05 +0000)]
Re-commit: [mips] Correct section alignments and EntrySizes for .bss, .text, .data, .reginfo, .MIPS.options, and .MIPS.abiflags
The lld tests will temporarily fail again but Simon Atanasyan will commit a fix for those shortly.
llvm-svn: 212946
Daniel Sanders [Mon, 14 Jul 2014 14:43:45 +0000 (14:43 +0000)]
Revert: [mips] Correct section alignments and EntrySizes for .bss, .text, .data, .reginfo, .MIPS.options, and .MIPS.abiflags
This commit causes multiple lld tests to fail. Reverting while I investigate the issue.
llvm-svn: 212945
Kostya Serebryany [Mon, 14 Jul 2014 14:27:21 +0000 (14:27 +0000)]
[tsan] add a currently-failing test with a must-deadlock
llvm-svn: 212944
Timur Iskhodzhanov [Mon, 14 Jul 2014 14:26:35 +0000 (14:26 +0000)]
[ASan] Fix a couple of nits in NULL deref tests
This is a follow-up to r212807
llvm-svn: 212943
Benjamin Kramer [Mon, 14 Jul 2014 14:24:30 +0000 (14:24 +0000)]
[clang-tidy] Add a checker for swapped arguments.
This looks for swapped arguments by looking at implicit conversions of arguments
void Foo(int, double);
Foo(1.0, 3); // Most likely a bug
llvm-svn: 212942
Alexander Kornienko [Mon, 14 Jul 2014 14:10:03 +0000 (14:10 +0000)]
Set up clang-tidy diagnostic consumer to print types etc.
Reviewers: bkramer
Reviewed By: bkramer
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D4494
llvm-svn: 212941
Benjamin Kramer [Mon, 14 Jul 2014 14:05:02 +0000 (14:05 +0000)]
[ASTMatchers] Make hasOverloadedOperatorName also match freestanding overloads.
Freestanding overloads are represented as FunctionDecls in the AST, make
the matcher also match them.
Differential Revision: http://reviews.llvm.org/D4493
llvm-svn: 212940
Daniel Sanders [Mon, 14 Jul 2014 14:02:14 +0000 (14:02 +0000)]
[mips] Correct section alignments and EntrySizes for .bss, .text, .data, .reginfo, .MIPS.options, and .MIPS.abiflags
Summary:
.bss, .text, and .data are at least 16-byte aligned.
.reginfo is 4-byte aligned and has a 24-byte EntrySize.
.MIPS.abiflags has an 24-byte EntrySize.
.MIPS.options is 8-byte aligned and has 1-byte EntrySize.
Using a 1-byte EntrySize for .MIPS.options seems strange because the
records are neither 1-byte long nor fixed-length but this matches the value
that GAS emits.
Differential Revision: http://reviews.llvm.org/D4487
llvm-svn: 212939
Daniel Sanders [Mon, 14 Jul 2014 13:08:14 +0000 (13:08 +0000)]
[mips] For the FP64A ABI, odd-numbered double-precision moves must not use mtc1/mfc1.
Summary:
This is because the FP64A the hardware will redirect 32-bit reads/writes
from/to odd-numbered registers to the upper 32-bits of the corresponding
even register. In effect, simulating FR=0 mode when FR=0 mode is not
available.
Unfortunately, we have to make the decision to avoid mfc1/mtc1 before
register allocation so we currently do this for even registers too.
FPXX has a similar requirement on 32-bit architectures that lack
mfhc1/mthc1 so this patch also handles the affected moves from the FPU for
FPXX too. Moves to the FPU were supported by an earlier commit.
Differential Revision: http://reviews.llvm.org/D4484
llvm-svn: 212938
Evgeniy Stepanov [Mon, 14 Jul 2014 13:07:51 +0000 (13:07 +0000)]
[sanitizer] Intercept getpass.
llvm-svn: 212937
Daniel Sanders [Mon, 14 Jul 2014 12:41:31 +0000 (12:41 +0000)]
[mips] Use MFHC1 when it is available (MIPS32r2 and later) for both FP32 and FP64 moves
Summary:
This is similar to r210771 which did the same thing for MTHC1.
Also corrected MTHC1_D32 and MTHC1_D64 which used AFGR64 and FGR64 on the
wrong definitions.
Differential Revision: http://reviews.llvm.org/D4483
llvm-svn: 212936
Daniel Jasper [Mon, 14 Jul 2014 12:38:38 +0000 (12:38 +0000)]
clang-format: Improve cast detection (fix false positive).
Before:
fn(a)(b)+1;
After:
fn(a)(b) + 1;
llvm-svn: 212935
NAKAMURA Takumi [Mon, 14 Jul 2014 12:26:15 +0000 (12:26 +0000)]
[CMake][Win32.DLL] Let llvm_add_library(SHARED) link dependent libraries as PRIVATE.
For example, c-index-test.exe requires just libclang.dll (its import library).
When libraries in libclang were not PRIVATE but PUBLIC, c-index-test required libraries transitive by libclang.
Note, on mingw with BUILD_SHARED_LIBS, library dependencies would become more strict.
In principle, required libraries should be "required in its source file".
This will help to detect missing dependencies.
llvm-svn: 212934
Tim Northover [Mon, 14 Jul 2014 11:16:02 +0000 (11:16 +0000)]
AArch64: remove unnecessary pseudo-instruction.
Sufficiently twisted use of TableGen lets us write patterns directly for f16
(as an i16 promoted to i32) -> f32 conversion.
llvm-svn: 212933
Daniel Sanders [Mon, 14 Jul 2014 10:26:15 +0000 (10:26 +0000)]
[mips] Correct the AFL_FLAGS1_ODDSPREG flag in .MIPS.abiflags when no '.module oddspreg' is used
Differential Revision: http://reviews.llvm.org/D4486
llvm-svn: 212932
Pavel Chupin [Mon, 14 Jul 2014 09:58:10 +0000 (09:58 +0000)]
[x32] Add __ILP32__ macro for ILP32 platforms
Summary:
Add __ILP32__ and _ILP32 macro for corresponding platforms.
Cover x86_64-*-*-gnux32 with test.
Test Plan: test added
Reviewers: chandlerc, atanasyan
Subscribers: cfe-commits, dschuff, zinovy.nis
Differential Revision: http://reviews.llvm.org/D4473
llvm-svn: 212931
Sasa Stankovic [Mon, 14 Jul 2014 09:40:29 +0000 (09:40 +0000)]
[mips] Expand BuildPairF64 to a spill and reload when the O32 FPXX ABI is
enabled and mthc1 and dmtc1 are not available (e.g. on MIPS32r1)
This prevents the upper 32-bits of a double precision value from being moved to
the FPU with mtc1 to an odd-numbered FPU register. This is necessary to ensure
that the code generated executes correctly regardless of the current FPU mode.
MIPS32r2 and above continues to use mtc1/mthc1, while MIPS-IV and above continue
to use dmtc1.
Differential Revision: http://reviews.llvm.org/D4465
llvm-svn: 212930
Evgeniy Stepanov [Mon, 14 Jul 2014 09:35:27 +0000 (09:35 +0000)]
[msan] Stop demangling function name in the stack origin report.
This was done by calling __cxa_demangle directly, which is bad
when c++abi library is instrumented. The following line always
contains the demangled name (when running with a symbolizer) anyway.
llvm-svn: 212929
Simon Atanasyan [Mon, 14 Jul 2014 09:01:40 +0000 (09:01 +0000)]
[Mips] Delete the empty directory.
llvm-svn: 212928
Simon Atanasyan [Mon, 14 Jul 2014 08:54:40 +0000 (08:54 +0000)]
[Mips] Remove unused test input file.
llvm-svn: 212927
Evgeniy Stepanov [Mon, 14 Jul 2014 08:54:10 +0000 (08:54 +0000)]
[asan] Remove XFAIL:android from 2 newly passing tests.
Fixed in r212872.
llvm-svn: 212926
Tobias Grosser [Mon, 14 Jul 2014 08:32:01 +0000 (08:32 +0000)]
DeadCodeElimination: Fix liveout computation
We move back to a simple approach where the liveout is the last must-write
statement for a data-location plus all may-write statements. The previous
approach did not work out. We would have to consider per-data-access
dependences, instead of per-statement dependences to correct it. As this adds
complexity and it seems we would not gain anything over the simpler approach
that we implement in this commit, I moved us back to the old approach of
computing the liveout, but enhanced it to also add may-write accesses.
We also fix the test case and explain why we can not perform dead code
elimination in this case.
llvm-svn: 212925
Alexander Kornienko [Mon, 14 Jul 2014 07:37:05 +0000 (07:37 +0000)]
Suggest automated replacements of C-style casts with C++ casts.
Summary:
This patch implements a subset of possible replacements of C-style
casts with const_cast/static_cast/reinterpret_cast. This should cover a large
portion of cases in real code. Handling of a few more cases may be implemented
eventually.
Reviewers: sbenza, djasper
Reviewed By: djasper
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D4478
llvm-svn: 212924
Todd Fiala [Mon, 14 Jul 2014 06:24:44 +0000 (06:24 +0000)]
Modified gdb-remote tests to run with automatically-chosen ports.
Now that llgs supports communicating the 0-port choose-a-port
mechanism and can communicate that back to a caller via the
--named-pipe option (at parity with debugserver), we use this
mechanism to always start llgs and debugserver gdb-remote
protocol tests without needing to use some port arbitration
mechanism. This eliminates some potential intermittent failures vs. the
previous random port and collision-avoidance strategy used.
llvm-svn: 212923
Bill Wendling [Mon, 14 Jul 2014 06:22:36 +0000 (06:22 +0000)]
Support lowering of empty aggregates.
This crash was pretty common while compiling Rust for iOS (armv7). Reason -
SjLj preparation step was lowering aggregate arguments as ExtractValue +
InsertValue. ExtractValue has assertion which checks that there is some data in
value, which is not true in case of empty (no fields) structures. Rust uses
them quite extensively so this patch uses a 'select true, %val, undef'
instruction to lower the argument.
Patch by Valerii Hiora.
llvm-svn: 212922
NAKAMURA Takumi [Mon, 14 Jul 2014 05:07:07 +0000 (05:07 +0000)]
[CMake] LINK_COMPONENTS: Add also corresponding MCTargetDesc and TargetInfo as well, when target names or "nativecodegen" are specified.
llvm-svn: 212921
NAKAMURA Takumi [Mon, 14 Jul 2014 05:01:53 +0000 (05:01 +0000)]
[CMake] Update libdeps.
llvm-svn: 212920
NAKAMURA Takumi [Mon, 14 Jul 2014 04:59:27 +0000 (04:59 +0000)]
[CMake] Reorder libdeps by alphabetical order.
llvm-svn: 212919
NAKAMURA Takumi [Mon, 14 Jul 2014 02:52:19 +0000 (02:52 +0000)]
NVPTX/LLVMBuild.txt: Add "Scalar" to required_libraries. It is really referenced.
llvm-svn: 212918
NAKAMURA Takumi [Mon, 14 Jul 2014 02:52:08 +0000 (02:52 +0000)]
Object/LLVMBuild.txt: Sort required_libraries by alphabetical order.
llvm-svn: 212917
Richard Smith [Mon, 14 Jul 2014 02:28:44 +0000 (02:28 +0000)]
Superficial fix for PR20218: binding a function lvalue to a const reference to
a function pointer is neither better nor worse than binding a function lvalue
to a function rvalue reference. Don't get confused and think that both bindings
are binding to a function lvalue (which would make the lvalue form win); the
const reference is binding to an rvalue.
The "real" bug in PR20218 is still present: we're getting the wrong answer from
template argument deduction, and that's what leads us to this weird overload
set.
llvm-svn: 212916
Andrea Di Biagio [Sun, 13 Jul 2014 21:02:14 +0000 (21:02 +0000)]
[DAGCombiner] Fix a crash caused by a missing check for legal type when trying to fold shuffles.
Verify that DAGCombiner does not crash when trying to fold a pair of shuffles
according to rule (added at r212539):
(shuffle (shuffle A, Undef, M0), Undef, M1) -> (shuffle A, Undef, M2)
The DAGCombiner avoids folding shuffles if the resulting shuffle dag node
is not legal for the target. That means, the resulting shuffle must have
legal type and legal mask.
Before, the DAGCombiner only called method
'TargetLowering::isShuffleMaskLegal' to check if it was "safe" to fold according
to the above-mentioned rule. However, this caused a crash in the x86 backend
since method 'isShuffleMaskLegal' always expects to be called on a
legal vector type.
llvm-svn: 212915
Saleem Abdulrasool [Sun, 13 Jul 2014 19:03:45 +0000 (19:03 +0000)]
MC: make MCWin64EHInstruction a POD-like struct
This is the first of a number of changes designed to generalise
MCWin64EHInstruction to support different target architectures. An ordered set
(vector) of these instructions is saved per frame to permit the emission of
information for Windows NT style unwinding. The only bit of information which
is actually target specific here is the Opcode for the unwinding bytecode. The
remainder of the information is simply generic information that is relevant to
the Windows NT unwinding model.
Remove the accessors for the fields, making them const and public instead. Sink
the knowledge of the alias'ed name into the single source and sink a single-use
check method into the use.
llvm-svn: 212914
Saleem Abdulrasool [Sun, 13 Jul 2014 19:03:40 +0000 (19:03 +0000)]
MC: make helper function be more const-correct
Introduce const-ness on parameters, they are used as read-only and should not be
modified. NFC.
llvm-svn: 212913
Saleem Abdulrasool [Sun, 13 Jul 2014 19:03:36 +0000 (19:03 +0000)]
MC: make DWARF and Windows unwinding handling more similar
Rename member variables and functions for the MCStreamer for DWARF-like
unwinding management. Rename the Windows ones as well and make the naming and
handling similar across the two. No functional change intended.
llvm-svn: 212912
Pavel Chupin [Sun, 13 Jul 2014 17:11:45 +0000 (17:11 +0000)]
Remove trailing spaces
llvm-svn: 212911
Simon Atanasyan [Sun, 13 Jul 2014 16:18:56 +0000 (16:18 +0000)]
Add forgotten `break` statement.
llvm-svn: 212910
Yi Kong [Sun, 13 Jul 2014 16:17:30 +0000 (16:17 +0000)]
Add test cases for AArch64 hints codegen
llvm-svn: 212909
Simon Atanasyan [Sun, 13 Jul 2014 15:28:54 +0000 (15:28 +0000)]
[Mips] Support SHT_MIPS_ABIFLAGS section type flag in the llvm-readobj,
obj2yaml and yaml2obj tools.
llvm-svn: 212908
NAKAMURA Takumi [Sun, 13 Jul 2014 13:47:37 +0000 (13:47 +0000)]
[CMake] Enable loadable modules, aka plugins, with BUILD_SHARED_LIBS on cygming.
Loadable modules could be enabled without BUILD_SHARED_LIBS with tweaks in future.
llvm-svn: 212907
NAKAMURA Takumi [Sun, 13 Jul 2014 13:40:23 +0000 (13:40 +0000)]
[CMake] Give explicit dependencies to a couple of modules, PrintFunctionNames and SampleAnalyzerPlugin, for Win32.DLL.
llvm-svn: 212906
NAKAMURA Takumi [Sun, 13 Jul 2014 13:38:55 +0000 (13:38 +0000)]
PrintFunctionNames/CMakeLists.txt: Fix a comment.
llvm-svn: 212905
NAKAMURA Takumi [Sun, 13 Jul 2014 13:36:48 +0000 (13:36 +0000)]
[CMake] Add LLVM_LINK_COMPONENTS to loadable modules, LLVMHello and BugpointPasses, on Win32.
llvm-svn: 212904
NAKAMURA Takumi [Sun, 13 Jul 2014 13:33:26 +0000 (13:33 +0000)]
[CMake] Introduce moddir for MODULE -- corresponding to LIBRARY_OUTPUT_DIRECTORY.
On Win32.DLL, it points not lib but bin.
LIBRARY_OUTPUT_DIRECTORY affects add_library(MODULE), especially Win32.DLL.
llvm-svn: 212903
NAKAMURA Takumi [Sun, 13 Jul 2014 13:28:18 +0000 (13:28 +0000)]
bugpoint/ToolRunner.cpp: ProcessFailure(): Close ErrorFD immediately, or it couldn't be reopened on Win32.
FIXME: We may have an option in openFileForWrite(), not to use ResultFD but to close it.
llvm-svn: 212902
David Majnemer [Sun, 13 Jul 2014 05:19:56 +0000 (05:19 +0000)]
MS ABI: Stick internal vftables in a comdat if they have RTTI data
Previously, we would have a private backing variable and an internal
alias pointing at it.
However, -fdata-sections only fires if a global variable has non-private
linkage. This means that an unreferenced vftable wouldn't get
discarded, bloating the object file.
Instead, stick the backing variable in a comdat even if the alias has
internal linkage. This will allow the linker to drop the vftable if it
is unused.
llvm-svn: 212901
David Majnemer [Sun, 13 Jul 2014 04:56:11 +0000 (04:56 +0000)]
IR: Allow comdats to be applied to globals with internal linkage
Our verifier check for checking if a global has local linkage was too
strict. Forbid private linkage but permit local linkage.
Object file formats permit this and forbidding it prevents elimination
of unused, internal, vftables under the MSVC ABI.
llvm-svn: 212900
David Majnemer [Sun, 13 Jul 2014 04:31:19 +0000 (04:31 +0000)]
MC: Let non-temporary COFF aliases be in symtab
MC was aping a binutils bug where aliases would default their linkage to
private instead of internal.
I've sent a patch to the binutils maintainers and they've recently
applied it to the GNU assembler sources.
This fixes PR20152.
Differential Revision: http://reviews.llvm.org/D4395
llvm-svn: 212899
Matt Arsenault [Sun, 13 Jul 2014 03:08:59 +0000 (03:08 +0000)]
Remove unused include
llvm-svn: 212898
Matt Arsenault [Sun, 13 Jul 2014 03:06:43 +0000 (03:06 +0000)]
R600: Use range for and fix missing consts.
llvm-svn: 212897
Matt Arsenault [Sun, 13 Jul 2014 03:06:39 +0000 (03:06 +0000)]
R600: Make ShaderType private
llvm-svn: 212896
Matt Arsenault [Sun, 13 Jul 2014 02:46:17 +0000 (02:46 +0000)]
R600: Run more tests with promote alloca disabled.
Re-run tests changed in r211110 to test both paths.
Also fix broken check line.
llvm-svn: 212895
Matt Arsenault [Sun, 13 Jul 2014 02:18:06 +0000 (02:18 +0000)]
R600: Run private-memory test with and without alloca promote
The unpromoted path still needs to be tested since we can't
always promote to using LDS.
llvm-svn: 212894
Matt Arsenault [Sun, 13 Jul 2014 02:08:26 +0000 (02:08 +0000)]
R600: Add option to disable promote alloca
This can make writing some tests harder, so add a flag
to disable it.
llvm-svn: 212893
Saleem Abdulrasool [Sat, 12 Jul 2014 23:40:53 +0000 (23:40 +0000)]
tests: use a more precise target for tests
llvm-svn: 212892
Saleem Abdulrasool [Sat, 12 Jul 2014 23:27:26 +0000 (23:27 +0000)]
Headers: add hint intrinsics to arm_acle.h
This adds the ARM ACLE hint intrinsic wrappers to arm_acle.h. These need to be
protected with a !defined(_MSC_VER) since MSVC (and thus clang in compatibility
mode) provide these wrappers as proper builtin intrinsics.
llvm-svn: 212891
Saleem Abdulrasool [Sat, 12 Jul 2014 23:27:22 +0000 (23:27 +0000)]
CodeGen: support hint intrinsics from ACLE on AArch64
This adds support for the ACLE hint intrinsics on AArch64 similar to ARM. This
is required to properly support ACLE on AArch64.
llvm-svn: 212890
Matt Arsenault [Sat, 12 Jul 2014 23:16:26 +0000 (23:16 +0000)]
Try to fix MSVC warning.
llvm-svn: 212889
Matt Arsenault [Sat, 12 Jul 2014 23:09:02 +0000 (23:09 +0000)]
Try to fix MSVC build
llvm-svn: 212888
Yi Kong [Sat, 12 Jul 2014 22:48:13 +0000 (22:48 +0000)]
Improve comments of ARM ACLE header file and tests
Include section number in ARM ACLE specification for easier navigation.
llvm-svn: 212887
Matt Arsenault [Sat, 12 Jul 2014 22:19:49 +0000 (22:19 +0000)]
Try to fix MSVC build
llvm-svn: 212886
Matt Arsenault [Sat, 12 Jul 2014 21:59:52 +0000 (21:59 +0000)]
Templatify DominanceFrontier.
Theoretically this should now work for MachineBasicBlocks.
llvm-svn: 212885
Ed Maste [Sat, 12 Jul 2014 21:46:39 +0000 (21:46 +0000)]
Fix lldb-gdbserver build
s_listen_thread had the wrong type.
llvm-svn: 212884