diff options
author | Saleem Abdulrasool <compnerd@compnerd.org> | 2014-10-05 23:43:59 +0000 |
---|---|---|
committer | Saleem Abdulrasool <compnerd@compnerd.org> | 2014-10-05 23:43:59 +0000 |
commit | 62117407896c1695422ec14186fb179a8f826dc0 (patch) | |
tree | be8bc60d7fcf71da14f1a0732276f27cc09850cf /lld/lib/Core/Error.cpp | |
parent | 8373d338f6f0f5462cf10704e904b0c359dddd3e (diff) | |
download | bcm5719-llvm-62117407896c1695422ec14186fb179a8f826dc0.tar.gz bcm5719-llvm-62117407896c1695422ec14186fb179a8f826dc0.zip |
PE/COFF: add a check to ensure that we dont mix up architectures
Previously, we would not check the target machine type and the module (object)
machine type. Add a check to ensure that we do not attempt to use an object
file with a different target architecture.
This change identified a couple of tests which were incorrectly mixing up
architecture types, using x86 input for a x64 target. Adjust the tests
appropriately. The renaming of the input and the architectures covers the
changes to the existing tests.
One significant change to the existing tests is that the newly added test input
for x64 uses the correct user label prefix for X64.
llvm-svn: 219093
Diffstat (limited to 'lld/lib/Core/Error.cpp')
-rw-r--r-- | lld/lib/Core/Error.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lld/lib/Core/Error.cpp b/lld/lib/Core/Error.cpp index 3131276a7b3..c336964b432 100644 --- a/lld/lib/Core/Error.cpp +++ b/lld/lib/Core/Error.cpp @@ -38,6 +38,8 @@ public: return "out of memory"; case NativeReaderError::unknown_chunk_type: return "unknown chunk type"; + case NativeReaderError::conflicting_target_machine: + return "conflicting target machine"; } llvm_unreachable("An enumerator of NativeReaderError does not have a " "message defined."); |