summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Object/Error.cpp
diff options
context:
space:
mode:
authorPeter Collingbourne <peter@pcc.me.uk>2014-09-18 21:28:49 +0000
committerPeter Collingbourne <peter@pcc.me.uk>2014-09-18 21:28:49 +0000
commit10039c02ea1d34d39fb3b66f522c53bb50751da5 (patch)
treed0fcaa82f000b5ef6f140be711ae02155192c4fd /llvm/lib/Object/Error.cpp
parent6bf091c656f319e36721364fe50c456efca36df6 (diff)
downloadbcm5719-llvm-10039c02ea1d34d39fb3b66f522c53bb50751da5.tar.gz
bcm5719-llvm-10039c02ea1d34d39fb3b66f522c53bb50751da5.zip
LTO: introduce object file-based on-disk module format.
This format is simply a regular object file with the bitcode stored in a section named ".llvmbc", plus any number of other (non-allocated) sections. One immediate use case for this is to accommodate compilation processes which expect the object file to contain metadata in non-allocated sections, such as the ".go_export" section used by some Go compilers [1], although I imagine that in the future we could consider compiling parts of the module (such as large non-inlinable functions) directly into the object file to improve LTO efficiency. [1] http://golang.org/doc/install/gccgo#Imports Differential Revision: http://reviews.llvm.org/D4371 llvm-svn: 218078
Diffstat (limited to 'llvm/lib/Object/Error.cpp')
-rw-r--r--llvm/lib/Object/Error.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/lib/Object/Error.cpp b/llvm/lib/Object/Error.cpp
index e7431d78074..44667c247b1 100644
--- a/llvm/lib/Object/Error.cpp
+++ b/llvm/lib/Object/Error.cpp
@@ -41,6 +41,8 @@ std::string _object_error_category::message(int EV) const {
return "Invalid data was encountered while parsing the file";
case object_error::unexpected_eof:
return "The end of the file was unexpectedly encountered";
+ case object_error::bitcode_section_not_found:
+ return "Bitcode section not found in object file";
}
llvm_unreachable("An enumerator of object_error does not have a message "
"defined.");
OpenPOWER on IntegriCloud