[llvm] [IR] Add zext nneg flag (PR #67982)

Nikita Popov via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 18 00:50:04 PDT 2023


================
@@ -6381,8 +6381,17 @@ int LLParser::parseInstruction(Instruction *&Inst, BasicBlock *BB,
   }
 
   // Casts.
+  case lltok::kw_zext: {
+    bool NonNeg = EatIfPresent(lltok::kw_nneg);
+    bool Res = parseCast(Inst, PFS, KeywordVal);
+    if (NonNeg)
+      Inst->setNonNeg();
+    if (Res != 0) {
+      return Res;
+    }
+    return 0;
----------------
nikic wrote:

The check was in the wrong position, fixed.

https://github.com/llvm/llvm-project/pull/67982


More information about the llvm-commits mailing list