[PATCH] D67544: [TableGen] Support encoding and decoding per-HwMode

Krzysztof Parzyszek via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 18 06:41:03 PDT 2019


kparzysz added a comment.

Looks good to me.



================
Comment at: llvm/utils/TableGen/SubtargetEmitter.cpp:1876
      << " const;\n";
   if (TGT.getHwModes().getNumModeIds() > 1)
     OS << "  unsigned getHwMode() const override;\n";
----------------
jmolloy wrote:
> kparzysz wrote:
> > This is probably unnecessary with your change.
> Unfortunately it's still necessary, as TargetSubtargetInfo and MCSubtargetInfo are not related. We need HwModes in both (test failures bear this out).
TargetSubtargetInfo inherits from MCSubtargetInfo, but you're right---each target defines its own subclass of MCSubtargetInfo which is not a part of TargetSubtargetInfo, so both need to be modified.


Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D67544/new/

https://reviews.llvm.org/D67544





More information about the llvm-commits mailing list