Commit Graph

141294 Commits

Author SHA1 Message Date
Eric Christopher 5724ee9765 Harden this test a bit to work on the mac with ancient gdbs.
llvm-svn: 172752
2013-01-17 20:09:50 +00:00
Aaron Ballman bea6c8d36a Reverting back to the fallback instead of using the 64-bit popcnt instruction as it doesn't exist on all x64 CPU architectures.
llvm-svn: 172751
2013-01-17 20:04:28 +00:00
Daniel Dunbar 8a81c24312 [Linker] Drop support for IR-level extended linking support (archives, etc.).
- This code is dead, and the "right" way to get this support is to use the
   platform-specific linker-integrated LTO mechanisms, or the forthcoming LLVM
   linker.

llvm-svn: 172749
2013-01-17 19:52:25 +00:00
Peter Collingbourne 6600516a58 Have ReExec read environment from /proc/self/environ
It is possible for ReExec to be called before the C standard library
has initialised itself sufficiently for execv to work properly.
Fix this by parsing the environment ourselves and using execve.

Differential Revision: http://llvm-reviews.chandlerc.com/D304

llvm-svn: 172748
2013-01-17 19:50:42 +00:00
Bill Schmidt 94b8cdbf55 Restore reverted test case, this time with REQUIRES: asserts
llvm-svn: 172747
2013-01-17 19:46:51 +00:00
Bill Schmidt b400204fd8 Remove bad test case
llvm-svn: 172746
2013-01-17 19:39:36 +00:00
Bill Schmidt dee1ef8f53 This patch fixes PR13626 by providing i128 support in the return
calling convention.  128-bit integers are now properly returned
in GPR3 and GPR4 on PowerPC.

llvm-svn: 172745
2013-01-17 19:34:57 +00:00
Chad Rosier e343bc83f0 [ms-inline asm] Updates and test case for r172743.
Part of rdar://12576868

llvm-svn: 172744
2013-01-17 19:22:48 +00:00
Chad Rosier d0ed73acb4 [ms-inline asm] Add support for the 'SIZE' and 'LENGTH' operators.
Part of rdar://12576868

llvm-svn: 172743
2013-01-17 19:21:48 +00:00
Chad Rosier 4edf11fcf0 [ms-inline asm] Extend the Sema interface to get the size and length of a
VarDecl.
Part of rdar://12576868

llvm-svn: 172742
2013-01-17 19:21:24 +00:00
Daniel Dunbar 1dc66cafca [docs] Get rid of some UTF8 characters (non-breaking space maybe).
llvm-svn: 172741
2013-01-17 18:57:32 +00:00
Daniel Dunbar 8bbf26f59e [utils] Update find-rev utility to take a branch argument (name of the git-svn
branch).

llvm-svn: 172740
2013-01-17 18:57:21 +00:00
Jordan Rose aa7a3b3e75 Format strings: correct signedness if already correcting width (%d,%u).
It is valid to do this:
  printf("%u", (int)x);

But if we see this:
  printf("%lu", (int)x);

...our fixit should suggest %d, not %u.

llvm-svn: 172739
2013-01-17 18:47:16 +00:00
Jordan Rose b169ccc118 Convert test/FixIt/format-darwin.m to use relative line numbers.
llvm-svn: 172738
2013-01-17 18:47:12 +00:00
Jyotsna Verma 9b60c1d171 Add indexed load/store instructions for offset validation check.
This patch fixes bug 14902 - http://llvm.org/bugs/show_bug.cgi?id=14902

llvm-svn: 172737
2013-01-17 18:42:37 +00:00
Michael Gottesman 1d777513e5 Added missing const from my last commit.
llvm-svn: 172736
2013-01-17 18:36:17 +00:00
Michael Gottesman 782e34474a [ObjCARC] Implemented operator<< for InstructionClass and changed a ``Visited'' Debug message to use it.
llvm-svn: 172735
2013-01-17 18:32:34 +00:00
Aaron Ballman 892a8ebf32 Reverting back to the fallback instead of using popcnt; this instruction doesn't exist on all CPU architectures. Fixes PR14982
llvm-svn: 172734
2013-01-17 18:27:30 +00:00
Bill Schmidt 6b2940b01e This patch fixes the PPC calling convention to handle returns of
_Complex float and _Complex long double, by simply increasing the
number of floating point registers available for return values.

The test case verifies that the correct registers are loaded.

llvm-svn: 172733
2013-01-17 17:45:19 +00:00
Joey Gouly 1d58cdbf4e Add some semantic checks for OpenCL. Variadic macros, VLAs and bitfields are not supported.
llvm-svn: 172732
2013-01-17 17:35:00 +00:00
Nico Weber 80a82761bd Formatter: Get bit tests in ifs right.
It's generally not possible to know if 'a' '*' 'b' is a multiplication
expression or a variable declaration with a purely lexer-based approach. The
formatter currently uses a heuristic that classifies this token sequence as a
multiplication in rhs contexts (after '=' or 'return') and as a declaration
else.

Because of this, it gets bit tests in ifs, such as "if (a & b)" wrong. However,
declarations in ifs always have to be followed by '=', so this patch changes
the formatter to classify '&' as an operator if it's at the start of an if
statement.

Before:
  if (a& b)
  if (int* b = f())

Now:
  if (a & b)
  if (int* b = f())

llvm-svn: 172731
2013-01-17 17:17:19 +00:00
Will Dietz 149d952e86 [ubsan] Add SANITIZER_INTERFACE_ATTRIBUTE to __ubsan_vptr_type_cache
Missed this one previously.

llvm-svn: 172730
2013-01-17 17:14:12 +00:00
Dmitri Gribenko 764ea24cfd Documentation: formatting
llvm-svn: 172729
2013-01-17 17:04:54 +00:00
Sylvestre Ledru 7f6a520b2c Under GNU/Linux & HURD, add a soname to the liblldb shared library.
llvm-svn: 172728
2013-01-17 16:59:32 +00:00
Alexey Samsonov 4f1885a109 [ASan] minor changes to swapcontext handling: don't clear shadow memory if context stack is too large
llvm-svn: 172727
2013-01-17 15:45:28 +00:00
Alexey Samsonov 708442294e ASan: Allow __asan_get_allocated_size(malloc(0)) to be 0 or 1
llvm-svn: 172726
2013-01-17 15:26:47 +00:00
Kostya Serebryany 87eb229241 [asan] attempting to fix the Mac build
llvm-svn: 172725
2013-01-17 15:14:20 +00:00
Daniel Malea c85a058ce0 fix 'const const' typo introduced in r172647
llvm-svn: 172724
2013-01-17 15:05:55 +00:00
Kostya Serebryany 709d0dac81 [asan] restructure read/pread/pread64 tests
llvm-svn: 172723
2013-01-17 14:58:29 +00:00
Kostya Serebryany 5cdd91fc43 [sanitizer] move write/pwrite/pwrite64 interceptors to common
llvm-svn: 172722
2013-01-17 14:48:03 +00:00
Kostya Serebryany b114d01849 [msan] start using common interceptors in msan
llvm-svn: 172721
2013-01-17 13:57:07 +00:00
Evgeniy Stepanov e3a325197a [msan] More interceptors.
strtod and friends, dladdr, getrusage

llvm-svn: 172720
2013-01-17 13:42:17 +00:00
Kostya Serebryany f7f5566055 [tsan] move prctl interceptor from asan to common_interceptors thus enabling it for tsan too
llvm-svn: 172719
2013-01-17 13:38:16 +00:00
Daniel Jasper fefb1e6257 Allow breaking after the trailing const after a function declaration.
Before:
void aaaaaaaaaaaa(int aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa) const GUARDED_BY(
    aaaaaaaaaaaaa);

After:
void aaaaaaaaaaaa(int aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa) const
    GUARDED_BY(aaaaaaaaaaaaa);

