https://github.com/aeubanks commented:

I see that MMI really is a Codegen concept and not a Target concept, so that's 
why it takes an LLVMTargetMachine instead of TargetMachine. However, the 
`static_cast`s everywhere are extremely unfortunate. And it doesn't make sense 
to make the return type of `Target::createTargetMachine()` `LLVMTargetMachine` 
instead of `TargetMachine`. Perhaps alternatively we make the MMI constructor 
take `TargetMachine` and cast it inside the constructor to `LLVMTargetMachine`, 
so we only pay the cost of this weird distinction in one place rather than 
everywhere? wdyt?

https://github.com/llvm/llvm-project/pull/110443
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to