summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGenObjC
Commit message (Collapse)AuthorAgeFilesLines
...
* Run this test through instnamer to stop it failing on non-asserts clang builds.Richard Smith2014-04-291-1/+1
| | | | llvm-svn: 207488
* Debug info: Improve line table for functions with cleanups an early exitAdrian Prantl2014-04-291-0/+25
| | | | | | | | | | | | | and no return expr at the end of the function. The "function has only simple returns" check in FinishFunction tests whether the number of simple return exprs equals the number of return exprs, but so far a fallthrough at the end of a function was not counted as a return, which would result in cleanup code being associated with the wrong source line. rdar://problem/16733984. llvm-svn: 207480
* Objective-C [IRGen]. Fixes a crash in IRGen involving use ofFariborz Jahanian2014-04-231-0/+11
| | | | | | | 'typeof' to extract type of an @encode expression used in an initializer. // rdar://16655340 llvm-svn: 207004
* Objective-C [IRGen]. Add encoding for 'weak' attribute of aFariborz Jahanian2014-04-021-0/+9
| | | | | | 'readonly' property. // rdar://16136439 llvm-svn: 205477
* ARM64: initial clang support commit.Tim Northover2014-03-294-7/+69
| | | | | | | | | | | This adds Clang support for the ARM64 backend. There are definitely still some rough edges, so please bring up any issues you see with this patch. As with the LLVM commit though, we think it'll be more useful for merging with AArch64 from within the tree. llvm-svn: 205100
* Don't produce a L symbol in __DATA,__data.Rafael Espindola2014-03-271-0/+2
| | | | | | The section __DATA,__data is atomized by the linker and cannot have L symbols. llvm-svn: 204879
* test: Give instrumentation based profiling tests their own directoryJustin Bogner2014-03-112-85/+0
| | | | | | | | These tests are logically related, but they're spread about several different CodeGen directories. Consolidate them in one place to make them easier to manage. llvm-svn: 203541
* Objective-C IRGen. Fixes several regressions caused by changes madeFariborz Jahanian2014-03-111-0/+33
| | | | | | to setting of ObjC linkages. //rdar://16206443 llvm-svn: 203521
* Use llvm.compiler.used instead of llvm.used for objc symbols.Rafael Espindola2014-03-061-1/+1
| | | | | | | | | | | | | LLVM currently has a hack (shouldEmitUsedDirectiveFor) that causes it to not print no_dead_strip for symbols starting with 'l' or 'L'. These are exactly the ones that the clang's objc codegen is producing. The net result, is that it is equivalent to llvm.compiler.used. The need for putting the private symbol in llvm.compiler.used should be clear (the objc runtime uses them). The reason for also putting the weak symbols in it is for LTO: ld64 will not ask us to preserve the it. llvm-svn: 203172
* Make the test a bit stronger by showing what is added to llvm.used.Rafael Espindola2014-03-061-0/+2
| | | | llvm-svn: 203170
* PGO: Add support for Objective-C blocks.Bob Wilson2014-03-062-5/+23
| | | | llvm-svn: 203157
* Revert "Use private linkage for remaining GlobalVariables with private names."Rafael Espindola2014-03-063-7/+7
| | | | | | | | This reverts commit r203059. Revert while we discuss what does it mean to be private and weak. llvm-svn: 203141
* Run -fprofile-instr tests with %clang_cc1.Bob Wilson2014-03-061-2/+2
| | | | | | | This should help avoid problems like the buildbot fallout from my change in r203085. I left the CodeGenCXX tests alone for now. llvm-svn: 203131
* CodeGenObjC/instr-profile.m: Add -target darwin to appease bots.NAKAMURA Takumi2014-03-061-2/+2
| | | | | | | | | | | | This expected; ; Function Attrs: uwtable define internal void @"\01+[A foreach:]"(i8* %self, i8* %_cmd, %0* %array) #0 { But the Name is mangled on other hosts; (x86_64-unknown-unknown) ; Function Attrs: nounwind uwtable define internal void @_c_A__foreach_(i8* %self, i8* %_cmd, %1* %array) #0 { llvm-svn: 203092
* Attempt to fix buildbots by dropping the -LABEL from some FileCheck patterns.Bob Wilson2014-03-061-2/+2
| | | | llvm-svn: 203090
* PGO: add instrumentation for Objective-C methods.Bob Wilson2014-03-062-6/+28
| | | | llvm-svn: 203085
* Use private linkage for remaining GlobalVariables with private names.Rafael Espindola2014-03-063-7/+7
| | | | | | | | | | | | | | | | | | | | | | This patch changes the remaining GlobalVariables using "\01L" and "\01l" prefixes to use private linkage. What is strange about them is that they currently use WeakAnyLinkage. There is no comment stating why and that is really odd since the symbols are completely hidden, so it doesn't make sense for them to be weak. Clang revisions like r63329, r63408, r63770, r65761 set the linkage to weak, but don't say why. I suspect they were just copying llvm-gcc. In llvm-gcc I found r58599 and r56322 that set DECL_WEAK, but they were just syncing from the apple gcc. I am not exactly sure what that means, since the last commit to svn://gcc.gnu.org/svn/gcc/branches/apple was in 2006, 2 years earlier. In summary, I have no idea why weak linkage was being used :-( To quote John McCall, "Let’s try without it and see" :-) llvm-svn: 203059
* Objective-C IRGen. Fix up the hueristics for determiningFariborz Jahanian2014-03-041-0/+64
| | | | | | | | if an ivar offset load is invariant iff inside an instance method and ivar belongs to instance method's class and one of its super class. // rdar://16095748 llvm-svn: 202872
* Objective-C. Fixes a regression when figuring out linkageFariborz Jahanian2014-03-031-0/+24
| | | | | | | for metadata symbols for forward referenced protocols which are never defined. // rdar://16203115 llvm-svn: 202761
* Use private linkage for globals we already name with \01L and \01l.Rafael Espindola2014-02-2717-132/+132
| | | | | | | | | | | | In llvm the only semantic difference between internal and private is that llvm tries to hide private globals my mangling them with a private prefix. Since the globals changed by this patch already had the magic don't mangle marker, there should be no change in the generated assembly. A followup patch should then be able to drop the \01L and \01l prefixes and let llvm mangle as appropriate. llvm-svn: 202419
* Objective-C. Remove an assertion which assertsFariborz Jahanian2014-02-241-0/+8
| | | | | | | on correctly handled block layout IRGen. // rdar://16111839 llvm-svn: 202063
* Do not put instrumentation counters before phis in ObjC for-in loops.Bob Wilson2014-02-242-0/+45
| | | | | | | We still don't use the PGO to set branch weights for these loops, but at least this keeps the compiler from crashing. <rdar://problem/16137778> llvm-svn: 202002
* Fix broken CHECK linesNico Rieck2014-02-162-2/+2
| | | | llvm-svn: 201477
* Fix broken RUN linesNico Rieck2014-02-161-1/+1
| | | | llvm-svn: 201475
* [IRGen]. Fixes a crash in using Objective-C array Fariborz Jahanian2014-02-141-0/+30
| | | | | | | | | properties by fixing shouldBindAsLValue to accept arrays (like record types) because we always manipulate them in memory. Patch suggested by John MaCall. // rdar://15610943 llvm-svn: 201428
* relax testcase and make ppc64 buildbots happy.Adrian Prantl2014-02-121-4/+4
| | | | llvm-svn: 201250
* Document and improve the debug-property-synth.m test based on theAdrian Prantl2014-02-121-6/+22
| | | | | | information provided in the referenced radar. llvm-svn: 201248
* Revert "Remove bad debug info test."Adrian Prantl2014-02-121-0/+20
| | | | | | | | This reverts commit r201183. The test, albeit undocumented and badly written is still testing something useful. It will be updated in a subsequent commit. llvm-svn: 201247
* Remove bad debug info test.David Blaikie2014-02-111-20/+0
| | | | | | | | | | Another test that's testing through assembly from Clang which is problematic. An attempt to upgrade this to just be an IR-generation test was unsuccessful (I was unable to get this test to fail) but it looks like there's other, better, test coverage in this area (test/CodeGenObjC/debuginfo-properties.m) anyway. llvm-svn: 201183
* Use an Itanium triple in DWARF debug info testsTimur Iskhodzhanov2014-01-308-8/+15
| | | | | | This should fix the clang part of the breakage in r200340. llvm-svn: 200435
* Objective-C [IRGen]. Generator a tail call to objc_getProperty() in Fariborz Jahanian2014-01-303-4/+4
| | | | | | | synthesized getters for performance improvement. // rdar://15884113 llvm-svn: 200430
* Objective-C. provide legacy encoding of *id and *Class typesFariborz Jahanian2014-01-281-0/+8
| | | | | | instead of crashing. // rdar://15824769. llvm-svn: 200338
* Use private linkage for utf-16 objc strings too.Rafael Espindola2014-01-212-2/+2
| | | | llvm-svn: 199709
* Give explicit sections for string constants used in NSStrings.Rafael Espindola2014-01-203-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Without them they can be merged with non unnamed_addr constants during LTO. The resulting constant is not unnamed_addr and goes in a different section, which causes ld64 to crash. A testcase that would crash before: * file1.mm: void g(id notification) { [notification valueForKey:@"name"]; } * file2.cpp: extern const char js_name_str[] = "name"; * file3.cpp extern bool JS_GetProperty(const char *name); extern const char js_name_str[]; bool js_ReportUncaughtException() { JS_GetProperty(js_name_str); } run clang file1.mm -o file1.o -c -w -emit-llvm clang file2.cpp -o file2.o -c -w -emit-llvm clang file3.cpp -o file3.o -c -w ld -dylib -o XUL file1.o file2.o file3.o -undefined dynamic_lookup. llvm-svn: 199688
* Add a triple. Should fix the 64 bit bots.Rafael Espindola2014-01-201-1/+1
| | | | llvm-svn: 199670
* Make the test more strict.Rafael Espindola2014-01-201-1/+3
| | | | llvm-svn: 199669
* Remove the -cxx-abi command-line flag.Hans Wennborg2014-01-142-2/+2
| | | | | | | | | | | | | | | This makes the C++ ABI depend entirely on the target: MS ABI for -win32 triples, Itanium otherwise. It's no longer possible to do weird combinations. To be able to run a test with a specific ABI without constraining it to a specific triple, new substitutions are added to lit: %itanium_abi_triple and %ms_abi_triple can be used to get the current target triple adjusted to the desired ABI. For example, if the test suite is running with the i686-pc-win32 target, %itanium_abi_triple will expand to i686-pc-mingw32. Differential Revision: http://llvm-reviews.chandlerc.com/D2545 llvm-svn: 199250
* Update tests in preparation for using the MS ABI for Win32 targetsHans Wennborg2014-01-132-4/+6
| | | | | | | | | | In preparation for making the Win32 triple imply MS ABI mode, make all tests pass in this mode, or make them use the Itanium mode explicitly. Differential Revision: http://llvm-reviews.chandlerc.com/D2401 llvm-svn: 199130
* Re-applying r198699 after reverting r198461.Adrian Prantl2014-01-072-6/+7
| | | | | | | | Debug info: Implement a cleaner version of r198461. For symmetry with C and C++ don't emit an extra lexical scope for the compound statement that is the body of an Objective-C method. llvm-svn: 198715
* Revert "Debug info: Ensure that the last stop point in a function is still ↵Adrian Prantl2014-01-071-4/+1
| | | | | | | | within" This reverts commit r198461. llvm-svn: 198714
* Revert "Debug info: Implement a cleaner version of r198461. For symmetry with"Adrian Prantl2014-01-072-5/+7
| | | | | | This reverts commit 198699 so we can get a cleaner patch. llvm-svn: 198713
* Debug info: Implement a cleaner version of r198461. For symmetry withAdrian Prantl2014-01-072-7/+5
| | | | | | | | | C and C++ don't emit an extra lexical scope for the compound statement that is the body of an Objective-C method. rdar://problem/15010825 llvm-svn: 198699
* Debug info: Ensure that the last stop point in a function is still withinAdrian Prantl2014-01-031-1/+4
| | | | | | | | | the lexical block formed by the compound statement that is the function body. rdar://problem/15010825 llvm-svn: 198461
* ObjectiveC. support "section" attribute on propertiesFariborz Jahanian2013-12-181-0/+13
| | | | | | and methods. rdar://15450637 llvm-svn: 197625
* Implement the MSABI and SysVABI calling conventions for Objective-C method ↵Aaron Ballman2013-12-181-2/+4
| | | | | | declarations. This appears to be an omission from r189644. llvm-svn: 197584
* Remove duplicated -cc1 in testsAlp Toker2013-12-082-3/+3
| | | | llvm-svn: 196728
* Fix a tranche of comment, test and doc typosAlp Toker2013-12-052-2/+2
| | | | llvm-svn: 196510
* clang/test: REQUIRES: s/x86-64-registered-target/x86-registered-target/NAKAMURA Takumi2013-12-0412-12/+12
| | | | llvm-svn: 196350
* Check IR on this test.Rafael Espindola2013-12-031-10/+6
| | | | llvm-svn: 196287
* Improving calling convention test coverage by adding tests for things not ↵Aaron Ballman2013-11-191-0/+11
| | | | | | currently handled. Specifically: the diagnostics in SemaDeclAttr.cpp, and ensuring that calling convention attributes are applied to ObjC method declarations. No functional changes. llvm-svn: 195098
OpenPOWER on IntegriCloud