summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CodeGenModule.h
Commit message (Collapse)AuthorAgeFilesLines
...
* Change CodeGenModule GlobalDeclMap to directly reference globalsDaniel Dunbar2008-07-301-2/+7
| | | | | | | | | | | | | | | instead of mapping the decl to a bitcast of the global to the correct type. - GetAddrOf{Function,GlobalVar} introduce the bitcast on every use now. - This solves a problem where a dangling pointer could be introduced by the RAUW done when replacing a forward or tentative definition. See testcase for more details. - Fixes <rdar://problem/6108358> llvm-svn: 54211
* Rework codegen emission of globalsDaniel Dunbar2008-07-291-17/+34
| | | | | | | | | | | | | | | | | | | | - No (intended) functionality change. - Primary purpose is to clearly separate (lazy) construction of globals that are a forward declaration or tentative definition from those that are the final definition. - Lazy construction is now encapsulated in GetAddrOf{Function,GlobalVar} while final definitions are constructed in EmitGlobal{Function,Var}Definition. - External interface for dealing with globals is now limited to EmitGlobal and GetAddrOf{Function,GlobalVar}. - Also updated helper functions dealing with statics, annotations, and ctors to be private. llvm-svn: 54179
* Fix codegen of chained declarationsDaniel Dunbar2008-07-291-1/+0
| | | | | | | | - Killed useless CodeGenModule::EmitGlobalVarDeclarator, instead just recurse on any ScopedDecl. - Fix for <rdar://problem/6093838> llvm-svn: 54162
* implement the alias attirbute (in both Sema and Codegen)Nuno Lopes2008-06-081-0/+3
| | | | llvm-svn: 52092
* First cut at setting attributes for functions and calls; this puts us Eli Friedman2008-06-011-0/+5
| | | | | | | | | | | | | | | much closer to passing the gcc struct layout tests. It might be possible to refactor this a bit, but I'm not sure there's actually enough common code for that to be useful. To get the calling convention completely correct, a bit of platform-specific code is necessary even for x86-Linux. On x86-Linux, the alignment of function parameters is extremely strange; as far as I can tell, it's always 4 except for SSE vectors or structs containing SSE vectors. I'm continuing to investigate this. llvm-svn: 51839
* Support for code generation of Objective-C top-level language constructs.Anton Korobeynikov2008-06-011-0/+6
| | | | | | Implemented by David Chisnall! llvm-svn: 51835
* Emit memmove, not memcpy, for structure copies; this is unfortunately Eli Friedman2008-05-261-0/+2
| | | | | | | | | | | | | | | | | required for correctness in cases of copying a struct to itself or to an overlapping struct (itself for cases like *a = *a, and overlapping is possible with unions). Hopefully, this won't end up being a perf issue; LLVM *should* be able to optimize memmove to memcpy in a lot of cases, and for small copies the generated code *should* be mostly comparable. (In reality, LLVM is currently horrible at optimizing memmove, but that's a bug, not a fundamental issue.) gcc currently generates wrong code; that's http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32667. llvm-svn: 51566
* Move getAccessedFieldNo out of lib/AST/Expr.cpp intoDan Gohman2008-05-221-0/+6
| | | | | | | | | lib/CodeGen/CGExpr.cpp and to change include/clang/AST/Attr.h to use its own enum for visibility types instead of using llvm::GlobalValue::VisibilityTypes. These changes eliminate dependencies in the AST library on LLVM's VMCore library. llvm-svn: 51398
* Added -g command line options to clang for generating source level debug ↵Sanjiv Gupta2008-05-081-2/+6
| | | | | | information. This patch currently enables generation of line number debug information (stoppoints) and region begin/end debug information. The new files CGDebugInfo.h and CGDebugInfo.cpp implements the debug info manager class CGDebugInfo. llvm-svn: 50848
* Fix PR2236Nate Begeman2008-04-201-3/+2
| | | | | | | Add test Implement feedback from Chris re: PR1998 llvm-svn: 50001
* Only generate code for static functions and global variables that are ↵Nate Begeman2008-04-201-0/+4
| | | | | | | | | actually used. Warn about unused static functions and variables. This fixes PR1998. llvm-svn: 49987
* Generate code for annotation attributes.Nate Begeman2008-04-191-1/+4
| | | | llvm-svn: 49951
* Add support to module codegen for adding and emitting annotationsNate Begeman2008-04-181-0/+3
| | | | llvm-svn: 49944
* Remove FileVarDecl and BlockVarDecl. They are replaced by ↵Steve Naroff2008-04-151-3/+2
| | | | | | | | VarDecl::isBlockVarDecl() and VarDecl::isFileVarDecl(). This is a fairly mechanical/large change. As a result, I avoided making any changes/simplifications that weren't directly related. I did break two Analysis tests. I also have a couple FIXME's in UninitializedValues.cpp. Ted, can you take a look? If the bug isn't obvious, I am happy to dig in and fix it (since I broke it). llvm-svn: 49748
* Add initial support for objc codegen for methods, ivars, and theChris Lattner2008-03-301-0/+2
| | | | | | etoile runtime, patch by David Chisnall! llvm-svn: 48969
* Make a major restructuring of the clang tree: introduce a top-levelChris Lattner2008-03-151-0/+129
lib dir and move all the libraries into it. This follows the main llvm tree, and allows the libraries to be built in parallel. The top level now enforces that all the libs are built before Driver, but we don't care what order the libs are built in. This speeds up parallel builds, particularly incremental ones. llvm-svn: 48402
OpenPOWER on IntegriCloud