Skip to content

Conversation

@ibsidorenko
Copy link

The type inference task consists of two subtasks: shape inference and dtype inference. For operations such as torch.aten.cat, shape inference works correctly, but dtype inference fails. This commit fixes that issue.

Enable loop unrolling within DtypeCalculateOp regions to support dtype inference for operations with list-type operands, such as torch.aten.cat. This commit extends FullyUnrollPrimLoop pattern to also unroll loops contained in DtypeCalculateOp regions, enabling the simplification pass to promote dtype information through operations like torch.aten.cat.

Enable loop unrolling within DtypeCalculateOp regions to support dtype
inference for operations with list-type operands, such as torch.aten.cat.
This commit extends FullyUnrollPrimLoop pattern to also unroll loops
contained in DtypeCalculateOp regions, enabling the simplification pass
to promote dtype information through operations like torch.aten.cat.
@ibsidorenko
Copy link
Author

ibsidorenko commented Dec 15, 2025

Hi, @ramiro050 @zjgarvey ! Can you please review this PR and enable 2 workflows for testing?

Copy link
Collaborator

@zjgarvey zjgarvey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch, thanks!

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