llvm-svn: 172718
2013-01-17 13:31:52 +00:00
Alexey Samsonov 769af07372 [ASan] fix __asan_get_ownership(p) and __asan_get_allocated_size(p) for the p = malloc(0)
llvm-svn: 172717
2013-01-17 13:25:17 +00:00
Chandler Carruth 0153800601 Add initial rough support for synthesizing linker options when passed
-fopenmp in the link step on Linux. There is probably more tweaking that
will need to take place to get good support for linking the relevant
libraries on all Linux distributions and/or on other platforms, but this
get's the ball moving and allows Clang to build programs which contain
OpenMP pragmas that can be safely ignored by a compiler that doesn't
implement them, and yet makes direct calls into the OpenMP runtime.

llvm-svn: 172715
2013-01-17 13:19:29 +00:00
Kostya Serebryany 125e26d49b [tsan] add write_range/read_range hooks to common interceptors called from tsan (to find races on read/pread/etc)
llvm-svn: 172714
2013-01-17 13:18:40 +00:00
Kostya Serebryany 93ebdb5d64 [sanitizer] a bit more unification for interceptors (merge read/pread/pread64 in asan and tsan)
llvm-svn: 172713
2013-01-17 13:09:00 +00:00
Dmitry Vyukov 59e5d358db tsan: fix a bug
llvm-svn: 172712
2013-01-17 12:59:10 +00:00
Daniel Jasper 11cb81cd6f Improve handling of comments in static initializers.
Also adding more tests.

We can now keep the formatting of something like:

static SomeType type = { aaaaaaaaaaaaaaaaaaaa, /* comment */
                         aaaaaaaaaaaaaaaaaaaa /* comment */,
                         /* comment */ aaaaaaaaaaaaaaaaaaaa,
                         aaaaaaaaaaaaaaaaaaaa, // comment
                         aaaaaaaaaaaaaaaaaaaa };

Note that the comment in the first line is handled like a trailing line comment
as that is likely what the user intended.

llvm-svn: 172711
2013-01-17 12:53:34 +00:00
Dmitry Vyukov e528f67c14 tsan: fix a bug
llvm-svn: 172710
2013-01-17 12:13:03 +00:00
Alexey Samsonov 347bcd3c5c ASan: add optional 'zero-based shadow' option to ASan passes. Always tell the values of shadow scale and offset to the runtime
llvm-svn: 172709
2013-01-17 11:12:32 +00:00
Elena Demikhovsky f6a30e05d5 Optimization for the following SIGN_EXTEND pairs:
v8i8  -> v8i64, 
v8i8  -> v8i32, 
v4i8  -> v4i64, 
v4i16 -> v4i64 
for AVX and AVX2.

Bug 14865.

llvm-svn: 172708
2013-01-17 09:59:53 +00:00
David Blaikie b61b815fc8 Improve -Wreorder to handle cases of anonymous class member ordering
llvm-svn: 172707
2013-01-17 08:49:22 +00:00
NAKAMURA Takumi 98154a917f clang/test/Index/code-completion-skip-bodies.cpp: Check stdout and stderr individually, rather than mixed output of stdout and stderr with 2>&1.
XFAIL(s) are removed.

llvm-svn: 172705
2013-01-17 07:27:55 +00:00
Craig Topper c7e6feee42 Combine AVX and SSE forms of MOVSS and MOVSD into the same multiclasses so they get instantiated together.
llvm-svn: 172704
2013-01-17 06:59:42 +00:00
Nico Weber 772fbfda45 Revert most of r172140.
r172140 changed the formatter to produce "-(id) foo" instead of "- (id)foo"
in google style, with a link to
http://google-styleguide.googlecode.com/svn/trunk/objcguide.xml#Method_Declarations_and_Definitions
as reference.  But now that I look at that link again, it seems I didn't
read it very carefully the first time round.

llvm-svn: 172703
2013-01-17 06:14:50 +00:00
Jason Molenda d0011a92d1 Add one more bit of logging for armv7 watchpoint debugging.
llvm-svn: 172702
2013-01-17 05:34:17 +00:00
David Blaikie 3fc2f9114a ArrayRef-ize some ctor initializer related APIs
llvm-svn: 172701
2013-01-17 05:26:25 +00:00
David Blaikie 3ae79d9b8b Remove some unnecessary casts
llvm-svn: 172700
2013-01-17 05:26:21 +00:00