summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Object/SymbolicFile.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Use std::unique_ptr to make the ownership explicit.Rafael Espindola2014-07-311-1/+1
| | | | llvm-svn: 214377
* Pass a unique_ptr<MemoryBuffer> to the constructors in the Binary hierarchy.Rafael Espindola2014-06-241-3/+4
| | | | | | | Once the objects are constructed, they own the buffer. Passing a unique_ptr makes that clear. llvm-svn: 211595
* Pass a std::unique_ptr& to the create??? methods is lib/Object.Rafael Espindola2014-06-231-2/+3
| | | | | | | | This makes the buffer ownership on error conditions very natural. The buffer is only moved out of the argument if an object is constructed that now owns the buffer. llvm-svn: 211546
* Make ObjectFile and BitcodeReader always own the MemoryBuffer.Rafael Espindola2014-06-231-9/+5
| | | | | | | | | | This allows us to just use a std::unique_ptr to store the pointer to the buffer. The flip side is that they have to support releasing the buffer back to the caller. Overall this looks like a more efficient and less brittle api. llvm-svn: 211542
* Add a SymbolicFile interface between Binary and ObjectFile.Rafael Espindola2014-02-211-0/+67
This interface allows IRObjectFile to be implemented without having dummy methods for all section and segment related methods. Both llvm-ar and llvm-nm are changed to use it. Unfortunately the mangler is still not plugged in since it requires some refactoring to make a Module hold a DataLayout. llvm-svn: 201881
OpenPOWER on IntegriCloud