After D41349, we can now directly access MCSubtargetInfo from createARM*AsmBackend. This patch makes use of this, avoiding the need to create a fresh MCSubtargetInfo (which was previously always done with a blank CPU and feature string). Given the total size of the change remains pretty tiny and we're removing the old explicit destructor, I changed the STI field to a reference rather than a pointer.
Details
Details
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
Comment Actions
Great, thank you very much for cleaning that up Alex! It would be great if you could replace the string search for "thumb" with isThumb() before committing
lib/Target/ARM/MCTargetDesc/ARMAsmBackend.h | ||
---|---|---|
28 ↗ | (On Diff #128500) | Could you use STI.getTargetTriple().isThumb() here? |
llvm/trunk/lib/Target/ARM/MCTargetDesc/ARMAsmBackend.h | ||
---|---|---|
26 | The Target also appears to be unnecessary. |
Comment Actions
This change produced a new error with LTO and AOSP ARM thumb code.
Please see a reduced test case at https://bugs.llvm.org/show_bug.cgi?id=36542
The Target also appears to be unnecessary.