summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/IPO/ExtractGV.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC)Alexander Kornienko2015-06-231-1/+1
| | | | | | Apparently, the style needs to be agreed upon first. llvm-svn: 240390
* Fixed/added namespace ending comments using clang-tidy. NFCAlexander Kornienko2015-06-191-1/+1
| | | | | | | | | | | | | The patch is generated using this command: tools/clang/tools/extra/clang-tidy/tool/run-clang-tidy.py -fix \ -checks=-*,llvm-namespace-comment -header-filter='llvm/.*|clang/.*' \ llvm/lib/ Thanks to Eugene Kosov for the original patch! llvm-svn: 240137
* Reformat partially, where I touched for whitespace changes.NAKAMURA Takumi2014-10-281-1/+1
| | | | llvm-svn: 220773
* Untabify and whitespace cleanups.NAKAMURA Takumi2014-10-281-5/+5
| | | | llvm-svn: 220771
* GlobalValue: Assert symbols with local linkage have default visibilityDuncan P. N. Exon Smith2014-05-071-3/+2
| | | | | | | | The change to ExtractGV.cpp has no functionality change except to avoid the asserts. Existing testcases already cover this, so I didn't add a new one. llvm-svn: 208264
* [C++] Use 'nullptr'. Transforms edition.Craig Topper2014-04-251-2/+2
| | | | llvm-svn: 207196
* [C++11] Add 'override' keyword to virtual methods that override their base ↵Craig Topper2014-03-051-1/+1
| | | | | | class. llvm-svn: 202953
* Add a fixed version of r195470 back.Rafael Espindola2013-11-221-17/+37
| | | | | | | | | | | | | | | | The fix is simply to use CurI instead of I when handling aliases to avoid accessing a invalid iterator. original message: Convert linkonce* to weak* instead of strong. Also refactor the logic into a helper function. This is an important improve on mingw where the linker complains about mixed weak and strong symbols. Converting to weak ensures that the symbol is not dropped, but keeps in a comdat, making the linker happy. llvm-svn: 195477
* Revert "Convert linkonce* to weak* instead of strong."Rafael Espindola2013-11-221-37/+17
| | | | | | | This reverts commit r195470. Debugging failure in some bots. llvm-svn: 195472
* Convert linkonce* to weak* instead of strong.Rafael Espindola2013-11-221-17/+37
| | | | | | | | | Also refactor the logic into a helper function. This is an important improvement on mingw where the linker complains about mixed weak and strong symbols. Converting to weak ensures that the symbol is not dropped, but keeps in a comdat, making the linker happy. llvm-svn: 195470
* Check isDiscardableIfUnused, rather than hasLocalLinkage, when bumpingLang Hames2013-03-041-3/+3
| | | | | | | GlobalValue linkage up to ExternalLinkage in the ExtractGV pass. This prevents linkonce and linkonce_odr symbols from being DCE'd. llvm-svn: 176459
* Move all of the header files which are involved in modelling the LLVM IRChandler Carruth2013-01-021-4/+4
| | | | | | | | | | | | | | | | | | | | | into their new header subdirectory: include/llvm/IR. This matches the directory structure of lib, and begins to correct a long standing point of file layout clutter in LLVM. There are still more header files to move here, but I wanted to handle them in separate commits to make tracking what files make sense at each layer easier. The only really questionable files here are the target intrinsic tablegen files. But that's a battle I'd rather not fight today. I've updated both CMake and Makefile build systems (I think, and my tests think, but I may have missed something). I've also re-sorted the includes throughout the project. I'll be committing updates to Clang, DragonEgg, and Polly momentarily. llvm-svn: 171366
* Use the new script to sort the includes of every file under lib.Chandler Carruth2012-12-031-3/+3
| | | | | | | | | | | | | | | | | Sooooo many of these had incorrect or strange main module includes. I have manually inspected all of these, and fixed the main module include to be the nearest plausible thing I could find. If you own or care about any of these source files, I encourage you to take some time and check that these edits were sensible. I can't have broken anything (I strictly added headers, and reordered them, never removed), but they may not be the headers you'd really like to identify as containing the API being implemented. Many forward declarations and missing includes were added to a header files to allow them to parse cleanly when included first. The main module rule does in fact have its merits. =] llvm-svn: 169131
* llvm-extract changes linkages so that functions on both sides of theRafael Espindola2012-10-291-12/+25
| | | | | | | split module can see each other. If it is keeping a symbol that already has a non local linkage, it doesn't need to change it. llvm-svn: 166908
* llvm-extract was unable to handle aliases. It would leave a copy on theRafael Espindola2012-10-291-0/+30
| | | | | | | | | | | | | | | | | | output of both llvm-extract foo.ll -func=bar and llvm-extract foo.ll -func=bar -delete so the two new files could not be linked together anymore. With this change alias are handled almost like functions and global variables. Almost because with alias we cannot just clear the initializer/body, we have to create a new declaration and replace the alias with it. The net result is that now the output of the above commands can be linked even if foo.ll has aliases. llvm-svn: 166907
* Remove tabs.Bill Wendling2012-07-191-10/+10
| | | | llvm-svn: 160477
* Improve the handling of available_externally and llvm.global_ctors.Rafael Espindola2011-06-091-4/+16
| | | | llvm-svn: 132775
* Fix llvm-extract so that it changes the linkage of all GlobalValues toBob Wilson2010-09-231-16/+14
| | | | | | | "external" even when doing lazy bitcode loading. This was broken because a function that is not materialized fails the !isDeclaration() test. llvm-svn: 114666
* Fix warning reported by MSVC++ builder.Nick Lewycky2010-09-051-2/+2
| | | | llvm-svn: 113106
* Rewrite ExtractGV, removing a bunch of stuff that didn't fully work,Dan Gohman2010-08-261-125/+32
| | | | | | and was over-complicated, and replacing it with a simple implementation. llvm-svn: 112120
* Reapply r110396, with fixes to appease the Linux buildbot gods.Owen Anderson2010-08-061-1/+1
| | | | llvm-svn: 110460
* Revert r110396 to fix buildbots.Owen Anderson2010-08-061-1/+1
| | | | llvm-svn: 110410
* Don't use PassInfo* as a type identifier for passes. Instead, use the ↵Owen Anderson2010-08-051-1/+1
| | | | | | | | address of the static ID member as the sole unique type identifier. Clean up APIs related to this change. llvm-svn: 110396
* Remove includes of Support/Compiler.h that are no longer needed after theNick Lewycky2009-10-251-1/+0
| | | | | | VISIBILITY_HIDDEN removal. llvm-svn: 85043
* Remove VISIBILITY_HIDDEN from class/struct found inside anonymous namespaces.Nick Lewycky2009-10-251-1/+1
| | | | | | | Chris claims we should never have visibility_hidden inside any .cpp file but that's still not true even after this commit. llvm-svn: 85042
* Introduce and use convenience methods for getting pointer typesDuncan Sands2009-10-061-1/+1
| | | | | | | where the element is of a basic builtin type. For example, to get an i8* use getInt8PtrTy. llvm-svn: 83379
* Push LLVMContexts through the IntegerType APIs.Owen Anderson2009-08-131-1/+2
| | | | llvm-svn: 78948
* Eliminate a few unused-variable warningsDouglas Gregor2009-07-291-2/+0
| | | | llvm-svn: 77519
* Move types back to the 2.5 API.Owen Anderson2009-07-291-2/+2
| | | | llvm-svn: 77516
* Move ConstantExpr to 2.5 API.Owen Anderson2009-07-291-1/+1
| | | | llvm-svn: 77494
* Change ConstantArray to 2.5 API.Owen Anderson2009-07-281-1/+1
| | | | llvm-svn: 77347
* Get rid of the Pass+Context magic.Owen Anderson2009-07-221-5/+6
| | | | llvm-svn: 76702
* Move the ConstantInt uniquing table into LLVMContextImpl. This exposed a ↵Owen Anderson2009-07-161-0/+2
| | | | | | | | number of issues in our current context-passing stuff, which is also fixed here llvm-svn: 76089
* Switch GlobalVariable ctors to a sane API, where *either* a context or a ↵Owen Anderson2009-07-081-2/+2
| | | | | | module is required. llvm-svn: 75025
* Push LLVMContext through GlobalVariables and IRBuilder.Owen Anderson2009-07-081-1/+1
| | | | llvm-svn: 74985
* More LLVMContext-ification.Owen Anderson2009-07-061-4/+5
| | | | llvm-svn: 74811
* Add the private linkage.Rafael Espindola2009-01-151-1/+2
| | | | llvm-svn: 62279
* Fix a bug that prevented llvm-extract -delete from working.Dan Gohman2008-10-211-1/+1
| | | | llvm-svn: 57864
* Tidy up several unbeseeming casts from pointer to intptr_t.Dan Gohman2008-09-041-1/+1
| | | | llvm-svn: 55779
* Factor code to copy global value attributes likeDuncan Sands2008-05-261-4/+1
| | | | | | | | | | | | | | | the section or the visibility from one global value to another: copyAttributesFrom. This is particularly useful for duplicating functions: previously this was done by explicitly copying each attribute in turn at each place where a new function was created out of an old one, with the result that obscure attributes were regularly forgotten (like the collector or the section). Hopefully now everything is uniform and nothing is forgotten. llvm-svn: 51567
* API changes for class Use size reduction, wave 1.Gabor Greif2008-04-061-2/+2
| | | | | | | | Specifically, introduction of XXX::Create methods for Users that have a potentially variable number of Uses. llvm-svn: 49277
* Fix some compilation errors on msvc:Ted Kremenek2008-03-091-0/+1
| | | | | | | | | - "Redefinition of I" (iterator masks previous definition) - include missing header file Patch by Argiris Kirtzidis! llvm-svn: 48115
* add a pass that can extract all kinds of global values, not just functions. ↵Andrew Lenharth2008-03-071-0/+174
Update llvm-extract to use it and optionally extract a global variable if you want it too llvm-svn: 48015
OpenPOWER on IntegriCloud