We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
def test_if_struct_access(): hcl.init() def kernel(): tag = hcl.scalar(0, "tag", dtype='uint32') stype = hcl.Struct({"x": hcl.UInt(8), "y": hcl.UInt(8)}) xy = hcl.scalar(0x1234, "xy", dtype=stype).v with hcl.if_(xy.x==1): # use of struct field access causes a scheduler error tag.v = 1 r = hcl.compute((2,), lambda i: tag.v, dtype=hcl.UInt(32)) return r s = hcl.create_schedule([], kernel)
The above code generates the following runtime error:
error: 'affine.load' op operation destroyed but still has uses LLVM ERROR: operation destroyed but still has uses
The text was updated successfully, but these errors were encountered:
Fails at: https://github.com/cornell-zhang/hcl-dialect-prototype/blob/4704d17e46b2df07f8074857b706b82c8c671c06/include/hcl/Bindings/Python/hcl/build_ir.py#L2646-L2647
@chhzh123 why do we remove built condition operations here?
Sorry, something went wrong.
Fixed by 7906b26
Added remove and profile mode for struct op visitors
Test case added here: https://github.com/cornell-zhang/heterocl/blob/9f7212f02dcf49e72fe6a980ace86e9f8b591f4d/tests/test_scalar.py#L87-L125
Closing the thread as the issue has been fixed
zzzDavid
No branches or pull requests
The above code generates the following runtime error:
The text was updated successfully, but these errors were encountered: