Bill Wendling
d63f1f5a9c
Remove invalid test. This test requires that dead basic blocks be kept
...
around. That's not how we do things. Besides, the commit message tells us that
it is covered by the GCC test suite.
------------------------------------------------------------------------
r127497 | zwarich | 2011-03-11 13:51:56 -0800 (Fri, 11 Mar 2011) | 3 lines
Fix the GCC test suite issue exposed by r127477, which was caused by stack
protector insertion not working correctly with unreachable code. Since that
revision was rolled out, this test doesn't actual fail before this fix.
------------------------------------------------------------------------
llvm-svn: 161985
2012-08-15 20:54:09 +00:00
Sean Callanan
219fc0f386
Fixed a problem in the JIT memory allocator where
...
allocations of executable memory would not be padded
to account for the size of the allocation header.
This resulted in undersized allocations, meaning that
when the allocation was written to later the next
allocation's header would be corrupted.
llvm-svn: 161984
2012-08-15 20:53:52 +00:00
Jakob Stoklund Olesen
3697143a0b
Add a CoveringSubRegIndices field to SubRegIndex records.
...
This can be used to tell TableGen to use a specific SubRegIndex instead
of synthesizing one when discovering all sub-registers.
llvm-svn: 161982
2012-08-15 20:15:48 +00:00
Jordan Rose
5fc5da0578
[analyzer] Correctly devirtualize virtual method calls in constructors.
...
This is the other half of C++11 [class.cdtor]p4 (the destructor side
was added in r161915). This also fixes an issue with post-call checks
where the 'this' value was already being cleaned out of the state, thus
being omitted from a reconstructed CXXConstructorCall.
llvm-svn: 161981
2012-08-15 20:07:17 +00:00
Matt Beaumont-Gay
22be8d5ab8
Allow 'static' and type qualifiers in K&R parameter type lists.
...
llvm-svn: 161980
2012-08-15 19:53:19 +00:00
Michael J. Spencer
135611f7fc
Properly test the LLVM_USE_RVALUE_REFERENCES macro.
...
llvm-svn: 161979
2012-08-15 19:21:42 +00:00
Michael J. Spencer
1d2d12deb1
Properly test the LLVM_USE_RVALUE_REFERENCES macro.
...
llvm-svn: 161978
2012-08-15 19:16:27 +00:00
Chad Rosier
ecf77b56dd
[ms-inline asm] Don't emit newlines as these are ignored by the AsmParser
...
anyways. Also, simplify some conditional logic.
llvm-svn: 161977
2012-08-15 19:12:42 +00:00
Michael J. Spencer
ef2284fbad
[PathV2] Add mapped_file_region. Implementation for Windows and POSIX.
...
llvm-svn: 161976
2012-08-15 19:05:47 +00:00
Michael J. Spencer
19cd5f2580
Add LLVM_DELETED_FUNCTION compatibility macro.
...
This should replace uses of:
class A {
A(const &A); // DO NOT IMPLEMENT
public:
...
};
llvm-svn: 161975
2012-08-15 18:54:36 +00:00
Daniel Jasper
faaffe373e
Add ASTMatcher for matching extern "C" function declarations.
...
llvm-svn: 161974
2012-08-15 18:52:19 +00:00
Chad Rosier
ba072d6b2c
Fix a typo in VariadicFunction.h that leads to invalid code in macro expansion.
...
Patch by Andy Gibbs <andyg1001@hotmail.co.uk>
llvm-svn: 161973
2012-08-15 18:48:14 +00:00
Fariborz Jahanian
05f4e7181a
Patch to warn about __private_extern__ on tentative definitions
...
as it does something unexpected (but gcc compatible).
Suggest use of __attribute__((visibility("hidden")))
on declaration instead. // rdar://7703982
llvm-svn: 161972
2012-08-15 18:42:26 +00:00
John Criswell
edc84507c7
Fix for PR#13606: http://llvm.org/bugs/show_bug.cgi?id=13606
...
Changed the alignment of an LValue to be 64 bits so that we can handle
alignment values up to half of a 64-bit address space.
llvm-svn: 161971
2012-08-15 18:40:30 +00:00
Owen Anderson
352dfff447
Fix another roundToIntegral bug where very large values could become infinity. Problem and solution identified by Steve Canon.
...
llvm-svn: 161969
2012-08-15 18:28:45 +00:00
Chad Rosier
73e325de55
[ms-inline asm] Add support for clobbers in CodeGen.
...
This is a reapplication of r161914 now that the scoping issue has been resolved
in r161966.
llvm-svn: 161967
2012-08-15 18:12:36 +00:00
Chad Rosier
ad34aef449
[ms-inline asm] Capturing loop-scoped (std::string)Reg with a StringRef is bad.
...
llvm-svn: 161966
2012-08-15 18:09:18 +00:00
Jakob Stoklund Olesen
70a0bbcad2
Make synthesized sub-register indexes available in the target namespace.
...
TableGen sometimes synthesizes missing sub-register indexes. Emit these
indexes as enumerators in the target namespace along with the
user-defined ones.
Also take this opportunity to stop creating new Record objects for
synthetic indexes.
llvm-svn: 161964
2012-08-15 18:00:55 +00:00
Michael Han
1fb908f745
Fix base type of ASTDeclNodeLister.
...
llvm-svn: 161963
2012-08-15 17:56:58 +00:00
Evan Cheng
eec6bc6270
Use vld1/vst1 to load/store f64 if alignment is < 4 and the target allows unaligned access. rdar://12091029
...
llvm-svn: 161962
2012-08-15 17:44:53 +00:00
Jordan Rose
9910720851
[analyzer] Don't try to devirtualize if the class is incomplete.
...
A similar issue to the previous commit, introduced by r161915.
llvm-svn: 161961
2012-08-15 17:33:37 +00:00
Jordan Rose
31c3fa9c24
[analyzer] Only adjust the type of 'this' when we devirtualize a method call.
...
With reinterpret_cast, we can get completely unrelated types in a region
hierarchy together; this was resulting in CXXBaseObjectRegions being layered
directly on an (untyped) SymbolicRegion, whose symbol was from a completely
different type hierarchy. This was what was causing the internal buildbot to
fail.
Reverts r161911, which merely masked the problem.
llvm-svn: 161960
2012-08-15 17:33:34 +00:00
Dmitry Vyukov
1c0b3c6b84
tsan: store sync objects in memory block headers + delete them when the block is freed
...
llvm-svn: 161959
2012-08-15 17:27:20 +00:00
Chad Rosier
b6f46c1af9
[ms-inline asm] Add the left brace source location and improve the pretty
...
printer. Patch by Enea Zaffanella <zaffanella@cs.unipr.it>.
llvm-svn: 161958
2012-08-15 16:53:30 +00:00
Dmitry Vyukov
9f1509fe44
tsan: provide function that imitates write to a region but does not detect races
...
llvm-svn: 161957
2012-08-15 16:52:19 +00:00
Owen Anderson
be7e297b6d
Fix typo in comment.
...
llvm-svn: 161956
2012-08-15 16:42:53 +00:00
Jakob Stoklund Olesen
2ec0c41e01
Add missing Rfalse operand to the predicated pseudo-instructions.
...
When predicating this instruction:
Rd = ADD Rn, Rm
We need an extra operand to represent the value given to Rd when the
predicate is false:
Rd = ADDCC Rfalse, Rn, Rm, pred
The Rd and Rfalse operands are different registers while in SSA form.
Rfalse is tied to Rd to make sure they get the same register during
register allocation.
Previously, Rd and Rn were tied, but that is not required.
Compare to MOVCC:
Rd = MOVCC Rfalse, Rtrue, pred
llvm-svn: 161955
2012-08-15 16:17:24 +00:00
Alexander Potapenko
cfb2a6b074
Remove the extra semicolon reported by the buildbot.
...
llvm-svn: 161954
2012-08-15 15:59:18 +00:00
Dmitry Vyukov
954fc8c3e4
tsan: switch to new allocator
...
llvm-svn: 161953
2012-08-15 15:35:15 +00:00
Alexander Potapenko
f6344ffe39
Introduce asan_intercepted_functions.h which contains the declarations wrapped functions and their wrappers.
...
Those declarations are going to be shared between asan_interceptors.cc and the dynamic runtime library on Mac OS.
llvm-svn: 161952
2012-08-15 15:24:48 +00:00
Alexey Samsonov
5b2c6ea38f
[ASan] lit tests: use nm instead of llvm-nm, until llvm-nm becomes usable on Mac. Port output test change in r161948 to lit
...
llvm-svn: 161951
2012-08-15 14:33:30 +00:00
Dmitry Vyukov
4b5ec3145a
tsan: add some more tests for memory allocator
...
llvm-svn: 161950
2012-08-15 14:25:33 +00:00
Dmitry Vyukov
c693689bb1
tsan: fix several integer overflows
...
llvm-svn: 161949
2012-08-15 14:25:08 +00:00
Alexander Potapenko
6c1de8faa7
Check for filenames and numbers to detect possible problems with asan_symbolize.py on -fPIE binaries.
...
llvm-svn: 161948
2012-08-15 14:00:09 +00:00
Alexander Potapenko
1800362758
Pass offset of the frame address within the binary to addr2line instead of the absolute address.
...
Fixes the problem with -PIE binaries.
llvm-svn: 161947
2012-08-15 13:58:24 +00:00
Alexander Potapenko
07ea07c3ca
Patch the frame address regardless of the frame number.
...
llvm-svn: 161946
2012-08-15 13:23:03 +00:00
Alexander Potapenko
20f9fcc285
Move the prototype of __CFInitialize to asan_mac.h so that asan_malloc_mac.cc may use it in the dynamic library mode.
...
llvm-svn: 161945
2012-08-15 12:23:36 +00:00
Bill Wendling
e1c54262f4
Set the branch probability of branching to the 'normal' destination of an invoke
...
instruction to something absurdly high, while setting the probability of
branching to the 'unwind' destination to the bare minimum. This should set cause
the normal destination's invoke blocks to be moved closer to the invoke.
PR13612
llvm-svn: 161944
2012-08-15 12:22:35 +00:00
Alexander Potapenko
9a168a7405
Use SANITIZER_INTERFACE_ATTRIBUTE instead of __attribute__((visibility("default")))
...
Export CheckFailed, asan_malloc, asan_free, asan_memalign, AsanStackTrace::CompressStack, AsanStackTrace::UncompressStack from the dynamic runtime library.
llvm-svn: 161943
2012-08-15 11:57:52 +00:00
Alexander Potapenko
55df945db2
Make __asan::asan_{malloc,free,memalign} globally visible, so that the dynamic version of the runtime will export them.
...
llvm-svn: 161942
2012-08-15 11:32:15 +00:00
Alexey Samsonov
9fe914b099
[ASan] Port (the last one) tricky interface_test to lit, and a *huge* chunks of boilerplate to run tests for 32/64 bits and all optimization levels. Alas, lit doesn't support for loops in RUN-lines...
...
llvm-svn: 161941
2012-08-15 11:26:57 +00:00
Benjamin Kramer
26b568d9d5
Fix a const violation in the generated disassembler.
...
llvm-svn: 161940
2012-08-15 10:26:44 +00:00
Alexander Potapenko
81a1ec8ea6
Do not attempt to intercept mlock and friends on Windows.
...
llvm-svn: 161939
2012-08-15 09:46:45 +00:00
Alexander Potapenko
785f8bc4ec
Use the common interception machinery for mlock/munlock/mlockall/munlockall.
...
llvm-svn: 161938
2012-08-15 09:22:57 +00:00
Kostya Serebryany
1e575ab8b2
[asan] implement --asan-always-slow-path, which is a part of the improvement to handle unaligned partially OOB accesses. See http://code.google.com/p/address-sanitizer/issues/detail?id=100
...
llvm-svn: 161937
2012-08-15 08:58:58 +00:00
Alexey Samsonov
0e056762ef
[ASan] use clangxx_asan instead of clang_asan for C++ lit tests
...
llvm-svn: 161936
2012-08-15 08:54:14 +00:00
Alexey Samsonov
6016486a16
[ASan] port remaining output and feature tests to lit. TODO: we should in fact run most of the tests for 32/64 bits and for all optimization levels
...
llvm-svn: 161935
2012-08-15 08:29:17 +00:00
Hans Wennborg
420052640f
Check for improper use of 'static' and type qualifiers in array
...
declarators.
They are only allowed for function parameters, and then only on the
outermost array type derivation.
llvm-svn: 161934
2012-08-15 07:42:30 +00:00
Alexey Samsonov
5717f4c1eb
[ASan] port interception and shared library tests to lit
...
llvm-svn: 161933
2012-08-15 07:13:51 +00:00
Alexey Samsonov
682a07cbe1
[ASan] move declaration of __asan_default_options to interface header
...
llvm-svn: 161932
2012-08-15 07:11:14 +00:00