Displaying 2 results from an estimated 2 matches for "bpftargetmachine".
2017 Aug 22
2
Subtarget Initialization in <ARCH>TargetMachine constructor
Hi,
I found some different discrepancy on how Subtarget is created
between some arch specific TargetMachine constructor.
For example, for BPF/Lanai:
BPFTargetMachine::BPFTargetMachine(const Target &T, const Triple &TT,
StringRef CPU, StringRef FS,
const TargetOptions &Options,
Optional<Reloc::Model> RM,
Op...
2017 Aug 23
2
Subtarget Initialization in <ARCH>TargetMachine constructor
...ter on is returned through:
>> const LanaiSubtarget *
>> getSubtargetImpl(const llvm::Function & /*Fn*/) const override {
>> return &Subtarget;
>> }
>
> Ok, so BPF and Lanai initialize a BPFSubtarget and LanaiSubtarget in
> the initializer list for BPFTargetMachine and LanaiTargetMachine. I'm
> not sure I quite follow your concern about initAsmInfo, as that
> accesses an MCSubtargetInfo rather than a subclass of Subtarget.
The following is what I observed:
Both Subtarget constructor and initAsmInfo will eventually create
a MCSubtargetInfo, which ca...