[Mlir-commits] [mlir] [TOSA] Add pass to sanitize gather/scatter indices (PR #221200)

Luke Hutton llvmlistbot at llvm.org
Mon Sep 7 03:47:53 PDT 2026


================
@@ -199,6 +199,24 @@ def TosaDowngrade1p1To1p0Pass
   }];
 }
 
+def TosaGatherScatterHardeningPass
+    : Pass<"tosa-gather-scatter-hardening", "func::FuncOp"> {
+  let summary = "Clamp TOSA gather and scatter indices to valid bounds";
+  let description = [{
+    Bounds the indices used by each gather and scatter with TOSA minimum and
+    maximum operations so that all accesses are in bounds. When the same
----------------
lhutton1 wrote:

I think it would be nice to highlight why this is a useful property for security, despite it being trivial

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


More information about the Mlir-commits mailing list