summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen
Commit message (Collapse)AuthorAgeFilesLines
...
* Block ivar layout must assume that the 'isa'Fariborz Jahanian2010-09-091-0/+3
| | | | | | | | field of the block descriptor is GC'able (scanned) as this what the runtime expects (one can send it messages). Radar 8394947. llvm-svn: 113454
* Fix warnings caused by new CXXUuidofExprClass enumerator.Francois Pichet2010-09-081-1/+2
| | | | llvm-svn: 113444
* Implement ARM static local initialization guards, which are more compact thanJohn McCall2010-09-089-157/+195
| | | | | | Itanium guards and use a slightly different compiled-in API. llvm-svn: 113330
* Local static block variable referecned in itsFariborz Jahanian2010-09-072-5/+5
| | | | | | | | block-literal initializer expression causes IRgen to crash. This patch fixes by saving it in StaticLocalDecl map already used for such purposes. (radar 8390455). llvm-svn: 113307
* get rid of a warning.Fariborz Jahanian2010-09-071-3/+3
| | | | llvm-svn: 113256
* Have Sema check for validity of CGString literalFariborz Jahanian2010-09-071-9/+0
| | | | | | instead of asserting in IRGen. Fixes radar 8390459. llvm-svn: 113253
* LastFieldBitfield in CGObjCCommonMac::BuildAggrIvarLayout keeps bitfields or ↵Argyrios Kyrtzidis2010-09-061-15/+24
| | | | | | | | unnamed fields but later the code assumes that it's always a bitfield. This can lead to a crash (reported at rdar://8368320). llvm-svn: 113154
* move the hackaround for PR6537 to catch unions as well,Chris Lattner2010-09-061-12/+12
| | | | | | fixing the ICE in PR7151 llvm-svn: 113130
* clean up some formatting.Chris Lattner2010-09-062-16/+15
| | | | llvm-svn: 113129
* No functional change. Replace Out << 'a' << 'b' with Out << "ab" and spellNick Lewycky2010-09-051-3/+3
| | | | | | David Vandevoorde's name correctly. llvm-svn: 113103
* Casting of a property reference to 'void' did notFariborz Jahanian2010-09-041-2/+7
| | | | | | | generate the necessary code. This patch fixes it. // rdar://8389655 llvm-svn: 113079
* Petty optimization.John McCall2010-09-041-1/+1
| | | | llvm-svn: 113049
* Truncate block variable of bool type to i1 when itsFariborz Jahanian2010-09-033-20/+2
| | | | | | | value is used. This matches with non-block variable use of bool type. (Fixes radar 8390062). llvm-svn: 113027
* Cope with llvm's reference to bool type of 'i1' vs. clang'sFariborz Jahanian2010-09-031-0/+17
| | | | | | | type of 'i8' for the same for __block variables of type bool. refixes radar 8382559. llvm-svn: 113015
* A constant initializer never matches the type of the variable it'sJohn McCall2010-09-031-1/+1
| | | | | | | initializing; it at best matches the element type of the variable it's initializing. Fixes PR8073. llvm-svn: 112992
* IRgen: Fix silly thinko in r112021, which was generating code for the same exprDaniel Dunbar2010-09-031-1/+1
| | | | | | | twice. This showed up as an assert on the odd test case because we generated the decl map entry twice. llvm-svn: 112943
* Add symantic support for the Pascal calling convention viaDawn Perchik2010-09-032-0/+5
| | | | | | | "__attribute((pascal))" or "__pascal" (and "_pascal" under -fborland-extensions). Support still needs to be added to llvm. llvm-svn: 112939
* Translate NEON vabdl, vaba, and vabal builtins to be implemented using theBob Wilson2010-09-031-9/+26
| | | | | | vabd intrinsic combined with zext and add operations. llvm-svn: 112937
* Re-commit r112916 with an additional fix for the self-host failures.John McCall2010-09-032-18/+29
| | | | | | I've audited the remaining getFunctionInfo call sites. llvm-svn: 112936
* Revert r112916, it's breaking selfhost pretty badly.John McCall2010-09-032-27/+17
| | | | llvm-svn: 112925
* Revert "Another i1 vs. i8 type mismatch issue. This time", it breaks some ↵Daniel Dunbar2010-09-031-1/+1
| | | | | | projects. llvm-svn: 112922
* It's not safe to use the generic CXXMethodDecl overload of CGT::getFunctionInfoJohn McCall2010-09-032-17/+27
| | | | | | | to set up a destructor call, because ABIs can tweak these conventions. Fixes rdar://problem/8386802. llvm-svn: 112916
* IRgen/Obj-C: Rewrite Objective-C bit-field access to compute the access strategyDaniel Dunbar2010-09-021-21/+24
| | | | | | | | using the same methods as used for normal structures. - This fixes problems with reading past the end of the structure and with handling straddled bit-field access. llvm-svn: 112914
* IRgen: Move CGBitFieldInfo strategy computation helpers to static memberDaniel Dunbar2010-09-022-11/+38
| | | | | | functions. llvm-svn: 112913
* Fix a few more ConvertTypes that should be ConvertTypeForMems, fixingDouglas Gregor2010-09-021-2/+3
| | | | | | two regressions in Boost.Config. llvm-svn: 112908
* Add a bunch of missing bitcasts for clang NEON builtin expansions.Bob Wilson2010-09-021-12/+57
| | | | | | Radar 8388233 llvm-svn: 112890
* Eliminate CXXBindReferenceExpr, which was used in a ton ofDouglas Gregor2010-09-021-4/+0
| | | | | | well-intentioned but completely unused code. llvm-svn: 112868
* Tidy up last commit, as per Devang's comments.David Chisnall2010-09-022-12/+22
| | | | llvm-svn: 112840
* Revert my two IRgen fixes for "bool", then use a far simpler approachDouglas Gregor2010-09-022-10/+4
| | | | | | | based on ConvertTypeForMem. Thanks to John for pointing out the right solution. llvm-svn: 112838
* Another i1 vs. i8 type mismatch issue. This timeFariborz Jahanian2010-09-021-1/+1
| | | | | | a 'bool' byref variable in memory. Fixes radar 8382559. llvm-svn: 112835
* Use the unmangled name for the display name in Objective-C debug info. This ↵David Chisnall2010-09-021-0/+14
| | | | | | should have no effect with the Mac runtime where clang (unlike GCC) uses the display name symbol name. llvm-svn: 112833
* Fix more i1/i8 pointer madness. Here, an overactive assertionDouglas Gregor2010-09-021-2/+3
| | | | | | | | | | | | complains when the element type of a C++ "delete" expression is different from what we would expect from the pointer type. When deleting a bool*, we end up with an i1 on one side (where we compute the LLVM type from the Clang bool type) and i8 on the other (where we grab the LLVM type from the LLVM pointer type). I've weakened the assertion appropriately, and the Boost Parallel Graph Library now passes its regression tests. llvm-svn: 112821
* Fix a crash involving pointer-to-data-members of boolean type. We wereDouglas Gregor2010-09-021-2/+7
| | | | | | | | | | | | constructing an LLVM PointerType directly from the "bool"'s LLVM type (i1), which resulted in unfortunate pointer type i1*. The fix is to build the LLVM PointerType from the corresponding Clang PointerType, so that we get i8* in the case of a bool. John, please review. I also left a FIXME there because we seem to be dropping "volatile", which would be rather unfortunate. llvm-svn: 112819
* Simplify some random accesses to the ASTContext from the ABI classes.John McCall2010-09-021-17/+17
| | | | llvm-svn: 112816
* Abstract IR generation of array cookies into the C++ ABI class andJohn McCall2010-09-025-227/+664
| | | | | | | | | | | | | | implement ARM array cookies. Also fix a few unfortunate bugs: - throwing dtors in deletes prevented the allocation from being deleted - adding the cookie to the new[] size was not being considered for overflow (and, more seriously, was screwing up the earlier checks) - deleting an array via a pointer to array of class type was not causing any destructors to be run and was passing the unadjusted pointer to the deallocator - lots of address-space problems, in case anyone wants to support free store in a variant address space :) llvm-svn: 112814
* Translate NEON vmull, vmlal, and vmlsl builtins to llvm multiply-add/subBob Wilson2010-09-011-10/+32
| | | | | | | | with zext/sext operations, instead of to llvm intrinsics. I have a plan to avoid the clang builtins for these, but it is going to take a little longer and I want to get the NEON intrinsics updated before the 2.8 release. llvm-svn: 112764
* Fix IRGen when property-dot syntax used to accessFariborz Jahanian2010-09-012-9/+23
| | | | | | a c++ class object 'ivar'. Fixes radar 8366604. llvm-svn: 112729
* Split ObjCInterfaceDecl::ReferencedProtocols into two lists: ↵Ted Kremenek2010-09-011-6/+7
| | | | | | | | | | | | | ReferencedProtocols and AllReferencedProtocols. ReferencedProtocols (and thus protocol_begin(), protocol_end()) now only contains the list of protocols that were directly referenced in an @interface declaration. 'all_referenced_protocol_[begin,end]()' now returns the set of protocols that were referenced in both the @interface and class extensions. The latter is needed for semantic analysis/codegen, while the former is needed to maintain the lexical information of the original source. Fixes <rdar://problem/8380046>. llvm-svn: 112691
* fix rdar://8360877 a really nasty miscompilation in Boost.XpressiveChris Lattner2010-09-011-3/+47
| | | | | | | | | | | | | | | caused by my ABI work. Passing: struct outer { int x; struct epsilon_matcher {} e; int f; }; as {i32,i32} isn't safe, because the offset of the second element needs to be at 8 when it is interpreted as a memory value. llvm-svn: 112686
* same refactoring as before, this time on the argument side.Chris Lattner2010-09-011-16/+17
| | | | llvm-svn: 112684
* refactor some code to cut down on redundancy, no functionality change.Chris Lattner2010-09-011-22/+19
| | | | llvm-svn: 112683
* Amusingly, I missed this point of abstraction in all my earlierJohn McCall2010-08-314-9/+53
| | | | | | member-pointer refactoring: dereferencing a member data pointer. llvm-svn: 112640
* Add support for windows x86-64 varargs, patch by Cameron Esfahani!Chris Lattner2010-08-311-2/+63
| | | | llvm-svn: 112603
* Teach IR generation to return 'this' from constructors and destructorsJohn McCall2010-08-3118-100/+371
| | | | | | under the ARM ABI. llvm-svn: 112588
* Rename DeclContext::getLookupContext to getRedeclContext and change its ↵Sebastian Redl2010-08-311-1/+1
| | | | | | semantics slightly. No functionality change in the absence of inline namespaces. Also, change a few places where inline namespaces actually make a difference to be prepared for them. llvm-svn: 112563
* Fix PR8029, a x86-32 ABI regression in introduced in r112211Chris Lattner2010-08-301-1/+0
| | | | llvm-svn: 112537
* Translate NEON vmovn builtin to a vector truncation instead of using an llvmBob Wilson2010-08-301-2/+1
| | | | | | intrinsic. llvm-svn: 112504
* Revert my user-defined literal commits - r1124{58,60,67} pendingAlexis Hunt2010-08-302-4/+0
| | | | | | some issues being sorted out. llvm-svn: 112493
* Two minor fixes to user-defined literals:Alexis Hunt2010-08-301-0/+3
| | | | | | | - Zero-initialize UDLData so that crashes stop - Stop complaining that we can't emit them (we most certainly can) llvm-svn: 112467
* Implement C++0x user-defined string literals.Alexis Hunt2010-08-291-0/+1
| | | | | | | | | | The extra data stored on user-defined literal Tokens is stored in extra allocated memory, which is managed by the PreprocessorLexer because there isn't a better place to put it that makes sure it gets deallocated, but only after it's used up. My testing has shown no significant slowdown as a result, but independent testing would be appreciated. llvm-svn: 112458
OpenPOWER on IntegriCloud