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

Emit assert/assume as call to llhd.assert intrinsic #222

Open
fabianschuiki opened this issue Jan 9, 2021 · 0 comments
Open

Emit assert/assume as call to llhd.assert intrinsic #222

fabianschuiki opened this issue Jan 9, 2021 · 0 comments
Labels
A-codegen Area: Code generation. C-enhancement Category: Adding or improving on features. E-easy Call for Participation: Easy issue, good first issue. L-vlog Language: Verilog and SystemVerilog.

Comments

@fabianschuiki
Copy link
Owner

Immediate assertions are currently ignored. As a first step to some minimally-useful implementation, lower them to a call to llhd.assert. Possibly something along the lines of:

    ; %0 = assertion condition
    br i1 %0, %bb0, %bb1
bb0:
    ; emit code of `else` statement here
    br %bb1
bb1:
    call void @llhd.assert (i1 %0)
@fabianschuiki fabianschuiki added E-easy Call for Participation: Easy issue, good first issue. L-vlog Language: Verilog and SystemVerilog. C-enhancement Category: Adding or improving on features. A-codegen Area: Code generation. labels Jan 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-codegen Area: Code generation. C-enhancement Category: Adding or improving on features. E-easy Call for Participation: Easy issue, good first issue. L-vlog Language: Verilog and SystemVerilog.
Projects
None yet
Development

No branches or pull requests

1 participant