Commit Graph

138159 Commits

Author SHA1 Message Date
Ted Kremenek 2317f30f4d Correctly handle IntegralToBool casts in C++ in the static analyzer. Fixes <rdar://problem/12759044>.
llvm-svn: 168843
2012-11-29 00:50:20 +00:00
Chad Rosier 9ae53f8e3a [driver] -mkernel implies -mstrict-align; don't add the redundant option.
rdar://12771737

llvm-svn: 168841
2012-11-29 00:42:06 +00:00
Jim Ingham 8c3f2764fb Add an example of using the target.process.extra-startup-command to turn on debugserver logging since
we always forget how to do this...

llvm-svn: 168840
2012-11-29 00:41:12 +00:00
Jim Ingham 7730b9a47a Tighten up how we acquire the underlying frame in the SBFrame methods. We were getting
the frame and then getting the run lock.  Which means that our frame could have gotten
invalidated by stopping between the time we got the frame and assured the the target was
stopped.  Now we get the run lock first, and THEN resolve the underlying frame object.

<rdar://problem/12621607>

llvm-svn: 168838
2012-11-29 00:26:19 +00:00
Jakob Stoklund Olesen 546e9e85f1 Avoid rewriting instructions twice.
This could cause miscompilations in targets where sub-register
composition is not always idempotent (ARM).

<rdar://problem/12758887>

llvm-svn: 168837
2012-11-29 00:26:11 +00:00
Daniel Malea e812109868 Rename __lambda to __lambda_node (apply r164404 from libcxxabi)
- fixes gcc 4.6 build problems
- resolves open bugzilla http://llvm.org/bugs/show_bug.cgi?id=13889

llvm-svn: 168835
2012-11-29 00:05:50 +00:00
Jason Molenda b8e5c79af1 Correct the label for the com.apple.debugserver.posix plist.
<rdar://problem/12769073> 

llvm-svn: 168834
2012-11-29 00:01:49 +00:00
Nick Lewycky 1af94eb075 Issue a fatal error if the line doesn't have a regular expression.
Also a couple not-user-visible changes; using empty() instead of size(), and
make inSection() not insert NULL Regex*'s into StringMap when doing a lookup.

llvm-svn: 168833
2012-11-29 00:01:38 +00:00
Nadav Rotem 307d767177 When combining consecutive stores allow loads in between the stores, if the loads do not alias.
llvm-svn: 168832
2012-11-29 00:00:08 +00:00
Daniel Malea 16e126c70b Linux buildbot fix: detect swig tool from PATH in shell script (before searching hardcoded directories)
llvm-svn: 168831
2012-11-28 23:49:11 +00:00
Bill Wendling f3614fd8e2 When we delete a dead basic block, see if any of its successors are dead and
delete those as well.

llvm-svn: 168829
2012-11-28 23:23:48 +00:00
Daniel Malea 9bbc8da517 Add 'class' keyword to friend definition (to fix gcc 4.6 build)
llvm-svn: 168827
2012-11-28 23:20:22 +00:00
Michael Han ddc016d4d7 Implement C++11 [dcl.attr.grammar] p4: If an attribute-specifier-seq appertains to a friend declaration, that declaration shall be a definition.
llvm-svn: 168826
2012-11-28 23:17:40 +00:00
Fariborz Jahanian 998f0a3360 objective-C blocks: Make sure that identical logic is used
in deciding a copy/dispose field is needed in a byref structure
and when generating the copy/dispose helpers. In certain
cases, these fields were being added but no copy/dispose was
being generated. This was uncovered in ARC, but not in MRR.
// rdar://12759433

llvm-svn: 168825
2012-11-28 23:12:17 +00:00
Richard Smith a118c6a8c0 Per C++11 [except.spec]p2, rvalue references are not permitted in exception specifications.
llvm-svn: 168824
2012-11-28 22:52:42 +00:00
Richard Smith 8606d75265 PR14388: An array or function type in an exception specification should be
decayed to a pointer type. Patch by WenHan Gu, with a little tweaking and
additional testcases by me.

llvm-svn: 168822
2012-11-28 22:33:28 +00:00
Manman Ren 836a93bdb3 ABI: comments from Eli on r168820.
rdar://12723368

