[PATCH] D11028: Make TargetLowering::getPointerTy() taking DataLayout as an argument
Mehdi AMINI
mehdi.amini at apple.com
Wed Jul 8 15:35:05 PDT 2015
joker.eph added inline comments.
================
Comment at: include/llvm/CodeGen/BasicTTIImpl.h:149
@@ -148,3 +148,3 @@
bool isTypeLegal(Type *Ty) {
- EVT VT = getTLI()->getValueType(Ty);
+ EVT VT = getTLI()->getValueType(TargetTransformInfoImplBase::DL, Ty);
return getTLI()->isTypeLegal(VT);
----------------
echristo wrote:
> My C++ knowledge may be lacking here, but why can't we use getDataLayout here?
C++ weirdness explained here: https://isocpp.org/wiki/faq/templates#nondependent-name-lookup-members
Now, we could also write `this->DL`. But I may be better adding a using `TargetTransformInfoImplBase::DL` in the class itself instead of clobbering every single use.
http://reviews.llvm.org/D11028
More information about the llvm-commits
mailing list