Chandler Carruth [Thu, 15 Jan 2015 02:21:56 +0000 (02:21 +0000)]
Switch this header file to not hard-code Windows line endings.
llvm-svn: 226081
Chandler Carruth [Thu, 15 Jan 2015 02:17:27 +0000 (02:17 +0000)]
[PM] Update for LLVM r226078 which moved TargetLibraryInfo to the
Analysis library.
llvm-svn: 226080
Chandler Carruth [Thu, 15 Jan 2015 02:16:55 +0000 (02:16 +0000)]
[PM] Update for LLVM r226078 which moved TargetLibraryInfo to the
Analysis library.
llvm-svn: 226079
Chandler Carruth [Thu, 15 Jan 2015 02:16:27 +0000 (02:16 +0000)]
[PM] Move TargetLibraryInfo into the Analysis library.
While the term "Target" is in the name, it doesn't really have to do
with the LLVM Target library -- this isn't an abstraction which LLVM
targets generally need to implement or extend. It has much more to do
with modeling the various runtime libraries on different OSes and with
different runtime environments. The "target" in this sense is the more
general sense of a target of cross compilation.
This is in preparation for porting this analysis to the new pass
manager.
No functionality changed, and updates inbound for Clang and Polly.
llvm-svn: 226078
NAKAMURA Takumi [Thu, 15 Jan 2015 02:15:21 +0000 (02:15 +0000)]
Win64Exception.cpp: Try to fix crash for x64 EH. "Per" might be null there.
llvm-svn: 226077
Ed Maste [Thu, 15 Jan 2015 02:07:28 +0000 (02:07 +0000)]
Fix build after r226068: cannot initialize 'int' with 'nullptr_t'
llvm-svn: 226076
Sanjoy Das [Thu, 15 Jan 2015 01:46:09 +0000 (01:46 +0000)]
Fix PR22222
The bug was introduced in r225282. r225282 assumed that sub X, Y is
the same as add X, -Y. This is not correct if we are going to upgrade
the sub to sub nuw. This change fixes the issue by making the
optimization ignore sub instructions.
Differential Revision: http://reviews.llvm.org/D6979
llvm-svn: 226075
Jim Ingham [Thu, 15 Jan 2015 01:41:04 +0000 (01:41 +0000)]
Make sure that when a breakpoint is hit but its condition is not met,
the hit count is not updated.
Also, keep the hit count for the breakpoint in the breakpoint. We were
using just the sum of the location's hit counts, but that was wrong since if a shared library is
unloaded, and the location goes away, the breakpoint hit count should not suddenly drop
by the number of hits there were on that location.
llvm-svn: 226074
Hal Finkel [Thu, 15 Jan 2015 01:33:00 +0000 (01:33 +0000)]
[TableGen] Add support for negative immediates to AsmMatcherEmitter
This adds support for creating an InstAlias with a negative immediate, i.e.:
def NOT : InstAlias<"not $dst, $src", (XORI GR32:$dst, GR32:$src, -1)>;
by resolving this problem:
RISCVGenAsmMatcher.inc:95:11: error: expected '= constant-expression' or end of enumerator definition
CVT_imm_-1,
^^^^^^^^^^
Patch by Jordy Potman, thanks!
llvm-svn: 226073
Rui Ueyama [Thu, 15 Jan 2015 01:32:00 +0000 (01:32 +0000)]
Make libmyshared.dylib a fat binary.
This would have caught the issue that I made in r225764.
llvm-svn: 226072
Hal Finkel [Thu, 15 Jan 2015 01:25:28 +0000 (01:25 +0000)]
[RegisterCoalescer] Remove copies to reserved registers
This allows the RegisterCoalescer to join "non-flipped" range pairs with a
physical destination register -- which allows the RegisterCoalescer to remove
copies like this:
<vreg> = something (maybe a load, for example)
... (things that don't use PHYSREG)
PHYSREG = COPY <vreg>
(with all of the restrictions normally applied by the RegisterCoalescer: having
compatible register classes, etc. )
Previously, the RegisterCoalescer handled only the opposite case (copying
*from* a physical register). I don't handle the problem fully here, but try to
get the common case where there is only one use of <vreg> (the COPY).
An upcoming commit to the PowerPC backend will make this pattern much more
common on PPC64/ELF systems.
llvm-svn: 226071
Hal Finkel [Thu, 15 Jan 2015 01:00:53 +0000 (01:00 +0000)]
[PowerPC] Add assembler support for mcrfs and friends
Fill out our support for the floating-point status and control register
instructions (mcrfs and friends). As it turns out, these are necessary for
compiling src/test/harness_fp.h in TBB for PowerPC.
Thanks to Raf Schietekat for reporting the issue!
llvm-svn: 226070
Richard Smith [Thu, 15 Jan 2015 01:00:33 +0000 (01:00 +0000)]
For PR21145: recognise a builtin call to a known deallocation function even if
it's defined in the current module. Clang generates this situation for the
C++14 sized deallocation functions, because it generates a weak definition in
case one isn't provided by the C++ runtime library.
llvm-svn: 226069
Kate Stone [Thu, 15 Jan 2015 00:52:41 +0000 (00:52 +0000)]
Three related changes to help:
The default help display now shows the alias collection by default, and hides commands whose named begin with an underscore. Help is primarily useful to those unfamiliar with LLDB and should aim to answer typical questions while still being able to provide more esoteric answers when required. To that latter end an argument to include the hidden commands in help has been added, and instead of having a help flag to show aliases there is now one to hide them. This final change might be controversial as it repurposes the -a shorthand as the opposite of its original meaning.
The previous implementation of OutputFormattedHelpText was easily confused by embedded newlines. The new algorithm correctly breaks on the FIRST newline or LAST space/tab before the target column count rather than treating all whitespace interchangeably.
Command interpreters now have the ability to specify help prologue text and a command prefix string. Neither are used in the current LLDB sources but are required to support REPL-like extensions where LLDB commands must be prefixed and additional help text is required to explain how to access traditional debugging commands.
<rdar://problem/
17751929>
<rdar://problem/
16953815>
<rdar://problem/
16953841>
<rdar://problem/
16930173>
<rdar://problem/
16879028>
llvm-svn: 226068
Richard Smith [Thu, 15 Jan 2015 00:48:52 +0000 (00:48 +0000)]
Fix crash-on-invalid and name lookup when recovering from ~X::X() typo.
llvm-svn: 226067
Colin LeMahieu [Thu, 15 Jan 2015 00:15:30 +0000 (00:15 +0000)]
[Hexagon] Replacing old versions of stores and loads.
llvm-svn: 226065
Adrian Prantl [Thu, 15 Jan 2015 00:11:36 +0000 (00:11 +0000)]
Add missing include directive for llvm::make_unique().
llvm-svn: 226064
Jonathan Roelofs [Thu, 15 Jan 2015 00:03:14 +0000 (00:03 +0000)]
Rename src_root -> libcxx_src_root. NFC
llvm-svn: 226063
Enrico Granata [Wed, 14 Jan 2015 23:58:18 +0000 (23:58 +0000)]
Reenable the logic to take an integer value and attempt to "po" it as an ObjC object
While there is quite a bit of potential for mishaps due to tagged pointers, and after quite some internal discussion, this seems a saner behavior given how "po" stands for "print OBJECT". The argument being that we should make at least some sensible attempt to print the thing the user passed as-if it was an object
Fixes rdar://
19423124
llvm-svn: 226062
Jonathan Roelofs [Wed, 14 Jan 2015 23:38:12 +0000 (23:38 +0000)]
Rename system_lib -> system_cxx_lib. NFC
llvm-svn: 226061
Ramkumar Ramachandra [Wed, 14 Jan 2015 23:27:07 +0000 (23:27 +0000)]
[GC] CodeGenPrep transform: simplify offsetable relocate
The transform is somewhat involved, but the basic idea is simple: find
derived pointers that have been offset from the base pointer using gep
and replace the relocate of the derived pointer with a gep to the
relocated base pointer (with the same offset).
llvm-svn: 226060
Duncan P. N. Exon Smith [Wed, 14 Jan 2015 23:11:51 +0000 (23:11 +0000)]
IR: Fix comment spelling, NFC
llvm-svn: 226058
Colin LeMahieu [Wed, 14 Jan 2015 23:07:36 +0000 (23:07 +0000)]
[Hexagon] Replacing old version of convert and load f64.
llvm-svn: 226057
Philip Reames [Wed, 14 Jan 2015 23:05:17 +0000 (23:05 +0000)]
getMangledTypeStr: clarify how it mangles types, and add tests
"Write a set of tests that show how name mangling is done for overloaded intrinsics." These happen to use gc.relocates to exercise the codepath in question, but is not a GC specific test.
Patch by: artagnon@gmail.com
Differential Revision: http://reviews.llvm.org/D6915
llvm-svn: 226056
NAKAMURA Takumi [Wed, 14 Jan 2015 23:01:36 +0000 (23:01 +0000)]
Update libdeps in NVPTXCodeGen, since r225944.
llvm-svn: 226055
Zachary Turner [Wed, 14 Jan 2015 22:58:19 +0000 (22:58 +0000)]
Only set the StopInfo on Windows if the stop is valid for this thread.
llvm-svn: 226054
Zachary Turner [Wed, 14 Jan 2015 22:58:09 +0000 (22:58 +0000)]
Don't try to link libpthread on Windows.
llvm-svn: 226053
Reid Kleckner [Wed, 14 Jan 2015 22:47:54 +0000 (22:47 +0000)]
Use MMI->getPersonality() instead of MMI->getPersonalities()[MMI->getPersonalityIndex()]
Also nuke the comment about supporting multiple personalities in a
single function, aka PR1414. That's just crazy.
llvm-svn: 226052
Duncan P. N. Exon Smith [Wed, 14 Jan 2015 22:28:03 +0000 (22:28 +0000)]
IR: Move MDLocation into place (clang testcases)
Update testcases to match LLVM change in r226048.
llvm-svn: 226049
Duncan P. N. Exon Smith [Wed, 14 Jan 2015 22:27:36 +0000 (22:27 +0000)]
IR: Move MDLocation into place
This commit moves `MDLocation`, finishing off PR21433. There's an
accompanying clang commit for frontend testcases. I'll attach the
testcase upgrade script I used to PR21433 to help out-of-tree
frontends/backends.
This changes the schema for `DebugLoc` and `DILocation` from:
!{i32 3, i32 7, !7, !8}
to:
!MDLocation(line: 3, column: 7, scope: !7, inlinedAt: !8)
Note that empty fields (line/column: 0 and inlinedAt: null) don't get
printed by the assembly writer.
llvm-svn: 226048
Matthias Braun [Wed, 14 Jan 2015 22:25:14 +0000 (22:25 +0000)]
MachineVerifier: Allow undef reads if a matching superreg is defined.
Summary:
Some pseudo instruction expansions break down a wide register use into
multiple uses of smaller sub registers. If the super register was
partially undefined the broken down sub registers may be completely
undefined now leading to MachineVerifier complaints. Unfortunately
liveness information to add the required dead flags is not easily
(cheaply) available when expanding pseudo instructions.
This commit changes the verifier to be quiet if there is an additional
implicit use of a super register. Pseudo instruction expanders can use
this to mark cases where partially defined values get potentially broken
into completely undefined ones.
Differential Revision: http://reviews.llvm.org/D6973
llvm-svn: 226047
Duncan P. N. Exon Smith [Wed, 14 Jan 2015 22:14:26 +0000 (22:14 +0000)]
IR: Always print MDLocation line
Print `MDLocation`'s `line` field even when it's 0.
llvm-svn: 226046
Duncan P. N. Exon Smith [Wed, 14 Jan 2015 21:58:17 +0000 (21:58 +0000)]
IR: Drop metadata references more aggressively during teardown
Sometimes teardown happens before the debug info graph is complete
(e.g., when clang throws an error). In that case, `MDNode`s will still
have RAUW, so deleting constants that the `MDNode`s point at will be
relatively expensive -- it'll cause re-uniquing all up the chain (what
I've been referring to as "teardown madness").
So, drop references *before* deleting constants. We need to drop a few
more references now: the metadata side of the metadata/value bridges
needs to be dropped off the cliff along with the rest of it (previously,
the bridges were cleaned before we did anything with the `MDNode`s).
There's no real functionality change here -- state before and after
`LLVMContextImpl::~LLVMContextImpl()` is unchanged -- so no testcase.
llvm-svn: 226044
Jonathan Roelofs [Wed, 14 Jan 2015 21:56:50 +0000 (21:56 +0000)]
Rename library_root to libcxx_library_root. NFC
llvm-svn: 226043
Zachary Turner [Wed, 14 Jan 2015 21:42:53 +0000 (21:42 +0000)]
Fix a number of tests on Windows.
These fix various issues with path handling and disable a few tests
which use features of LLVM which are not yet supported on Windows.
llvm-svn: 226042
Greg Clayton [Wed, 14 Jan 2015 21:37:19 +0000 (21:37 +0000)]
Specify ObjC++ when running heap commands in case we are stopped in a frame with another language.
This ensures the expression gets runs with the correct language.
<rdar://problem/
18816647>
llvm-svn: 226041
Jonathan Roelofs [Wed, 14 Jan 2015 21:02:14 +0000 (21:02 +0000)]
Refactor configure_compile_flags. NFC
llvm-svn: 226040
Vince Harron [Wed, 14 Jan 2015 21:01:15 +0000 (21:01 +0000)]
Fixes compilation/run error with BUILD_SHARED_LIBS=TRUE
BUILD_SHARED_LIBS=TRUE currently isn't working for Linux x86_64
This patch fixes the link errors and also some runtime errors
Test Plan:
CC=clang CXX=clang++ cmake -GNinja -DBUILD_SHARED_LIBS=TRUE -DCMAKE_LINKER=ld.gold -DCMAKE_BUILD_TYPE=Debug ../../llvm
ninja
ninja check-lldb
llvm-svn: 226039
Rafael Espindola [Wed, 14 Jan 2015 20:55:48 +0000 (20:55 +0000)]
Don't create new comdats in CodeGen.
This patch stops the implicit creation of comdats during codegen.
Clang now sets the comdat explicitly when it is required. With this patch clang and gcc
now produce the same result in pr19848.
llvm-svn: 226038
Ed Maste [Wed, 14 Jan 2015 20:32:33 +0000 (20:32 +0000)]
test: Add workaround for FreeBSD libedit vs readline issue
If stdout is not a terminal Python executes
rl_variable_bind ("enable-meta-key", "off");
This produces a warning with FreeBSD's libedit because the
enable-meta-key variable is unknown. Not an issue on Apple because
cpython commit
f0ab6f9f0603 added a #ifndef __APPLE__ around the call.
See http://bugs.python.org/issue19884 for more information.
For now we just discard the warning output to get the tests working
again on FreeBSD.
llvm-svn: 226037
Colin LeMahieu [Wed, 14 Jan 2015 20:26:15 +0000 (20:26 +0000)]
[Hexagon] Removing old, unused !tstbit instructions.
llvm-svn: 226036
Rafael Espindola [Wed, 14 Jan 2015 20:24:46 +0000 (20:24 +0000)]
Add a test that would have found the issue with r225644.
llvm-svn: 226035
Chandler Carruth [Wed, 14 Jan 2015 20:19:29 +0000 (20:19 +0000)]
[MBP] Add flags to disable the BadCFGConflict check in MachineBlockPlacement.
Some benchmarks have shown that this could lead to a potential
performance benefit, and so adding some flags to try to help measure the
difference.
A possible explanation. In diamond-shaped CFGs (A followed by either
B or C both followed by D), putting B and C both in between A and
D leads to the code being less dense than it could be. Always either
B or C have to be skipped increasing the chance of cache misses etc.
Moving either B or C to after D might be beneficial on average.
In the long run, but we should probably do a better job of analyzing the
basic block and branch probabilities to move the correct one of B or
C to after D. But even if we don't use this in the long run, it is
a good baseline for benchmarking.
Original patch authored by Daniel Jasper with test tweaks and a second
flag added by me.
Differential Revision: http://reviews.llvm.org/D6969
llvm-svn: 226034
Bill Schmidt [Wed, 14 Jan 2015 20:17:10 +0000 (20:17 +0000)]
[PPC64] Add support for the ICBT instruction on POWER8.
Patch by Kit Barton.
Support for the ICBT instruction is currently present, but limited to
embedded processors. This change adds a new FeatureICBT that can be used
to identify whether the ICBT instruction is available on a specific processor.
Two new tests are added:
* Positive test to ensure the icbt instruction is present when using
-mcpu=pwr8
* Negative test to ensure the icbt instruction is not generated when
using -mcpu=pwr7
Both test cases use the Prefetch opcode in LLVM. They are based on the
ppc64-prefetch.ll test case.
llvm-svn: 226033
Rafael Espindola [Wed, 14 Jan 2015 20:08:46 +0000 (20:08 +0000)]
Fix linking of shared libraries.
In shared libraries the plugin can see non-weak declarations that are still
undefined.
llvm-svn: 226031
David Blaikie [Wed, 14 Jan 2015 19:59:18 +0000 (19:59 +0000)]
Add comment about a gotcha I ran across while touching this code.
I haven't looked closely at exactly why the side effect is required, but
this seems better than not mentioning it at all.
llvm-svn: 226030
Duncan P. N. Exon Smith [Wed, 14 Jan 2015 19:56:10 +0000 (19:56 +0000)]
IR: Fix a use-after-free in RAUW
Happened pretty commonly during `LLVMContext` teardown when `clang -g`
hit an error. This fixes the use-after-free. Next I'll clean up
teardown so that it's not RAUW'ing when metadata-tracked values are
deleted (only really causes a problem if the graph is mid-construction
when teardown starts, but it's still unnecessary work).
llvm-svn: 226029
David Blaikie [Wed, 14 Jan 2015 19:55:27 +0000 (19:55 +0000)]
unique_ptrify the value in DominatorTreeBase::DomTreeNodes
(noticed the need for an explicit dtor in a recent commit & figured I'd
tidy that up)
llvm-svn: 226028
Greg Clayton [Wed, 14 Jan 2015 19:45:21 +0000 (19:45 +0000)]
Typing "gui" will crash programs that don't give LLDB a real terminal.
We now verify that the debugger's input file is a valid terminal file descriptor before allowing the "gui" command to try to run.
Xcode would crash if you typed "gui" at the command line prior to this fix.
<rdar://problem/
18775851>
llvm-svn: 226027
Rafael Espindola [Wed, 14 Jan 2015 19:43:32 +0000 (19:43 +0000)]
Fix handling of extern_weak. This was broken by r225983.
llvm-svn: 226026
Daniel Jasper [Wed, 14 Jan 2015 19:37:54 +0000 (19:37 +0000)]
clang-tidy: Add initial check for "Don't use else after return".
As per the LLVM coding standards:
http://llvm.org/docs/CodingStandards.html#don-t-use-else-after-a-return
Initial version, probably still quite a bit to do until this is really
useful.
Review: http://reviews.llvm.org/D6927
llvm-svn: 226025
Jonathan Roelofs [Wed, 14 Jan 2015 19:29:04 +0000 (19:29 +0000)]
Support picking the unwinder used for testing on linux (just as libc++abi testing allows)
llvm-svn: 226024
David Majnemer [Wed, 14 Jan 2015 19:26:56 +0000 (19:26 +0000)]
InstCombine: Don't take A-B<0 into A<B if A-B has other uses
This fixes PR22226.
llvm-svn: 226023
Rafael Espindola [Wed, 14 Jan 2015 19:07:23 +0000 (19:07 +0000)]
Revert "Add r224985 back with two fixes."
This reverts commit r225644 while I debug a regression.
llvm-svn: 226022
Reid Kleckner [Wed, 14 Jan 2015 18:50:10 +0000 (18:50 +0000)]
Emit the Itanium LSDA for unknown EH personalities on Win64
This fixes lots of generic CodeGen tests that use __gcc_personality_v0.
This suggests that using ExceptionHandling::MSVC was a mistake, and we
should instead classify each function by personality function. This
would, for example, allow us to LTO a binary containing uses of SEH and
Itanium EH.
llvm-svn: 226019
Reid Kleckner [Wed, 14 Jan 2015 18:49:39 +0000 (18:49 +0000)]
Remove dead code for llvm.eh.selector in the old EH model
llvm-svn: 226018
Zachary Turner [Wed, 14 Jan 2015 18:34:43 +0000 (18:34 +0000)]
Implement demangling on Windows.
llvm-svn: 226017
Zachary Turner [Wed, 14 Jan 2015 18:34:35 +0000 (18:34 +0000)]
Add null pointer checks to some SBStream functions.
llvm-svn: 226016
Hans Wennborg [Wed, 14 Jan 2015 18:32:20 +0000 (18:32 +0000)]
docs/conf.py: bump version to 3.7
llvm-svn: 226015
Hans Wennborg [Wed, 14 Jan 2015 18:30:55 +0000 (18:30 +0000)]
Update PACKAGE_VERSION to 3.7.0svn
llvm-svn: 226014
Colin LeMahieu [Wed, 14 Jan 2015 18:26:14 +0000 (18:26 +0000)]
[Hexagon] Removing old versions of cmph and updating references.
llvm-svn: 226013
Rafael Espindola [Wed, 14 Jan 2015 18:25:45 +0000 (18:25 +0000)]
Add support for comdats with names larger than 256 characters.
llvm-svn: 226012
Steven Wu [Wed, 14 Jan 2015 18:22:29 +0000 (18:22 +0000)]
Revert "More robust deployment target parsing on darwin"
This breaks green-dragon. Revert it and investigate.
llvm-svn: 226011
Hans Wennborg [Wed, 14 Jan 2015 18:14:05 +0000 (18:14 +0000)]
docs/conf.py: update for 3.7
llvm-svn: 226010
Hans Wennborg [Wed, 14 Jan 2015 18:14:03 +0000 (18:14 +0000)]
ReleaseNotes.rst: update to 3.7
The 3.6 release notes are in the 3.6 branch.
llvm-svn: 226009
Hans Wennborg [Wed, 14 Jan 2015 18:14:00 +0000 (18:14 +0000)]
Update cxx_dr_status.html after 3.6 branch
llvm-svn: 226008
Hans Wennborg [Wed, 14 Jan 2015 18:07:30 +0000 (18:07 +0000)]
ReleaseNotes.rst: bump version to 3.7
The 3.6 notes are now in the 3.6 branch.
llvm-svn: 226007
Colin LeMahieu [Wed, 14 Jan 2015 18:05:44 +0000 (18:05 +0000)]
[Hexagon] Removing old versions of cmpb and updating references.
llvm-svn: 226006
Steven Wu [Wed, 14 Jan 2015 18:01:27 +0000 (18:01 +0000)]
More robust deployment target parsing on darwin
Summary:
This is a more robust way of figuring out implicit deployment target
from isysroot. It also handles iphone simulator target.
Reviewers: bob.wilson, t.p.northover
Reviewed By: t.p.northover
Subscribers: t.p.northover, cfe-commits
Differential Revision: http://reviews.llvm.org/D6939
llvm-svn: 226005
Hans Wennborg [Wed, 14 Jan 2015 17:38:03 +0000 (17:38 +0000)]
Trunk is now 3.7.0svn
llvm-svn: 226004
Colin LeMahieu [Wed, 14 Jan 2015 16:49:12 +0000 (16:49 +0000)]
[Hexagon] Deleting versions of compare-not that don't have encoding information. Updating references.
llvm-svn: 226003
Sanjay Patel [Wed, 14 Jan 2015 16:03:58 +0000 (16:03 +0000)]
fix typos
llvm-svn: 225991
Saleem Abdulrasool [Wed, 14 Jan 2015 15:55:17 +0000 (15:55 +0000)]
builtins: avoid duplicating unwind declarations
Use unwind.h to get the declarations for unwinding interfaces. This header is
already provided by clang and gcc, so this adds no additional dependencies for
building the builtins library. It avoids the duplication which may drift over
time though.
llvm-svn: 225990
Tom Stellard [Wed, 14 Jan 2015 15:42:34 +0000 (15:42 +0000)]
R600/SI: Use IMPLICIT_DEF and KILL when failing to spill VGPRs
This helps us avoid 'invalid register class for operand' verifier
errors.
llvm-svn: 225989
Tom Stellard [Wed, 14 Jan 2015 15:42:31 +0000 (15:42 +0000)]
R600/SI: Spill VGPRs to scratch space for compute shaders
llvm-svn: 225988
Olivier Sallenave [Wed, 14 Jan 2015 15:36:28 +0000 (15:36 +0000)]
Check that the TLI callback enableAggressiveFMAFusion has the desired effect on FMA folding.
llvm-svn: 225987
Viktor Kutuzov [Wed, 14 Jan 2015 14:59:46 +0000 (14:59 +0000)]
[Msan] Fix strlen() and strnlen() interceptors to work on FreeBSD
Differential Revision: http://reviews.llvm.org/D6928
llvm-svn: 225986
Jonathan Roelofs [Wed, 14 Jan 2015 14:48:27 +0000 (14:48 +0000)]
Fix a lit configuration diagnostic. NFC
llvm-svn: 225985
Olivier Sallenave [Wed, 14 Jan 2015 14:47:24 +0000 (14:47 +0000)]
Override the TLI callback enableAggressiveFMAFusion and return true. Indeed, fmul, fmadd and fadd nodes cost the same number of cycles, so we can enable more combining heuristics to produce more fmadd nodes.
llvm-svn: 225984
Rafael Espindola [Wed, 14 Jan 2015 13:53:50 +0000 (13:53 +0000)]
Handle a symbol being undefined.
This can happen if:
* It is present in a comdat in one file.
* It is not present in the comdat of the file that is kept.
* Is is not used.
This should fix the LTO boostrap.
Thanks to Takumi NAKAMURA for setting up the bot!
llvm-svn: 225983
Daniel Jasper [Wed, 14 Jan 2015 12:24:59 +0000 (12:24 +0000)]
clang-format: Disable flag for Google's Java and Javascript styles.
Disable AlwaysBreakBeforeMultilineString, as the style guides don't
really say to do so.
llvm-svn: 225982
Daniel Sanders [Wed, 14 Jan 2015 12:00:12 +0000 (12:00 +0000)]
[mips] Handle transparent unions correctly.
Summary:
This fixes MultiSource/Applications/lemon on big-endian N32 by correcting the
handling of the argument to wait(). glibc defines it as a transparent union of
void* and int*. Such unions are passed according to the rules of the first
member so the argument must be passed as if it were a void* (sign extended from
i32 to i64) and not as a union (shifted to the upper bits of an i64).
wait() already behaves correctly on big-endian O32 and N64 since the union is
already the same size as an argument slot.
Reviewers: atanasyan
Reviewed By: atanasyan
Subscribers: cfe-commits
Differential Revision: http://reviews.llvm.org/D6963
llvm-svn: 225981
Vladimir Medic [Wed, 14 Jan 2015 11:35:22 +0000 (11:35 +0000)]
Add disassembler tests for mips32r2 platform. There are no functional changes.
llvm-svn: 225980
Chandler Carruth [Wed, 14 Jan 2015 11:29:14 +0000 (11:29 +0000)]
[cleanup] Re-sort *all* #include lines with llvm/utils/sort_includes.py
Sorry for the noise, I managed to miss a bunch of recent regressions of
include orderings here. This should actually sort all the includes for
Clang. Again, no functionality changed, this is just a mechanical
cleanup that I try to run periodically to keep the #include lines as
regular as possible across the project.
llvm-svn: 225979
Chandler Carruth [Wed, 14 Jan 2015 11:26:52 +0000 (11:26 +0000)]
[cleanup] Re-sort #include lines using llvm/utils/sort_includes.py
This is just a mechanical cleanup, no functionality changed. This just
fixes very minor inconsistencies with how #include lines were spaced and
sorted in LLD.
llvm-svn: 225978
Erik Eckstein [Wed, 14 Jan 2015 11:24:47 +0000 (11:24 +0000)]
reapply: SLPVectorizer: Cache results from memory alias checking.
This speeds up the dependency calculations for blocks with many load/store/call instructions.
Beside the improved runtime, there is no functional change.
Compared to the original commit, this re-applied commit contains a bug fix which ensures that there are
no incorrect collisions in the alias cache.
llvm-svn: 225977
Chandler Carruth [Wed, 14 Jan 2015 11:24:38 +0000 (11:24 +0000)]
[cleanup] Re-sort the #include lines with llvm/utils/sort_includes.py
No functionality changed, this is just a mechanical cleanup to keep the
order of #include lines consistent across the project.
llvm-svn: 225976
Chandler Carruth [Wed, 14 Jan 2015 11:23:58 +0000 (11:23 +0000)]
[cleanup] Re-sort the #include lines using llvm/utils/sort_includes.py
No functionality changed, this is a purely mechanical cleanup to ensure
the #include order remains consistent across the project.
llvm-svn: 225975
Chandler Carruth [Wed, 14 Jan 2015 11:23:27 +0000 (11:23 +0000)]
[cleanup] Re-sort all the #include lines in LLVM using
utils/sort_includes.py.
I clearly haven't done this in a while, so more changed than usual. This
even uncovered a missing include from the InstrProf library that I've
added. No functionality changed here, just mechanical cleanup of the
include order.
llvm-svn: 225974
Daniel Jasper [Wed, 14 Jan 2015 10:48:41 +0000 (10:48 +0000)]
clang-format: [Java] Support try blocks with resources.
Before:
try
(SomeResource rs = someFunction()) {
Something();
}
After:
try (SomeResource rs = someFunction()) {
Something();
}
llvm-svn: 225973
Jyoti Allur [Wed, 14 Jan 2015 10:48:16 +0000 (10:48 +0000)]
Correct POP handling for v7m
llvm-svn: 225972
Daniel Jasper [Wed, 14 Jan 2015 10:36:31 +0000 (10:36 +0000)]
clang-format: [Java] Prefer not to break in parameter annotations.
Before:
boolean someFunction(@Param(
aaaaaaaaaaaaaaaa)
String aaaaa,
String
bbbbbbbbbbbbbbb) {}
After:
boolean someFunction(
@Param(
aaaaaaaaaaaaaaaa) String aaaaa,
String
bbbbbbbbbbbbbbb) {}
llvm-svn: 225971
Chandler Carruth [Wed, 14 Jan 2015 10:33:21 +0000 (10:33 +0000)]
[dom] Make the DominatorTreeBase not a dynamic class!
Now that the passes are wrappers around this, we no longer need
a vtable, virtual destructor, and other associated mess. This is
particularly nice to me as this is a class template. =]
llvm-svn: 225970
Chandler Carruth [Wed, 14 Jan 2015 10:19:28 +0000 (10:19 +0000)]
[PM] Port domtree to the new pass manager (at last).
This adds the domtree analysis to the new pass manager. The analysis
returns the same DominatorTree result entity used by the old pass
manager and essentially all of the code is shared. We just have
different boilerplate for running and printing the analysis.
I've converted one test to run in both modes just to make sure this is
exercised while both are live in the tree.
llvm-svn: 225969
Kai Nacke [Wed, 14 Jan 2015 10:19:09 +0000 (10:19 +0000)]
[mips] Refine octeon instructions seq/seqi/sne/snei
This commit refines the pattern for the octeon seq/seqi/sne/snei instructions.
The target register is set to 0 or 1 according to the result of the comparison.
In C, this is something like
rd = (unsigned long)(rs == rt)
This commit adds a zext to bring the result to i64. With this change the
instruction is selected for this type of code. (gcc produces the same code for
the above C code.)
llvm-svn: 225968
Vladimir Medic [Wed, 14 Jan 2015 10:18:56 +0000 (10:18 +0000)]
Add disassembler tests for mips32r2 platform. There are no functional changes.
llvm-svn: 225967
Chandler Carruth [Wed, 14 Jan 2015 10:07:19 +0000 (10:07 +0000)]
[PM] Make DominatorTrees (corectly) movable so that we can move them
into the new pass manager's analysis cache which stores results
by-value.
Technically speaking, the dom trees were originally not movable but
copyable! This, unsurprisingly, didn't work at all -- the copy was
shallow and just resulted in rampant memory corruption. This change
explicitly forbids copying (as it would need to be a deep copy) and
makes them explicitly movable with the unsurprising boiler plate to
member-wise move them because we can't rely on MSVC to generate this
code for us. =/
llvm-svn: 225966
Daniel Jasper [Wed, 14 Jan 2015 10:02:49 +0000 (10:02 +0000)]
clang-format: [Java] Understand "import static".
llvm-svn: 225965
Daniel Jasper [Wed, 14 Jan 2015 10:00:20 +0000 (10:00 +0000)]
clang-format: [Java] Don't let annotations confuse return type analysis.
Before:
@Test
ReturnType
doSomething(String
aaaaaaaaaaaaa, String
bbbbbbbbbbbbbbb) {}
After:
@Test
ReturnType doSomething(
String
aaaaaaaaaaaaa, String
bbbbbbbbbbbbbbb) {}
llvm-svn: 225964
Daniel Jasper [Wed, 14 Jan 2015 09:51:32 +0000 (09:51 +0000)]
clang-format: [Java] Don't line-wrap before annotations' l_parens.
Before:
@SomeAnnotation
(
aaaaaaaaaaaaaaaaa,
aaaaaaaaaaaaaaaaaaaa)
int i;
After:
@SomeAnnotation(
aaaaaaaaaaaaaaaaa,
aaaaaaaaaaaaaaaaaaaa)
int i;
llvm-svn: 225963