llvm-svn: 168821
2012-11-28 22:29:41 +00:00
Manman Ren 84b921f805 ABI: modify CreateCoercedLoad and CreateCoercedStore to not use load or store of
the original parameter or return type.

Since we do not accurately represent the data fields of a union, we should not
directly load or store a union type.

As an exmple, if we have i8,i8, i32, i32 as one field type and i32,i32 as
another field type, the first field type will be chosen to represent the union.
If we load with the union's type, the 3rd byte and the 4th byte will be skipped.

rdar://12723368

llvm-svn: 168820
2012-11-28 22:08:52 +00:00
Richard Smith 58db83d11d PR13098: If we're instantiating an overloaded binary operator and we could
determine which member function would be the callee from within the template
definition, don't pass that function as a "non-member function" to
CreateOverloadedBinOp. Instead, just rely on it to select the member function
for itself.

llvm-svn: 168818
2012-11-28 21:47:39 +00:00
Dmitri Gribenko 5cb3f1097f Documentation: improve formatting and remove unneeded empty lines.
llvm-svn: 168817
2012-11-28 21:40:54 +00:00
Michael Ilseman 37018f8322 Whoops, fixed bad merge
llvm-svn: 168816
2012-11-28 21:21:18 +00:00
Michael Ilseman 1833e000a3 Fixed bad test case
llvm-svn: 168815
2012-11-28 21:19:52 +00:00
Michael Ilseman 018530268d Fast-math: IRBuilder test for creating instructions with fast-math flags
llvm-svn: 168814
2012-11-28 21:17:34 +00:00
Michael Ilseman be6871db58 Fast-math: Extend IRBuilder to have settable FastMathFlags to create instructions with
Also extended IRBuilder's documentation to mention the convenience state for DefaultFPMathTag and FastMathFlags that can be set.

llvm-svn: 168812
2012-11-28 21:16:19 +00:00
Michael Ilseman 8e5db2d07a Fast-math comments and convenience method
llvm-svn: 168811
2012-11-28 21:11:25 +00:00
Jyotsna Verma 519b3856dd Define signed const-ext immediate operands and their predicates.
llvm-svn: 168810
2012-11-28 20:58:14 +00:00
Benjamin Kramer b1996da782 ARM: Implement CanLowerReturn so large vectors get expanded into sret.
Fixes 14337.

llvm-svn: 168809
2012-11-28 20:55:10 +00:00
Jim Ingham 75f27e8610 Cleanup - remove declarations of unimplemented functions.
llvm-svn: 168807
2012-11-28 20:09:03 +00:00
Jakob Stoklund Olesen 26c9d70d28 Make the LiveRegMatrix analysis available to targets.
No functional change, just moved header files.

Targets can inject custom passes between register allocation and
rewriting. This makes it possible to tweak the register allocation
before rewriting, using the full global interference checking available
from LiveRegMatrix.

llvm-svn: 168806
2012-11-28 19:13:06 +00:00
Jordan Rose 85ff8f281e [analyzer] scan-build: Don't forget to close our temp file for Clang's output.
Also, minor whitespace/indentation fixes.

Patch by Peeter Joot!

llvm-svn: 168805
2012-11-28 19:12:44 +00:00
Jordan Rose dbbbf55119 [analyzer] scan-build: Treat '.C' files as C++.
Part of PR14443.

llvm-svn: 168804
2012-11-28 19:12:29 +00:00
Eli Bendersky 10f22d7054 Add backreference matching capabilities to Support/Regex, with
appropriate unit tests. This change in itself is not expected to
affect any functionality at this point, but it will serve as a
stepping stone to improve FileCheck's variable matching capabilities.

Luckily, our regex implementation already supports backreferences,
although a bit of hacking is required to enable it. It supports both
Basic Regular Expressions (BREs) and Extended Regular Expressions
(EREs), without supporting backrefs for EREs, following POSIX strictly
in this respect. And EREs is what we actually use (rightly). This is
contrary to many implementations (including the default on Linux) of
POSIX regexes, that do allow backrefs in EREs.

Adding backref support to our EREs is a very simple change in the
regcomp parsing code. I fail to think of significant cases where it
would clash with existing things, and can bring more versatility to
the regexes we write. There's always the danger of a backref in a
specially crafted regex causing exponential matching times, but since
we mainly use them for testing purposes I don't think it's a big
problem. [it can also be placed behind a flag specific to FileCheck,
if needed].

