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

[BUG] KeyError: 'attempt to access a non-existent attribute' #152

Open
chhzh123 opened this issue Apr 24, 2024 · 0 comments
Open

[BUG] KeyError: 'attempt to access a non-existent attribute' #152

chhzh123 opened this issue Apr 24, 2024 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@chhzh123
Copy link
Member

An error in the buffer generation pass.

import allo
from allo.ir.types import int32

def func(A: int32[8]) -> int32[8]:
    return A

def top(A: int32[8]) -> int32[8]:
    return func(A)

s = allo.customize(top)
print(s.module)
s.build(target="vitis_hls", mode="csim")

This will lead to the following error:

Traceback (most recent call last):
  File "/scratch/users/hc676/allo/test.py", line 12, in <module>
    s.build(target="vitis_hls", mode="csim")
  File "/scratch/users/hc676/allo/allo/customize.py", line 685, in build
    return HLSModule(
           ^^^^^^^^^^
  File "/scratch/users/hc676/allo/allo/backend/hls.py", line 175, in __init__
    buffers = generate_input_output_buffers(
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/scratch/users/hc676/allo/allo/passes.py", line 159, in generate_input_output_buffers
    MockBuffer(top_func_name, arg.owner.attributes["name"].value)
                              ~~~~~~~~~~~~~~~~~~~~^^^^^^^^
KeyError: 'attempt to access a non-existent attribute'
@chhzh123 chhzh123 added the bug Something isn't working label Apr 24, 2024
@chhzh123 chhzh123 self-assigned this Apr 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant