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

Inline pragmas for functions breaks Vivado HLS backend #275

Open
sgpthomas opened this issue Nov 11, 2019 · 4 comments
Open

Inline pragmas for functions breaks Vivado HLS backend #275

sgpthomas opened this issue Nov 11, 2019 · 4 comments

Comments

@sgpthomas
Copy link
Contributor

sgpthomas commented Nov 11, 2019

It seems like the INLINE pragma that we add to functions cause the synthesized circuit to be incorrect. Removing it causes the generated circuits to be correct. We need to figure out why this is the case.

@rachitnigam
Copy link
Member

This is not sufficient to reproduce the bug. On a broader note, it seems hard in general to build upon a broken backend--we have to assume that the backend is correct for our semantics to be correct. A bug in the backend is not a bug in our compiler.

@sampsyo @sgpthomas thoughts?

@sampsyo
Copy link
Contributor

sampsyo commented Feb 8, 2020

Well, speaking purely philosophically and not about this specific case, I think it's a little less cut and dry for us than other compilers… because part of Dahlia's "value proposition" is in avoiding the "bad parts" of HLS. So wantonly producing incorrect hardware because the backend is broken is probably not the philosophy we want to embrace for all incorrectness. But on the other hand, at some point, we can't fix everything about the wobbliness of the backend…

@rachitnigam
Copy link
Member

I thought the “avoiding bad parts” to be statically definable bad parts. HLS tools add new bugs every version. Trying to prevent those bug seems like a losing battle—we’d have to reverse engineer new bugs every version and the compiler would become a collection of ad hoc warnings.

On the other hand, the static behaviors rejected by the type system have a formal meaning and an explanation.

@sampsyo
Copy link
Contributor

sampsyo commented Feb 9, 2020

Yeah, always working around weird bugs might be infeasible. But I guess I'm just pointing out that the distinction between "weird bugs in this particular version of Vivado HLS" and "legitimately hard-to-implement hardware thing that VIvado HLS does poorly on" is a fuzzier line than it might seem. So, like, avoiding the "wrong" inlining pragma and finding the "right" one might be worth doing, for example.

@rachitnigam rachitnigam changed the title Function pragmas break the correctness of synthesis Inline pragmas for functions breaks Vivado HLS backend Jan 26, 2021
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

3 participants