For more details, see:

* http://lists.cs.uiuc.edu/pipermail/llvmdev/2012-November/055840.html
* http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20121126/156878.html

llvm-svn: 168802
2012-11-28 19:00:02 +00:00
Benjamin Kramer 2069bdaab3 MCJIT depends on JIT.
Unbreaks the CMake shared library build. This is nasty and should be fixed
eventually.

llvm-svn: 168800
2012-11-28 18:35:35 +00:00
Ulrich Weigand 9e159fd7a0 Fix initial frame state on powerpc64.
The createPPCMCAsmInfo routine used PPC::R1 as the initial frame
pointer register, but on PPC64 the 32-bit R1 register does not
have a corresponding DWARF number, causing invalid CIE initial
frame state to be emitted.  Fix by using PPC::X1 instead.

llvm-svn: 168799
2012-11-28 18:21:03 +00:00
Alexey Samsonov 53f7e12909 Refactor -fsanitize, -f*-sanitizer arguments parsing. Provide a more careful diagnostic for invalid sets of sanitizers
llvm-svn: 168794
2012-11-28 17:34:24 +00:00
Kostya Serebryany df5f3028e2 [asan] add DISABLED_BuiltinLongJmpTest
llvm-svn: 168793
2012-11-28 15:01:23 +00:00
Patrik Hägglund 504f4783ed Fix warning. [-Wunused-variable]
llvm-svn: 168792
2012-11-28 14:32:52 +00:00
Patrik Hägglund b476cdfde5 Fix tests with broken datalayout strings.
Buildbot failure at r168785.

llvm-svn: 168791
2012-11-28 13:30:31 +00:00
Dmitry Vyukov 4a48553869 tsan: explicitly say that failed to restore the stack
llvm-svn: 168790
2012-11-28 13:30:06 +00:00
Dmitry Vyukov eb3d36e649 tsan: address several review comments
llvm-svn: 168789
2012-11-28 13:01:32 +00:00
Dmitry Vyukov 3374e3f874 tsan: add log_path parameter (similar to asan)
remove old log_fileno

llvm-svn: 168788
2012-11-28 12:56:52 +00:00
Dmitry Vyukov e1a7f338a3 tsan: dynamic history size
introduces history_size parameter that can be used to control trace size at startup

llvm-svn: 168786
2012-11-28 12:19:50 +00:00
Patrik Hägglund 3eb16c543e Add error handling in getInt.
Accordingly, update a testcase with a broken datalayout string.

Also, we never parse negative numbers, because '-' is used as a
separator. Therefore, use unsigned as result type.

llvm-svn: 168785
2012-11-28 12:13:12 +00:00
Dmitry Vyukov 00e4604d6b tsan: change fast state layout in preparation to dynamic traces
llvm-svn: 168784
2012-11-28 10:49:27 +00:00
Dmitry Vyukov 2429b02770 tsan: move traces from tls into dedicated storage at fixed address
helps to reduce tls size (it's weird to have multi-MB tls)
will help with dynamically adjustable trace size

llvm-svn: 168783
2012-11-28 10:35:31 +00:00
Kostya Serebryany a873623e54 [asan] Split AddressSanitizer into two passes (FunctionPass, ModulePass), Clang part.
llvm-svn: 168782
2012-11-28 10:32:11 +00:00
Kostya Serebryany dfe9e7933e [asan] Split AddressSanitizer into two passes (FunctionPass, ModulePass), LLVM part. This requires a clang part which will follow.
llvm-svn: 168781
2012-11-28 10:31:36 +00:00
Tobias Grosser 70325bb308 cmake: Fix installation of include files
Install the configured Config/config.h file, rather than the
Config/config.h.cmake and Config/Config.h.in source files.

Contributed-by: Richard Membarth <richard.membarth@informatik.uni-erlangen.de>
llvm-svn: 168780
2012-11-28 10:12:21 +00:00
Bill Wendling 706d3d66e9 Add back support for reading and parsing 'deplibs'.
This is for backwards compatibility for pre-3.x bc files. The code reads the
code, but does nothing with it.

llvm-svn: 168779
2012-11-28 08:41:48 +00:00
Andy Gibbs 17a1306ecc Remove obsolete comment missed by r162937
llvm-svn: 168778
2012-11-28 08:14:36 +00:00