Skip to content

Inductor indexing kernels don't check for valid indices #93538

@ngimel

Description

@ngimel

When eager mode gets invalid indices for indexing operations (e.g. negative or larger than input size) it generates kernel assert and hard errors with invalidated context. Inductor isn't set up to error, it can produce silent wrong results or error out with illegal memory access, depending on the caching allocator state and indices values.
It's unclear if triton can have internal asserts in its kernels, but we should still think what our behavior should be in these cases, see pytorch/torchdynamo#1515 (comment)

cc @ezyang @soumith @msaroufim @wconstab @bdhirsh

Metadata

Metadata

Labels

oncall: pt2triagedThis issue has been looked at a team member, and triaged and prioritized into an appropriate module

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions