Commit Graph

130179 Commits

Author SHA1 Message Date
Benjamin Kramer 60d7f5a1d7 Disable death tests on platforms which don't support them.
llvm-svn: 160000
2012-07-10 17:30:44 +00:00
Arnaud A. de Grandmaison 617f5269c3 Adds support for auto-detection of compilation databases, looking in a directory and all its parents.
llvm-svn: 159998
2012-07-10 16:56:35 +00:00
Axel Naumann b307400326 Improve r159256 following Chandler's comments:
Implement UniqueFileContainer::erase(), camelCase, add comment on future optimizations of the cache versus de-optimizations of invalidations.

llvm-svn: 159997
2012-07-10 16:50:27 +00:00
Anna Zaks 8698dd63d7 [analyzer] Remove redundant check (scalar type is a superset of integer)
PR13319 Reported by Jozsef Mihalicza.

llvm-svn: 159996
2012-07-10 16:27:55 +00:00
Axel Naumann b2f1a46402 Clear diagnostic counts after processing the diagnostics.
The consumer might see multiple input files (e.g. for cling) and since r159977 the count is maintained across input files.

llvm-svn: 159995
2012-07-10 16:24:07 +00:00
Chandler Carruth 77d940011d Fix a bug where I didn't test for an empty range before inspecting the
back of it.

I don't have anything even remotely close to a test case for this. It
only broke two build bots, both of them doing bootstrap builds, one of
them a dragonegg bootstrap. It doesn't break for me when I bootstrap
either. It doesn't reproduce every time or on many machines during the
bootstrap. Many thanks to Duncan Sands who got the exact command (and
stage of the bootstrap) which failed on the dragonegg bootstrap and
managed to get it to trigger under valgrind with debug symbols. The fix
was then found by inspection.

llvm-svn: 159993
2012-07-10 15:41:33 +00:00
Manuel Klimek a9c86c980b Fixes the MSVC build.
llvm-svn: 159992
2012-07-10 14:21:30 +00:00
Nadav Rotem d908ddc186 Improve the loading of load-anyext vectors by allowing the codegen to load
multiple scalars and insert them into a vector. Next, we shuffle the elements
into the correct places, as before.
Also fix a small dagcombine bug in SimplifyBinOpWithSameOpcodeHands, when the
migration of bitcasts happened too late in the SelectionDAG process.

llvm-svn: 159991
2012-07-10 13:25:08 +00:00
Manuel Klimek 65fd0e1fd3 Adds support for auto-detection of compilation databases
from a source file and changes clang-check to make use of this.

This makes clang-check just work on in-tree builds, and allows
easy setup via a symlink per source directory to make clang-check
work without any extra configuration.

llvm-svn: 159990
2012-07-10 13:10:51 +00:00
Richard Barton 1dc44dcedd Fix instruction description of VMOV (between two ARM core registers and two single-precision resiters) (and do it properly this time!
llvm-svn: 159989
2012-07-10 12:51:09 +00:00
Alexey Samsonov 2d4bd13eb6 [Sanitizer] fix CMake build
llvm-svn: 159988
2012-07-10 09:17:06 +00:00
Manuel Klimek af18d52c09 Update the docs with specifics about escaping of compile commands.
llvm-svn: 159987
2012-07-10 08:05:54 +00:00
Alexey Samsonov 9f666ea6ca [ASan] move flags description to separate header, add comments about them.
llvm-svn: 159985
2012-07-10 07:41:27 +00:00
Craig Topper be41e2daa6 Reverse assembler/disassembler operand order for gather instructions.
llvm-svn: 159983
2012-07-10 06:38:33 +00:00
Chandler Carruth e18614dd17 Add an efficient merge operation to LiveInterval and use it to avoid
quadratic behavior when performing pathological merges. Fixes the core
element of PR12652.

There is only one user of addRangeFrom left: join. I'm hoping to
refactor further in a future patch and have join use this merge
operation as well.

llvm-svn: 159982
2012-07-10 05:16:17 +00:00
Chandler Carruth ac766b9b42 Teach LiveIntervals how to verify themselves and start using it in some
of the trick merge routines. This adds a layer of testing that was
necessary when implementing more efficient (and complex) merge logic for
this datastructure.

No functionality changed here.

llvm-svn: 159981
2012-07-10 05:06:03 +00:00
Chris Lattner 209ad6baa0 Jordan points out that this was incorrect: clang should recover from
*errors* with fixits on them by following the recovery advised by the
fixit, but if it is a fixit on a warning, then obviously the AST 
should be for the code as-written.

llvm-svn: 159980
2012-07-10 05:03:05 +00:00
Jordan Rose b8b2ca6ffb Allow -verify directives to specify a min and max count, not just "+".
void f(); // expected-note 0+ {{previous declaration is here}}
  void g(); // expected-note 0-1 {{previous declaration is here}}

The old "+" syntax is still an alias for "1+", and single numbers still work.

Patch by Andy Gibbs!

llvm-svn: 159979
2012-07-10 02:57:26 +00:00
Jordan Rose e1572eb3e2 Allow line numbers on -verify directives.
// expected-warning@10 {{some text}}

The line number may be absolute (as above), or relative to the current
line by prefixing the number with either '+' or '-'.

Patch by Andy Gibbs!

llvm-svn: 159978
2012-07-10 02:57:03 +00:00
Jordan Rose 6dae761810 Clean up VerifyDiagnosticsConsumer in preparation for upcoming enhancements.
Patch by Andy Gibbs!

llvm-svn: 159977
2012-07-10 02:56:15 +00:00
Richard Trieu 50f5f46a93 Properly update the FormattedArgs vector when the template type diffing falls
back to regular type printing.

llvm-svn: 159976
2012-07-10 01:46:04 +00:00
Greg Clayton cc0c4d4ae7 Improve dynamic type resolution efficiency by looking for the type in the module that contains the vtable symbol first and only look for the first match. If we don't find anything, _then_ move on to the rest of the modules in the target and watch out for multiple matches.
llvm-svn: 159975
2012-07-10 01:22:15 +00:00
Jim Grosbach 16b43dbbfe ARM: Allow more flexible patterns in NEON formats.
Some NEON instructions want to match against normal SDNodes for some
operand types and Intrinsics for others. For example, CTLZ. To enable this,
switch from explicitly requiring Intrinsic on the class templates to using
SDPatternOperator instead.

llvm-svn: 159974
2012-07-10 00:51:13 +00:00
Jim Grosbach 700068206f Allow intrinsics to be used in place of node matchables.
TableGen has support for using an intrinics name directly in a DAG,
but this breaks down when referring to just a node, as that's
handled initializer list stuff entirely via subclassing in the
parser. That is, using an instrinsic like "(int_my_intrinsic ...)"
works fine. Using it standalone for parameterizing the operator
in such a DAG does not.

Fixing this is simple enough, as we simply declare Intrinsic
as deriving from SDPatternOperator, which is the class name
intended for exactly this purpose in TargetSelectionDAG.td.

When the intrinsic is actually used in the DAG pattern, it will
be recognized and expanded to an intrinsic_wo_chain (et. al.)
just like when it's used directly.

Incoming ARM NEON cleanup based on this and a bit of functionality
improvement after that.

llvm-svn: 159973
2012-07-10 00:51:11 +00:00
Jordan Rose 6ea25fe9ce Add an explanation of -Wobjc-literal-compare to the "Objective-C Literals" page
(per Jean-Daniel's suggestion to keep around an explanation of why
direct comparisons on ObjC literals are a bad idea)

llvm-svn: 159972
2012-07-10 00:20:57 +00:00
Akira Hatanaka efff7b763b Make register Mips::RA allocatable if not in mips16 mode.
llvm-svn: 159971
2012-07-10 00:19:06 +00:00
Arnaud A. de Grandmaison cdccafa53c [cindex.py] Make CompileCommand.arguments usage consistent with CompileCommand.directory and the rest of the python binding
Patch by David Röthlisberger

llvm-svn: 159970
2012-07-10 00:00:05 +00:00
Dan Gohman 3d1512384f Delete code for folding undefs in ScalarEvolution. It's invalid in
obscure ways, and it isn't actually important in the real world.

llvm-svn: 159969
2012-07-09 23:51:20 +00:00
Chad Rosier 5e781c6363 Revert 159966 since Tanya temporarily updated the test case.
llvm-svn: 159968
2012-07-09 23:04:15 +00:00
Tanya Lattner 724eaea271 TEMPORARY. I will fix this properly shortly.
Silence buildbot so I can figure out the right flag to put this warning under.

llvm-svn: 159967
2012-07-09 23:01:07 +00:00
Chad Rosier 386433999f Put new warning in r159965 under a flag to appease buildbots. Someone please
verify this is the correct grouping.

llvm-svn: 159966
2012-07-09 22:59:22 +00:00
Tanya Lattner bcffcdfd18 Patch by Anton Lokhmotov to add OpenCL work group size attributes.
llvm-svn: 159965
2012-07-09 22:06:01 +00:00
Dmitri Gribenko 17709ae8d9 Comment lexing: fix lexing to actually work in non-error cases.
llvm-svn: 159963
2012-07-09 21:32:40 +00:00
Jason Molenda 55831d8b9f Add lldb.1 to the xcode project file, add a copy files phase to install it.
<rdar://problem/10613024> 

llvm-svn: 159962
2012-07-09 21:16:31 +00:00
Abramo Bagnara cb43567374 The delete argument should not be converted to void*.
llvm-svn: 159961
2012-07-09 21:15:43 +00:00
Chad Rosier aeed158f75 Revert r159938 (and r159945) to appease the buildbots.
llvm-svn: 159960
2012-07-09 20:43:34 +00:00
Andrew Trick fb982ddeda Machine model: allow itineraries to be shared by different processor models.
llvm-svn: 159959
2012-07-09 20:43:03 +00:00
Andrew Trick c50f06487c indentation
llvm-svn: 159958
2012-07-09 20:43:01 +00:00
Owen Anderson d4b841f8f9 Teach the DAG combiner to turn sitofp/uitofp from i1 into a conditional move, since there are only two possible values.
Previously, this would become an integer extension operation, followed by a real integer->float conversion.

llvm-svn: 159957
2012-07-09 20:31:12 +00:00
Fariborz Jahanian 05d0d447c4 objective-c: provide fixit hint for @autoreleasepool
and similar other keywords. // rdar://10723084

llvm-svn: 159956
2012-07-09 20:00:35 +00:00
Manman Ren 5f6fa428fa X86: implement functions to analyze & synthesize CMOV|SET|Jcc
getCondFromSETOpc, getCondFromCMovOpc, getSETFromCond, getCMovFromCond

No functional change intended.
If we want to update the condition code of CMOV|SET|Jcc, we first analyze the
opcode to get the condition code, then update the condition code, finally
synthesize the new opcode form the new condition code.

llvm-svn: 159955
2012-07-09 18:57:12 +00:00
Matt Beaumont-Gay ad0bb8e361 Silence unused variable warning in -Asserts build
llvm-svn: 159954
2012-07-09 18:55:31 +00:00
Akira Hatanaka 9bf2b5677d Reapply r158846.
Access mips register classes via MCRegisterInfo's functions instead of via the
TargetRegisterClasses defined in MipsGenRegisterInfo.inc.

llvm-svn: 159953
2012-07-09 18:46:47 +00:00
Nuno Lopes 95cc4f3cb5 instcombine: merge the functions that remove dead allocas and dead mallocs/callocs/...
This patch removes ~70 lines in InstCombineLoadStoreAlloca.cpp and makes both functions a bit more aggressive than before :)
In theory, we can be more aggressive when removing an alloca than a malloc, because an alloca pointer should never escape, but we are not taking advantage of this anyway

llvm-svn: 159952
2012-07-09 18:38:20 +00:00
Jim Grosbach 2987c57924 Tests: check for target availability for target-specific tests.
Lots of tests are using an explicit target triple w/o first checking that the
target is actually available. Add a REQUIRES clause to a bunch of them. This should
hopefully unbreak bots which don't configure w/ all targets enabled.

llvm-svn: 159949
2012-07-09 18:34:21 +00:00
Richard Barton 984d0ba6b6 Some formatting to keep Clang happy
llvm-svn: 159948
2012-07-09 18:30:56 +00:00
Richard Barton 5beef2d242 Oops - correct broken disassembly for VMOV
llvm-svn: 159945
2012-07-09 18:20:02 +00:00
Fariborz Jahanian dbed9d42fd objective-c: yank any use of "non-fragile abi" phrase
from diagnostics. // rdar://9657485

llvm-svn: 159943
2012-07-09 17:54:36 +00:00
Chad Rosier 6213549751 80-column and whitespace.
llvm-svn: 159942
2012-07-09 17:31:28 +00:00
Jordan Rose 12e730c6e3 Better parser recovery in Objective-C containers.
Previously it was possible to get an infinite-loop-on-invalid with a namespace
decl within @interface. Since 'namespace' is normally a safe place to retry
top-level parsing, we just didn't consume the token.

This adds a flag that tracks whether we have temporarily left Objective-C
scope to parse a C-like declaration, and uses that to better recover from
parse problems by stopping at possible method declarations and at @end. To
fix the original problem, we do /not/ stop at 'namespace' when in an
Objective-C @interface or @protocol context (but still do in @implementation).

llvm-svn: 159941
2012-07-09 16:54:53 +00:00