Skip to content
Commit 0b468b01 authored by Alex Zinenko's avatar Alex Zinenko Committed by jpienaar
Browse files

gpu::LaunchOp: canonicalize away constant kernel arguments

The GPU Launch operation may take constants as arguments, in particular
affine-to-GPU mapping pass automatically forwards potentially constant lower
bounds of loops into the kernel.  Define a canonicalization pattern for
LaunchOp that recreates the constants inside the kernel region instead of
accepting them as kernel arguments.  This is currently restricted to standard
constants but may be extended to other constant operations.

Also fix an off-by-one indexing bug in OperandStorage::eraseOperand.

PiperOrigin-RevId: 256035437
parent 705b8091
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment