Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect pattern DynamicIotaOpToBroadcast #2628

Open
christopherbate opened this issue Nov 16, 2024 · 0 comments
Open

Incorrect pattern DynamicIotaOpToBroadcast #2628

christopherbate opened this issue Nov 16, 2024 · 0 comments

Comments

@christopherbate
Copy link
Contributor

What happened?

// RUN: stablehlo-opt %s -stablehlo-aggressive-simplification

func.func @dynamic_iota_broadcast_second(%arg0 : tensor<2xi32>) -> tensor<5x?xi32> {
  %0 = "stablehlo.dynamic_iota"(%arg0) <{iota_dimension = 1 : i64}> : (tensor<2xi32>) -> tensor<5x?xi32>
  func.return %0 : tensor<5x?xi32>
}

Pattern DynamicIotaOpToBroadcast assumes arith.index_cast can be used even if operand and result types are both not index, but this is not true (perhaps it was at the time the MHLO code was written).

Anyways, it seems like arith.index_cast shouldn't be required anymore.

Steps to reproduce your issue

  1. Go to '...'
  2. Click on '....'
  3. Scroll down to '....'
  4. See error

Version information

No response

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

No branches or pull requests

1 participant