[llvm] [IR][TableGen] Add RangeSet TableGen intrinsic property (PR #203623)
Rahul Joshi via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 13 10:00:38 PDT 2026
================
@@ -886,6 +891,52 @@ AttributeSet Intrinsic::getFnAttributes(LLVMContext &C, ID id) {{
NoFunctionAttrsID);
}
+void IntrinsicEmitter::EmitImmArgRangeSetChecks(
+ const CodeGenIntrinsicTable &Ints, raw_ostream &OS) {
+ IfDefEmitter IfDef(OS, "GET_INTRINSIC_IMMARG_RANGE_SET_CHECKS");
+ OS << R"(
+bool Intrinsic::isImmArgValueInRangeSet(ID IID, unsigned ArgIdx,
----------------
jurahul wrote:
Thanks. This looks good. Its still doing a linear search within the list for a given intrinsic, but if that becomes a problem, we can make it a binary search. I suspect for small list size, linear search is still faster, so what we have might be ok.
https://github.com/llvm/llvm-project/pull/203623
More information about the llvm-commits
mailing list