[PATCH] D44928: [MC] Pass MCSubtargetInfo to fixupNeedsRelaxation and applyFixup
Eric Christopher via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon May 21 01:44:07 PDT 2018
echristo added a comment.
Herald added a subscriber: atanasyan.
Taking a quick glance through this I wonder if adding the subtarget to the fragment is necessary since we've got it at encodeInstruction time? I haven't done a thorough look, but I'm concerned we're missing something here.
Thoughts? Also one similar sort of inline comment.
================
Comment at: lib/Target/ARM/MCTargetDesc/ARMAsmBackend.h:22-25
+ // The STI from the target triple the MCAsmBackend was instantiated with
+ // note that MCFragments may have a different local STI that should be
+ // used in preference.
const MCSubtargetInfo &STI;
----------------
I think we should just rely on a passed in STI wherever necessary and only store module/object level caches here. Also applies to isThumbMode below :)
Thoughts?
https://reviews.llvm.org/D44928
More information about the llvm-commits
mailing list