This is splitted out from D85519, but significantly reworked.
Changes:
- This test was changed to stop using python.
- Use NoHeaders: true instead of llvm-objcopy --strip-sections.
- Test llvm-readelf too (not just llvm-readobj).
- Simplify the YAML used a bit (e.g. remove PT_LOAD).
- Test 2 different cases: objects with section header table and without.