summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Archive
Commit message (Collapse)AuthorAgeFilesLines
* Move lib/Archive to tools/llvm-ar.Rafael Espindola2013-06-177-1371/+0
| | | | | | | llvm-ar is the only tool that needs to write archive files. Every other tool should be able to use the lib/Object interface. llvm-svn: 184083
* Remove the LLVM specific archive index.Rafael Espindola2013-06-144-148/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Archive files (.a) can have a symbol table indicating which object files in them define which symbols. The purpose of this symbol table is to speed up linking by allowing the linker the read only the .o files it is actually going to use instead of having to parse every object's symbol table. LLVM's archive library currently supports a LLVM specific format for such table. It is hard to see any value in that now that llvm-ld is gone: * System linkers don't use it: GNU ar uses the same plugin as the linker to create archive files with a regular index. The OS X ar creates no symbol table for IL files, I assume the linker just parses all IL files. * It doesn't interact well with archives having both IL and native objects. * We probably don't want to be responsible for yet another archive format variant. This patch then: * Removes support for creating and reading such index from lib/Archive. * Remove llvm-ranlib, since there is nothing left for it to do. We should in the future add support for regular indexes to llvm-ar for both native and IL objects. When we do that, llvm-ranlib should be reimplemented as a symlink to llvm-ar, as it is equivalent to "ar s". llvm-svn: 184019
* Don't use PathV1.h in Signals.h.Rafael Espindola2013-06-131-2/+2
| | | | llvm-svn: 183947
* Convert another use of sys::identifyFileType.Rafael Espindola2013-06-111-8/+6
| | | | | | No functionality change. llvm-svn: 183754
* Convert another use of sys::identifyFileType.Rafael Espindola2013-06-111-8/+6
| | | | | | No functionality change. llvm-svn: 183746
* Pass a StringRef to sys::identifyFileType.Rafael Espindola2013-06-102-2/+2
| | | | llvm-svn: 183669
* Fix auto_ptr is deprecated warningsMatt Arsenault2013-02-261-11/+11
| | | | llvm-svn: 176123
* Fix typoMatt Arsenault2013-02-261-1/+1
| | | | llvm-svn: 176117
* Move all of the header files which are involved in modelling the LLVM IRChandler Carruth2013-01-023-3/+3
| | | | | | | | | | | | | | | | | | | | | 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
* Sort includes for all of the .h files under the 'lib' tree. These wereChandler Carruth2012-12-041-2/+1
| | | | | | | | | | missed in the first pass because the script didn't yet handle include guards. Note that the script is now able to handle all of these headers without manual edits. =] llvm-svn: 169224
* Use the new script to sort the includes of every file under lib.Chandler Carruth2012-12-033-4/+7
| | | | | | | | | | | | | | | | | 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
* Mark checkSignature const, and in turn stop casting away const fromRoman Divacky2012-09-052-3/+3
| | | | | | ArchiveMemberHeader. Found by gcc48 -Wcast-qual. llvm-svn: 163255
* Remove references to compression in llvm-ar. It has been a long time since weRafael Espindola2012-08-102-10/+4
| | | | | | switched from a bytecode+bzip2 to the current bitcode. llvm-svn: 161651
* Include cstdio in a few place that depended on getting it transitively ↵Benjamin Kramer2012-03-231-0/+1
| | | | | | through StringExtras.h llvm-svn: 153328
* Avoid using an invalidated iterator.Rafael Espindola2012-01-231-1/+5
| | | | llvm-svn: 148681
* The iteration order over a std::set<Module*> depends on the addresses of theRafael Espindola2012-01-231-13/+15
| | | | | | modules. Avoid that to make the order the linker sees the modules deterministic. llvm-svn: 148676
* Support/FileSystem: Add file_magic and move a vew clients over to it.Michael J. Spencer2011-12-131-3/+3
| | | | llvm-svn: 146523
* LLVMBuild: Remove trailing newline, which irked me.Daniel Dunbar2011-12-121-1/+0
| | | | llvm-svn: 146409
* build/CMake: Finish removal of add_llvm_library_dependencies.Daniel Dunbar2011-11-291-6/+0
| | | | llvm-svn: 145420
* build: Add initial cut at LLVMBuild.txt files.Daniel Dunbar2011-11-031-0/+23
| | | | llvm-svn: 143634
* Rewrite the CMake build to use explicit dependencies between libraries,Chandler Carruth2011-07-291-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | specified in the same file that the library itself is created. This is more idiomatic for CMake builds, and also allows us to correctly specify dependencies that are missed due to bugs in the GenLibDeps perl script, or change from compiler to compiler. On Linux, this returns CMake to a place where it can relably rebuild several targets of LLVM. I have tried not to change the dependencies from the ones in the current auto-generated file. The only places I've really diverged are in places where I was seeing link failures, and added a dependency. The goal of this patch is not to start changing the dependencies, merely to move them into the correct location, and an explicit form that we can control and change when necessary. This also removes a serialization point in the build because we don't have to scan all the libraries before we begin building various tools. We no longer have a step of the build that regenerates a file inside the source tree. A few other associated cleanups fall out of this. This isn't really finished yet though. After talking to dgregor he urged switching to a single CMake macro to construct libraries with both sources and dependencies in the arguments. Migrating from the two macros to that style will be a follow-up patch. Also, llvm-config is still generated with GenLibDeps.pl, which means it still has slightly buggy dependencies. The internal CMake 'llvm-config-like' macro uses the correct explicitly specified dependencies however. A future patch will switch llvm-config generation (when using CMake) to be based on these deps as well. This may well break Windows. I'm getting a machine set up now to dig into any failures there. If anyone can chime in with problems they see or ideas of how to solve them for Windows, much appreciated. llvm-svn: 136433
* Revert PathV2 changes, as sys::fs::unique_file is not finished yet.Dan Gohman2011-03-011-38/+36
| | | | llvm-svn: 126773
* Archive: Fix temp path names.Michael J. Spencer2011-01-171-4/+6
| | | | llvm-svn: 123660
* UnRevert "Revert "Archive: Replace all internal uses of PathV1 with PathV2. ↵Michael J. Spencer2011-01-161-36/+36
| | | | | | The external API still uses PathV1."" llvm-svn: 123605
* UnRevert "Revert the archive part of "Support/PathV2: Add identify_magic.""Michael J. Spencer2011-01-162-6/+7
| | | | | | This reverts commit dd103021a889a986a181ce36ed7b0e8dc9b645e1. llvm-svn: 123595
* Revert the archive part of "Support/PathV2: Add identify_magic."Michael J. Spencer2011-01-162-7/+6
| | | | llvm-svn: 123593
* Revert "Archive: Replace all internal uses of PathV1 with PathV2. The ↵Michael J. Spencer2011-01-161-36/+36
| | | | | | external API still uses PathV1." llvm-svn: 123557
* Archive: Replace all internal uses of PathV1 with PathV2. The external API ↵Michael J. Spencer2011-01-151-36/+36
| | | | | | still uses PathV1. llvm-svn: 123551
* Support/PathV2: Add identify_magic.Michael J. Spencer2011-01-152-6/+7
| | | | llvm-svn: 123548
* Fix Whitespace.Michael J. Spencer2011-01-102-17/+17
| | | | llvm-svn: 123152
* Support/Path: Deprecate PathV1::exists and replace all uses with ↵Michael J. Spencer2011-01-102-3/+7
| | | | | | PathV2::fs::exists. llvm-svn: 123151
* MemoryBuffer now return an error_code and returns a OwningPtr<MemoryBuffer> ↵Michael J. Spencer2010-12-162-14/+11
| | | | | | via an out parm. llvm-svn: 121958
* Support/MemoryBuffer: Replace all uses of std::string *ErrMsg with ↵Michael J. Spencer2010-12-092-8/+25
| | | | | | error_code &ec. And fix clients. llvm-svn: 121379
* Merge System into Support.Michael J. Spencer2010-11-293-4/+4
| | | | llvm-svn: 120298
* Revert "CMake: Get rid of LLVMLibDeps.cmake and export the libraries normally."Michael J. Spencer2010-09-131-2/+0
| | | | | | | | | | This reverts commit r113632 Conflicts: cmake/modules/AddLLVM.cmake llvm-svn: 113819
* CMake: Get rid of LLVMLibDeps.cmake and export the libraries normally.Michael J. Spencer2010-09-101-0/+2
| | | | llvm-svn: 113632
* Eliminate some unnessary Path::exists() calls.Dan Gohman2010-05-271-8/+4
| | | | llvm-svn: 104888
* silence a warning, patch by "mike".Chris Lattner2010-04-251-1/+1
| | | | llvm-svn: 102297
* Don't write into MemoryBuffers.Benjamin Kramer2010-04-194-18/+13
| | | | llvm-svn: 101783
* Fix -Wcast-qual warnings.Dan Gohman2010-04-192-4/+7
| | | | llvm-svn: 101779
* add newlines at end of files.Chris Lattner2010-04-071-1/+1
| | | | llvm-svn: 100706
* Fix a grammaro.Dan Gohman2010-03-301-1/+1
| | | | llvm-svn: 99917
* From PR6228:Chris Lattner2010-02-041-1/+2
| | | | | | | | | | | | "Attached patch removes the extra NUL bytes from the output and changes test/Archive/MacOSX.toc from a binary to a text file (removes svn:mime-type=application/octet-stream and adds svn:eol-style=native). I can't figure out how to get SVN to include the new contents of the file in the patch so I'm attaching it separately." Patch by James Abbatiello! llvm-svn: 95292
* Kill ModuleProvider and ghost linkage by inverting the relationship betweenJeffrey Yasskin2010-01-274-59/+44
| | | | | | | | | | | | | | | | | | | | | Modules and ModuleProviders. Because the "ModuleProvider" simply materializes GlobalValues now, and doesn't provide modules, it's renamed to "GVMaterializer". Code that used to need a ModuleProvider to materialize Functions can now materialize the Functions directly. Functions no longer use a magic linkage to record that they're materializable; they simply ask the GVMaterializer. Because the C ABI must never change, we can't remove LLVMModuleProviderRef or the functions that refer to it. Instead, because Module now exposes the same functionality ModuleProvider used to, we store a Module* in any LLVMModuleProviderRef and translate in the wrapper methods. The bindings to other languages still use the ModuleProvider concept. It would probably be worth some time to update them to follow the C++ more closely, but I don't intend to do it. Fixes http://llvm.org/PR5737 and http://llvm.org/PR5735. llvm-svn: 94686
* make -fno-rtti the default unless a directory builds with REQUIRES_RTTI.Chris Lattner2010-01-241-1/+0
| | | | llvm-svn: 94378
* Stop building RTTI information for *most* llvm libraries. NotableChris Lattner2010-01-221-0/+1
| | | | | | | | | | | missing ones are libsupport, libsystem and libvmcore. libvmcore is currently blocked on bugpoint, which uses EH. Once it stops using EH, we can switch it off. This #if 0's out 3 unit tests, because gtest requires RTTI information. Suggestions welcome on how to fix this. llvm-svn: 94164
* Prune #includes from llvm/Linker.h and llvm/System/Path.h,Chris Lattner2009-08-233-26/+25
| | | | | | | | | | | | | | | | | | forcing them down into various .cpp files. This change also: 1. Renames TimeValue::toString() and Path::toString() to ::str() for similarity with the STL. 2. Removes all stream insertion support for sys::Path, forcing clients to call .str(). 3. Removes a use of Config/alloca.h from bugpoint, using smallvector instead. 4. Weans llvm-db off <iostream> sys::Path really needs to be gutted, but I don't have the desire to do it at this point. llvm-svn: 79869
* Make LLVMContext and LLVMContextImpl classes instead of structs.Benjamin Kramer2009-08-111-1/+1
| | | | llvm-svn: 78690
* Factor some of the constants+context related code out into a separate ↵Owen Anderson2009-08-041-1/+1
| | | | | | | | header, to make LLVMContextImpl.h not hideous. Also, fix some MSVC compile errors. llvm-svn: 78115
* Fix some non-sensical code.Daniel Dunbar2009-07-131-1/+4
| | | | | | - This makes it more like other similar code in Archive handling. llvm-svn: 75452
OpenPOWER on IntegriCloud