ELF: Report original emulation name in "unknown emulation" error
authorEd Maste <emaste@freebsd.org>
Thu, 8 Sep 2016 19:36:22 +0000 (19:36 +0000)
committerEd Maste <emaste@freebsd.org>
Thu, 8 Sep 2016 19:36:22 +0000 (19:36 +0000)
commit2b68ada188d0e850875a0ebf6939276fd21a71b4
tree919b772fa782602501ec71c507aed4aa14402eee
parent21e2be64034e3ad175be0e7d0e99eed3cb88469a
ELF: Report original emulation name in "unknown emulation" error

A trailing _fbsd is stripped from emulation names, but if the result was
still not a valid emulation the error was somewhat confusing.

For example,

% ld.lld -m elf_amd64_fbsd
unknown emulation: elf_amd64

Use the original emulation name in error messages.

Differential Revision: https://reviews.llvm.org/D24357

llvm-svn: 280983
lld/ELF/Driver.cpp
lld/test/ELF/basic.s