- Mar 21, 2013
-
-
rdar://problem/13037793Douglas Gregor authored
<rdar://problem/13037793> Allow the names of modules to differ from the name of their subdirectory in the include path. llvm-svn: 177621
-
John McCall authored
enum return type to be converted to blocks with any integer type of the same size. rdar://13463504 llvm-svn: 177613
-
Manman Ren authored
Testing cases for structs of structs and unions of structs. llvm-svn: 177612
-
David Blaikie authored
This isn't necessary & with the next change to LLVM the DW_TAG_file_type entry won't be emitted at all - only the raw filename/directory pair, so match on that directly instead. llvm-svn: 177609
-
Richard Smith authored
* libclang_rt-san-* is sanitizer_common, and is linked in only if no other sanitizer runtime is present. * libclang_rt-ubsan-* is the piece of the runtime which doesn't depend on a C++ ABI library, and is always linked in. * libclang_rt-ubsan_cxx-* is the piece of the runtime which depends on a C++ ABI library, and is only linked in when linking a C++ binary. This change also switches us to using -whole-archive for the ubsan runtime (which is made possible by the above split), and switches us to only linking the sanitizer runtime into the main binary and not into DSOs (which is made possible by using -whole-archive). The motivation for this is to only link a single copy of sanitizer_common into any binary. This is becoming important now because we want to share more state between multiple sanitizers in the same process (for instance, we want a single shared output mutex). The Darwin ubsan runtime is unchanged; because we use a DSO there, we don't need this complexity. llvm-svn: 177605
-
- Mar 20, 2013
-
-
Reid Kleckner authored
Reviewers: rjmccall CC: timurrrr, llvm-commits Differential Revision: http://llvm-reviews.chandlerc.com/D554 llvm-svn: 177589
-
rdar://problem/12368093Douglas Gregor authored
<rdar://problem/12368093> Extend module maps with a 'conflict' declaration, and warn when a newly-imported module conflicts with an already-imported module. llvm-svn: 177577
-
Jordan Rose authored
This fixes some mistaken condition logic in RegionStore that caused global variables to be invalidated when /any/ region was invalidated, rather than only as part of opaque function calls. This was only being used by CStringChecker, and so users will now see that strcpy() and friends do not invalidate global variables. Also, add a test case we don't handle properly: explicitly-assigned global variables aren't being invalidated by opaque calls. This is being tracked by <rdar://problem/13464044>. llvm-svn: 177572
-
Jordan Rose authored
Due to improper modelling of copy constructors (specifically, their const reference arguments), we were producing spurious leak warnings for allocated memory stored in structs. In order to silence this, we decided to consider storing into a struct to be the same as escaping. However, the previous commit has fixed this issue and we can now properly distinguish leaked memory that happens to be in a struct from a buffer that escapes within a struct wrapper. Originally applied in r161511, reverted in r174468. <rdar://problem/12945937> llvm-svn: 177571
-
Jordan Rose authored
In this case, the value of 'x' may be changed after the call to indirectAccess: struct Wrapper { int *ptr; }; void indirectAccess(const Wrapper &w); void test() { int x = 42; Wrapper w = { x }; clang_analyzer_eval(x == 42); // TRUE indirectAccess(w); clang_analyzer_eval(x == 42); // UNKNOWN } This is important for modelling return-by-value objects in C++, to show that the contents of the struct are escaping in the return copy-constructor. <rdar://problem/13239826> llvm-svn: 177570
-
David Blaikie authored
(this is a paired commit with an LLVM change to DIBuilder - expect some buildbot skew/fallout) llvm-svn: 177565
-
David Blaikie authored
The #line directive is mostly for backend testing (keeping these files matching should simplify maintenance somewhat) though the corresponding backend test improvement/update doesn't verify the file information directly just yet. Coming in a later iteration. llvm-svn: 177559
-
Fariborz Jahanian authored
I am not sure how much we can improve for when a randon ObjC keyword is thrown into the ivar decl. block. // rdar://6854840 llvm-svn: 177553
-
Fariborz Jahanian authored
'}' is missing for the ivar declarations. // rdar://6854840 llvm-svn: 177549
-
David Blaikie authored
Fix by Ismail Pazarbasi (ismail.pazarbasi@gmail.com), review by Dmitri Gribenko. llvm-svn: 177546
-
Manman Ren authored
For constructors/desctructors that return 'this', if there exists a callsite that returns 'this' and is immediately before the return instruction, make sure we are using the return value from the callsite. We don't need to keep 'this' alive through the callsite. It also enables optimizations in the backend, such as tail call optimization. Updated from r177211. rdar://12818789 llvm-svn: 177541
-
Hans Wennborg authored
We were checking "Arch == llvm::Triple::x86_64 || Arch == llvm::Triple::x86_64", but the rhs should actually check for powerpc64. Found while experimenting with a potential new Clang warning. llvm-svn: 177496
-
David Blaikie authored
The backend portion of this test will be committed to LLVM's test suite. llvm-svn: 177485
-
Richard Smith authored
llvm-svn: 177480
-
Nick Lewycky authored
emit function names in .gcda files by default, and the flag turns that off! Rename the flag to make it match what it actually does. This keeps the default format compatible with gcc 4.2. Also add a test for this flag. llvm-svn: 177475
-
John McCall authored
performing unqualified lookup for a friend class declaration. rdar://13393749 llvm-svn: 177473
-
Nick Lewycky authored
is enabled. Also add a new -test-coverage cc1 flag which makes testing coverage possible and add our first clang-side coverage test. llvm-svn: 177470
-
rdar://problem/10796651Douglas Gregor authored
Configuration macros are macros that are intended to alter how a module works, such that we need to build different module variants for different values of these macros. A module can declare its configuration macros, in which case we will complain if the definition of a configation macro on the command line (or lack thereof) differs from the current preprocessor state at the point where the module is imported. This should eliminate some surprises when enabling modules, because "#define CONFIG_MACRO ..." followed by "#include <module/header.h>" would silently ignore the CONFIG_MACRO setting. At least it will no longer be silent about it. Configuration macros are eventually intended to help reduce the number of module variants that need to be built. When the list of configuration macros for a module is exhaustive, we only need to consider the settings for those macros when building/finding the module, which can help isolate modules for various project-specific -D flags that should never affect how modules are build (but currently do). llvm-svn: 177466
-
David Blaikie authored
Mostly, try to depend on the annotation comments more so these tests are more legible, brief, and agnostic to schema changes in the future (sure, they're not agnostic to changes to the comment annotations but since they're easier to read they should be easier to update if that happens). llvm-svn: 177457
-
Jordan Rose authored
A floating-point version is nice for testing unknown values, but it's good to be able to check all parts of the structure as well. Test change only, no functionality change. llvm-svn: 177455
-
- Mar 19, 2013
-
-
Anna Zaks authored
This fixes a crash when analyzing LLVM that was exposed by r177220 (modeling of trivial copy/move assignment operators). When we look up a lazy binding for “Builder”, we see the direct binding of Loc at offset 0. Previously, we believed the binding, which led to a crash. Now, we do not believe it as the types do not match. llvm-svn: 177453
-
Jordan Rose authored
(see previous commit) llvm-svn: 177449
-
Chad Rosier authored
llvm-svn: 177441
-
Fariborz Jahanian authored
closing rbrace is missing in an ObjC class declaration. Can do beter than this, but it involves addition of overhead which will be present in correct code. // rdar://6854840 llvm-svn: 177435
-
Adrian Prantl authored
Relax test to allow for attributes on other architectures. Caught by powerpc64-unknown-linux-gnu buildbot. llvm-svn: 177419
-
Chad Rosier authored
llvm-svn: 177414
-
Rafael Espindola authored
llvm-svn: 177402
-
Rafael Espindola authored
-no-integrated-as. It is the only assembler we have there. llvm-svn: 177398
-
Alexey Samsonov authored
llvm-svn: 177391
-
John McCall authored
we expect a related result type. rdar://12493140 llvm-svn: 177378
-
rdar://problem/13363214Douglas Gregor authored
<rdar://problem/13363214> Eliminate race condition between module rebuild and the global module index. The global module index was querying the file manager for each of the module files it knows about at load time, to prune out any out-of-date information. The file manager would then cache the results of the stat() falls used to find that module file. Later, the same translation unit could end up trying to import one of the module files that had previously been ignored by the module cache, but after some other Clang instance rebuilt the module file to bring it up-to-date. The stale stat() results in the file manager would trigger a second rebuild of the already-up-to-date module, causing failures down the line. The global module index now lazily resolves its module file references to actual AST reader module files only after the module file has been loaded, eliminating the stat-caching race. Moreover, the AST reader can communicate to its caller that a module file is missing (rather than simply being out-of-date), allowing us to simplify the module-loading logic and allowing the compiler to recover if a dependent module file ends up getting deleted. llvm-svn: 177367
-
Richard Smith authored
it wasn't taking into account that the float should be truncated *before* the range check happens. Thus (unsigned)-0.99 and (unsigned char)255.9 have defined behavior and should not be trapped. llvm-svn: 177362
-
Argyrios Kyrtzidis authored
llvm-svn: 177359
-
Fariborz Jahanian authored
top-level HeaderDoc tags @functiongroup and @methodgroup to doc. tags recognized. // rdar://12379114 llvm-svn: 177358
-
Richard Smith authored
llvm-svn: 177354
-