- Feb 16, 2009
-
-
Douglas Gregor authored
prototype, synthesize ParmVarDecls for prototype-less FunctionDecl. llvm-svn: 64666
-
- Feb 15, 2009
-
-
Daniel Dunbar authored
llvm-svn: 64599
-
- Feb 14, 2009
-
-
Daniel Dunbar authored
important for both keeping the generated LLVM simple and for ensuring that integer types are passed/promoted correctly. llvm-svn: 64529
-
-
Douglas Gregor authored
etc.) when we perform name lookup on them. This ensures that we produce the correct signature for these functions, which has two practical impacts: 1) When we're supporting the "implicit function declaration" feature of C99, these functions will be implicitly declared with the right signature rather than as a function returning "int" with no prototype. See PR3541 for the reason why this is important (hint: GCC always predeclares these functions). 2) If users attempt to redeclare one of these library functions with an incompatible signature, we produce a hard error. This patch does a little bit of work to give reasonable error messages. For example, when we hit case #1 we complain that we're implicitly declaring this function with a specific signature, and then we give a note that asks the user to include the appropriate header (e.g., "please include <stdlib.h> or explicitly declare 'malloc'"). In case #2, we show the type of the implicit builtin that was incorrectly declared, so the user can see the problem. We could do better here: for example, when displaying this latter error message we say something like: 'strcpy' was implicitly declared here with type 'char *(char *, char const *)' but we should really print out a fake code line showing the declaration, like this: 'strcpy' was implicitly declared here as: char *strcpy(char *, char const *) This would also be good for printing built-in candidates with C++ operator overloading. The set of C library functions supported by this patch includes all functions from the C99 specification's <stdlib.h> and <string.h> that (a) are predefined by GCC and (b) have signatures that could cause codegen issues if they are treated as functions with no prototype returning and int. Future work could extend this set of functions to other C library functions that we know about. llvm-svn: 64504
-
- Feb 13, 2009
-
-
Daniel Dunbar authored
llvm-svn: 64502
-
Daniel Dunbar authored
- PR3566 llvm-svn: 64492
-
Daniel Dunbar authored
- Fix emission of static functions with constructor attribute while I was here. <rdar://problem/6140899> [codegen] "static" and attribute-constructor interact poorly llvm-svn: 64488
-
Anders Carlsson authored
llvm-svn: 64445
-
Douglas Gregor authored
llvm-svn: 64425
-
Douglas Gregor authored
ABI to the CodeGen library. Since C++ code-generation is so incomplete, we can't exercise much of this mangling code. However, a few smoke tests show that it's doing the same thing as GCC. When C++ codegen matures, we'll extend the ABI tester to verify name-mangling as well, and complete the implementation here. At this point, the major client of name mangling is in the uses of the new "overloadable" attribute in C, which allows overloading. Any "overloadable" function in C (or in an extern "C" block in C++) will be mangled the same way that the corresponding C++ function would be mangled. llvm-svn: 64413
-
Daniel Dunbar authored
llvm-svn: 64411
-
- Feb 12, 2009
-
-
Daniel Dunbar authored
llvm-svn: 64380
-
Daniel Dunbar authored
llvm-svn: 64368
-
- Feb 11, 2009
-
-
Chris Lattner authored
finishing off rdar://6520707 llvm-svn: 64295
-
- Feb 10, 2009
-
-
Anders Carlsson authored
llvm-svn: 64252
-
Daniel Dunbar authored
llvm-svn: 64195
-
Daniel Dunbar authored
ABI. llvm-svn: 64187
-
- Feb 09, 2009
-
-
Anders Carlsson authored
llvm-svn: 64173
-
Daniel Dunbar authored
llvm-svn: 64168
-
- Feb 06, 2009
-
-
Daniel Dunbar authored
llvm-svn: 63952
-
- Feb 05, 2009
-
-
Daniel Dunbar authored
scalar/complex/aggregate cases. - Currently disabled for x86_64, triggering a misoptimization (PR3489). llvm-svn: 63864
-
- Feb 04, 2009
-
-
Daniel Dunbar authored
llvm-svn: 63777
-
Daniel Dunbar authored
llvm-svn: 63679
-
- Feb 03, 2009
-
-
Daniel Dunbar authored
types. llvm-svn: 63669
-
- Jan 30, 2009
-
-
Douglas Gregor authored
error, since both C99 and C++ consider it an error. For reference, GCC makes this a warning while G++ makes it an error. llvm-svn: 63435
-
Anders Carlsson authored
llvm-svn: 63394
-
Nuno Lopes authored
llvm-svn: 63390
-
- Jan 29, 2009
-
-
Douglas Gregor authored
represents an implicit value-initialization of a subobject of a particular type. This replaces the (ab)use of CXXZeroValueInitExpr within initializer lists for the "holes" that occur due to the use of C99 designated initializers. The new test case is currently XFAIL'd, because CodeGen's ConstExprEmitter (in lib/CodeGen/CGExprConstant.cpp) needs to be taught to value-initialize when it sees ImplicitValueInitExprs. llvm-svn: 63317
-
Daniel Dunbar authored
llvm-svn: 63280
-
- Jan 28, 2009
-
-
Daniel Dunbar authored
- Merged into single ComplexEvaluator, these share too much logic to be worth splitting for float/int (IMHO). Will split on request. llvm-svn: 63248
-
Nuno Lopes authored
llvm-svn: 63158
-
- Jan 27, 2009
-
-
Anders Carlsson authored
If an input constraint refers to an output constraint, it should have the same constraint info as the output constraint. Fixes PR3417 llvm-svn: 63127
-
Chris Lattner authored
llvm-svn: 63117
-
Daniel Dunbar authored
builtins-x86.c. llvm-svn: 63069
-
- Jan 25, 2009
-
-
Eli Friedman authored
__builtin___CFStringMakeConstantString. (We get into trouble in GenerateStaticBlockVarDecl if the constant folder isn't accurate.) llvm-svn: 62949
-
Eli Friedman authored
constant. llvm-svn: 62948
-
- Jan 24, 2009
-
-
Eli Friedman authored
Note that there are still other issues in this area; see PR3396. llvm-svn: 62942
-
- Jan 23, 2009
-
-
Daniel Dunbar authored
- <rdar://problem/6518844> Clang-generated bitcode crashes LLVM while compiling function pointer addition expression llvm-svn: 62857
-
- Jan 22, 2009
-
-
Daniel Dunbar authored
- Although gross, this is needed currently to ensure that we produce well formed debug information (to match pace with the assertions being added to DebugInfo in LLVM). llvm-svn: 62734
-