- Jun 16, 2011
-
-
John McCall authored
Language-design credit goes to a lot of people, but I particularly want to single out Blaine Garst and Patrick Beard for their contributions. Compiler implementation credit goes to Argyrios, Doug, Fariborz, and myself, in no particular order. llvm-svn: 133103
-
John McCall authored
include a specific variable. llvm-svn: 133102
-
Eli Friedman authored
llvm-svn: 133095
-
- Jun 15, 2011
-
-
John McCall authored
Depends on LLVM r133093. llvm-svn: 133094
-
Eli Friedman authored
Use isAnyComplexType here so we don't pass complex numbers into the aggregate handling code; found by inspection. llvm-svn: 133070
-
Eli Friedman authored
llvm-svn: 133069
-
Devang Patel authored
- llvm.dbg.declare already receives line number information from ParmDecl - Additional extra stoppoint messes up gdb's understanding of where function body starts. llvm-svn: 133065
-
Douglas Gregor authored
were just punting on template argument deduction for a number of type nodes. Most of them, obviously, didn't matter. As a consequence of this, make extended vector types (via the ext_vector_type attribute) actually work properly for several important cases: - If the attribute appears in a type-id (i.e, not attached to a typedef), actually build a proper vector type - Build ExtVectorType whenever the size is constant; previously, we were building DependentSizedExtVectorType when the size was constant but the type was dependent, which makes no sense at all. - Teach template argument deduction to handle ExtVectorType/DependentSizedExtVectorType. llvm-svn: 133060
-
Douglas Gregor authored
llvm-svn: 133056
-
Douglas Gregor authored
before the template parameters have acquired a proper context (e.g., because the enclosing context has yet to be built), provide empty parameter lists for all outer template parameter scopes to inhibit any substitution for those template parameters. Fixes PR9643 / <rdar://problem/9251019>. llvm-svn: 133055
-
Jordy Rose authored
- (bounded copies) Be more conservative about how much is being copied. - (str(n)cat) If we can't compute the exact final length of an append operation, we can still lower-bound it. - (stpcpy) Fix the conjured return value at the end to actually be returned. This requires these supporting changes: - C string metadata symbols are still live even when buried in a SymExpr. - "Hypothetical" C string lengths, to represent a value that /will/ be passed to setCStringLength() if all goes well. (The idea is to allow for temporary constrainable symbols that may end up becoming permanent.) - The 'checkAdditionOverflow' helper makes sure that the two strings being appended in a strcat don't overflow size_t. This should never *actually* happen; the real effect is to keep the final string length from "wrapping around" in the constraint manager. This doesn't actually test the "bounded" operations (strncpy and strncat) because they can leave strings unterminated. Next on the list! llvm-svn: 133046
-
Douglas Gregor authored
either imlicitly (for builtins) or explicitly (due to multiple specification of the same attributes). Fixes <rdar://problem/9612060>. llvm-svn: 133045
-
Jordy Rose authored
[analyzer] If a C string length is UnknownVal, clear any existing length binding. No tests yet because the only thing that sets string length is strcpy(), and that needs some work anyway. llvm-svn: 133044
-
Jordy Rose authored
[analyzer] When performing a binary operation on symbolic operands, we convert the symbol values to a common type. But in a relational operation, the result is an 'int' or 'bool', which may not be the appropriate type to convert the operands to. In these cases, use the left-hand operand's type as the conversion type. There's no associated test for this because fully-constrained symbolic values are evaluated ahead of time in normal expressions. This can only come up in checker-constructed expressions (like the ones in an upcoming patch to CStringChecker). llvm-svn: 133041
-
Douglas Gregor authored
protected in the case where a variable is being initialized by a trivial default constructor but has a non-trivial destructor. llvm-svn: 133037
-
Nico Weber authored
llvm-svn: 133036
-
Ted Kremenek authored
Change the output for -Wshift-overflow and -Wshift-sign-overflow to an unsigned hexadecimal. It makes more sense for looking at bits than a signed decimal does. Also, change the diagnostic's wording from "overrides" to "sets". This uses a new optional argument in APInt::toString() that adds the '0x' prefix to hexademical numbers. This fixes PR 9651. Patch by nobled@dreamwidth.org! llvm-svn: 133033
-
Douglas Gregor authored
inference, to be used (only) by the Objective-C rewriter. llvm-svn: 133025
-
Ted Kremenek authored
[format strings] correctly suggest correct type for '%@' specifiers. Fixes <rdar://problem/9607158>. llvm-svn: 133024
-
- Jun 14, 2011
-
-
Chris Lattner authored
lexer is not a paste operator, it is a normal token. This fixes a conformance issue shown here: http://p99.gforge.inria.fr/c99-conformance/c99-conformance-clang-2.9.html and it defines away the crash from before. llvm-svn: 133005
-
-
Douglas Gregor authored
in a noexcept exception specification because it isn't part of the canonical type. This ensures that we keep the exact expression written in the noexcept exception specification, rather than accidentally "adopting" a previously-written and canonically "equivalent" function prototype. Fixes PR10087. llvm-svn: 132998
-
Nico Weber authored
llvm-svn: 132996
-
David Majnemer authored
llvm-svn: 132994
-
Benjamin Kramer authored
llvm-svn: 132990
-
Chris Lattner authored
as constant size arrays. This has slightly different semantics in some insane cases, but allows us to accept some constructs that GCC does. Continue to be pedantic in -std=c99 and other modes. This addressed rdar://8733881 - error "variable-sized object may not be initialized"; g++ accepts same code llvm-svn: 132983
-
-
David Majnemer authored
- Move a test from test/SemaTemplate/instantiate-expr-3.cpp, it did not belong there - Incomplete and abstract types are considered hard errors llvm-svn: 132979
-
Bruno Cardoso Lopes authored
whether it's a data or instruction cache access. llvm-svn: 132977
-
-
Peter Collingbourne authored
llvm-svn: 132973
-
Jordy Rose authored
[analyzer] CStringChecker checks functions in the C standard library, not C++. Its external name is now unix.experimental.CString. llvm-svn: 132958
-
Eli Friedman authored
The LLVM IR representation of byval arguments has a rather strange property: if the alignment of an argument to a call is less than the specified byval alignment for that argument, there is no way to specify the alignment of the implied copy. Therefore, we must ensure that the alignment of the argument is at least the byval alignment. To do this, we have to mess with the alignment of relevant alloca's in some cases, and insert a copy that conceptually shouldn't be necessary in some cases. This patch tries relatively hard to avoid creating an extra copy if it can be avoided (see test3 in the included testcase), but it is not possible to avoid in some cases (like test2 in the included testcase). rdar://9483886 llvm-svn: 132957
-
Jordy Rose authored
llvm-svn: 132956
-
Jordy Rose authored
[analyzer] Fix modeling of strnlen to be more conservative. Move tests we can't properly model (yet?) to string-fail.c. llvm-svn: 132955
-
Eli Friedman authored
Make __gnu_inline__ functions in gnu99 mode work the same way as inline functions in gnu89 mode in terms of redefinitions. rdar://9559708 . llvm-svn: 132953
-
Devang Patel authored
This fixes radar 8757124. llvm-svn: 132949
-
- Jun 13, 2011
-
-
Benjamin Kramer authored
llvm-svn: 132924
-
Douglas Gregor authored
reason to allow the user to control these semantics through a flag. llvm-svn: 132919
-
Douglas Gregor authored
llvm-svn: 132917
-