summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGen/ms-declspecs.c
Commit message (Collapse)AuthorAgeFilesLines
* Reorder the check strings in test case following r252692.Akira Hatanaka2015-11-111-1/+1
| | | | | | rdar://problem/19836465 llvm-svn: 252693
* [MS Compat] Add support for __declspec(noalias)David Majnemer2015-07-201-0/+5
| | | | | | | The attribute '__declspec(noalias)' communicates that the function only accesses memory pointed to by its pointer-typed arguments. llvm-svn: 242728
* Don't crash when a selectany symbol would get common linkageNico Weber2015-04-151-1/+3
| | | | | | | | | | | | | | | | Things can't both be in comdats and have common linkage, so never give things in comdats common linkage. Common linkage is only used in .c files, and the only thing that can trigger a comdat in c is selectany from what I can tell. Fixes PR23243. Also address an over-the-shoulder review comment from rnk by moving the hasAttr<SelectAnyAttr>() in Decl.cpp around a bit. It only makes a minor difference for selectany on global variables, so it goes well with the rest of this patch. http://reviews.llvm.org/D9042 llvm-svn: 235053
* Make __declspec(selectany) turn variable declartions into definitions.Nico Weber2015-04-151-0/+4
| | | | | | Fixes PR23242. llvm-svn: 235046
* [patch][pr19848] Produce explicit comdats in clang.Rafael Espindola2015-01-121-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | The llvm IR until recently had no support for comdats. This was a problem when targeting C++ on ELF/COFF as just using weak linkage would cause quite a bit of dead bits to remain on the executable (unless -ffunction-sections, -fdata-sections and --gc-sections were used). To fix the problem, llvm's codegen will just assume that any weak or linkonce that is not in an explicit comdat should be output in one with the same name as the global. This unfortunately breaks cases like pr19848 where a weak symbol is not xpected to be part of any comdat. Now that we have explicit comdats in the IR, we can finally get both cases right. This first patch just makes clang give explicit comdats to GlobalValues where t is allowed to. A followup patch to llvm will then stop implicitly producing comdats. llvm-svn: 225705
* Implement __declspec(selectany) under -fms-extensionsReid Kleckner2013-05-201-0/+5
| | | | | | | | | | | | | | | | selectany only applies to externally visible global variables. It has the effect of making the data weak_odr. The MSDN docs suggest that unused definitions can only be dropped at linktime, so Clang uses weak instead of linkonce. MSVC optimizes away references to constant selectany data, so it must assume that there is only one definition, hence weak_odr. Reviewers: espindola Differential Revision: http://llvm-reviews.chandlerc.com/D814 llvm-svn: 182266
* Fix testcases to not rely upon target-* attributes.Bill Wendling2013-02-261-6/+6
| | | | llvm-svn: 176135
* Revert "Add more attributes from the command line to functions."Anna Zaks2013-02-251-6/+6
| | | | | | | | This reverts commit 176009. The commit is a likely cause of several buildbot failures. llvm-svn: 176044
* Add more attributes from the command line to functions.Bill Wendling2013-02-251-6/+6
| | | | | | | This is an ongoing process. Any command line option which a back-end cares about should be added here. llvm-svn: 176009
* Update tests so that we don't test for function-only attributes on call sites.Bill Wendling2013-02-221-1/+1
| | | | llvm-svn: 175921
* Update to use references to attribute groups instead of listing the ↵Bill Wendling2013-02-221-2/+2
| | | | | | attributes on the call/invoke instructions. llvm-svn: 175878
* Modify the tests to use attribute group references instead of listing theBill Wendling2013-02-201-5/+9
| | | | | | function attributes. llvm-svn: 175606
* Add the 'target-cpu' and 'target-features' attributes to functions.Bill Wendling2013-02-151-2/+2
| | | | | | | The back-end will use these values to reconfigure code generation for different features. llvm-svn: 175308
* Update the tests.Bill Wendling2013-01-311-2/+2
| | | | | | | This update coincides with r174110. That change ordered the attributes alphabetically. llvm-svn: 174111
* Reapplying the changes from r158717 as they were rolled back to avoid merge ↵Aaron Ballman2012-06-191-0/+8
| | | | | | conflicts from a separate problematic patch. llvm-svn: 158750
* Revert r158700 and dependent patches r158716, r158717, and r158731.Jakob Stoklund Olesen2012-06-191-8/+0
| | | | | | | | The original r158700 caused crashes in the gcc test suite, g++.abi/vtable3a.C among others. It also caused failures in the libc++ test suite. llvm-svn: 158749
* Improves parsing and semantic analysis for MS __declspec attributes. This ↵Aaron Ballman2012-06-191-0/+8
| | | | | | includes support for the align (which fixes PR12631). llvm-svn: 158717
* Turned on support for __declspecs: noreturn, noinline, nothrow and naked in ↵Aaron Ballman2012-02-231-0/+16
MS compatibility mode. llvm-svn: 151295
OpenPOWER on IntegriCloud