Skip to content

[HIP] Emit error for non-zero dynamic shared memory - #21118

Merged
qedawkins merged 2 commits into
iree-org:mainfrom
qedawkins:error_on_nonzero_shared_mem
Jun 17, 2025
Merged

qedawkins merged 2 commits into
iree-org:mainfrom
qedawkins:error_on_nonzero_shared_mem

Conversation

@qedawkins

@qedawkins qedawkins commented Jun 17, 2025 •

Copy link
Copy Markdown
Contributor

Leaving the field deprecated allowed for older vmfbs to silently load
and execute incorrectly. This un-deprecates the field and emits an error
if present and non-zero. After the next release we plan to formally drop it.

Leaving the field deprecated allowed for older vmfbs to silently load
+ execute incorrectly. This un-deprecates the field and emits an error
if present and non-zero. After the next release we plan to formally
drop it.
@qedawkins

Copy link
Copy Markdown
Contributor Author

I verified locally that it emits the expected error on an old vmfb

runtime/src/iree/hal/drivers/hip/native_executable.c:443: INVALID_ARGUMENT; exports[0] for kernel `matmul_dispatch_0_matmul_like_Dx4096x4096_f16xf16xf32` specified non-zero deprecated field block_shared_memory_size in modules[0]. Verify matching compiler and runtime versions.; while invoking native function hal.executable.create; while calling import; 
[ 0] bytecode module.__init:1286 base_ir/specialized_matmul.mlir:11:10
      at base_ir/specialized_matmul.mlir:5:3; creating VM context; creating run context

@qedawkins
qedawkins enabled auto-merge (squash) June 17, 2025 18:07
@qedawkins
qedawkins merged commit aa64203 into iree-org:main Jun 17, 2025
@qedawkins
qedawkins deleted the error_on_nonzero_shared_mem branch June 17, 2025 19:30
AWoloszyn pushed a commit that referenced this pull request Dec 1, 2025
Leaving the field deprecated allowed for older vmfbs to silently load
and execute incorrectly. This un-deprecates the field and emits an error
if present and non-zero. After the next release we plan to formally drop it.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants