[PATCH] D90107: [TableGen] [AMDGPU] Add !sub bang operator for subtraction

Madhur Amilkanthwar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 28 06:30:56 PDT 2020


madhur13490 accepted this revision.
madhur13490 added inline comments.
This revision is now accepted and ready to land.


================
Comment at: llvm/docs/TableGen/ProgRef.rst:1664
+``!sub(``\ *a*\ ``,`` *b*\ ``)``
+    This operator subtracts *b* from *a* and produces the difference.
+
----------------
nit; ".. and produces the arithmetic difference"


================
Comment at: llvm/lib/TableGen/TGParser.cpp:1259
+            Code != BinOpInit::SRL && Code != BinOpInit::SHL &&
+            Code != BinOpInit::MUL)
           ArgType = Resolved;
----------------
I think the condition can be moved to a separate function before it becomes unmanageable.


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

https://reviews.llvm.org/D90107



More information about the llvm-commits mailing list