This change implements unified text stub format and command line interface proposed in the elfabi/ifs merge plan (https://lists.llvm.org/pipermail/llvm-dev/2021-March/149263.html). This CL mainly serves the purpose of verifying the ideas proposed in the merge plan. Once it lands, the next step will be update the clang IFSO driver and llvm-ifs to generate the text stub in the same format and performs the actual merging.
I ran into a lot of issues with LLVM's yaml library. It does not allow using ScalarTraits on Optional<uint16_t> type. It also does not allow mapping 2 traits on the same type, creating a lot of difficulties to support both Target: triple_string and Target: { Arch:..., Endianness: ...} in the same data structure. Please let me know if you have better workarounds than the one I used in this change.
When updating ifs tool with the unified text stub and command line interfacing, I plan to rename 'ELFStub.h' to 'InterfaceStub.h' 'TBEHandler.cpp' to 'IFSHandler.cpp' as these 2 will cover formats like TBD and COEF in the future. The naming of 'ELFObjHandler.h' will remans the same since it still only covers ELF related operations. Please let me know if you have any suggestions.