Hi, Justin Thansk, but I have a little concern though. I saw Chiou mentioned the compatibility issue of PTX on the mailing list. http://lists.cs.uiuc.edu/pipermail/llvmdev/2011-March/038654.html In my PTX.td patch, def FeaturePTX23 : SubtargetFeature<"ptx23", "PTXVersion", PTX_VERSION_2_3", "Use PTX Language Version 2.3", [FeaturePTX22]>; I can only guess above statement means PTX23 is fully compatible with PTX22. Is my guess right? If so, how can one express that FeatureA is NOT fully compatible with FeatureB in .td? Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667
On Sat, May 7, 2011 at 4:17 AM, 陳韋任 <chenwj at iis.sinica.edu.tw> wrote:> Hi, Justin > > Thansk, but I have a little concern though. I saw Chiou mentioned the > compatibility issue of PTX on the mailing list. > http://lists.cs.uiuc.edu/pipermail/llvmdev/2011-March/038654.html > > In my PTX.td patch, > > def FeaturePTX23 : SubtargetFeature<"ptx23", "PTXVersion", > PTX_VERSION_2_3", > "Use PTX Language Version 2.3", > [FeaturePTX22]>; > > I can only guess above statement means PTX23 is fully compatible with > PTX22. Is my guess right? If so, how can one express that FeatureA is > NOT fully compatible with FeatureB in .td? >Literally, it means any feature supported by PTX 2.2 is also supported by PTX 2.3. While this may not be strictly true, it is a good approximation for now, until more of the ISA is implemented. I wouldn't worry about it for now.> > Regards, > chenwj > > -- > Wei-Ren Chen (陳韋任) > Computer Systems Lab, Institute of Information Science, > Academia Sinica, Taiwan (R.O.C.) > Tel:886-2-2788-3799 #1667 > > _______________________________________________ > LLVM Developers mailing list > LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu > http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev >-- Thanks, Justin Holewinski -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110508/12315e86/attachment.html>
Hi, Justin I have sent another patch for subtarget ptx23 to llvm-commits. But I don't see it has been committed. Can you help me take look on it? I also attach that patch here. Regards, chenwj -- Wei-Ren Chen (陳韋任) Computer Systems Lab, Institute of Information Science, Academia Sinica, Taiwan (R.O.C.) Tel:886-2-2788-3799 #1667 -------------- next part -------------- Index: lib/Target/PTX/PTXSubtarget.h ==================================================================--- lib/Target/PTX/PTXSubtarget.h (revision 131048) +++ lib/Target/PTX/PTXSubtarget.h (working copy) @@ -72,6 +72,8 @@ bool supportsPTX22() const { return PTXVersion >= PTX_VERSION_2_2; } + bool supportsPTX23() const { return PTXVersion >= PTX_VERSION_2_3; } + std::string ParseSubtargetFeatures(const std::string &FS, const std::string &CPU); }; // class PTXSubtarget Index: lib/Target/PTX/PTXInstrInfo.td ==================================================================--- lib/Target/PTX/PTXInstrInfo.td (revision 131048) +++ lib/Target/PTX/PTXInstrInfo.td (working copy) @@ -36,6 +36,8 @@ def DoesNotSupportPTX21 : Predicate<"!getSubtarget().supportsPTX21()">; def SupportsPTX22 : Predicate<"getSubtarget().supportsPTX22()">; def DoesNotSupportPTX22 : Predicate<"!getSubtarget().supportsPTX22()">; +def SupportsPTX23 : Predicate<"getSubtarget().supportsPTX23()">; +def DoesNotSupportPTX23 : Predicate<"!getSubtarget().supportsPTX23()">; //===----------------------------------------------------------------------===// // Instruction Pattern Stuff