-
Notifications
You must be signed in to change notification settings - Fork 790
[SYCL][FPGA] Add implicit memory attribute with [[intel::max_replicates()]] #3409
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
Conversation
…es()]] If the declaration does not have an [[intel::fpga_memory]] attribute, we create one as an implicit attribute. During refactoring work with [[intel::max_replicates()]] attribute, we somehow dropped the implicit memory attribute. This patch fixes the problem. Signed-off-by: soumi.manna <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good.
clang/lib/Sema/SemaDeclAttr.cpp
Outdated
// attribute, this creates one as an implicit attribute. | ||
if (!D->hasAttr<IntelFPGAMemoryAttr>()) | ||
D->addAttr(IntelFPGAMemoryAttr::CreateImplicit( | ||
Context, IntelFPGAMemoryAttr::Default)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does it make sense to do this outside the if condition? i.e. we want to do this regardless of E's value dependency, no?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch! Same goes for checking for mutual exclusion, I suppose.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, I will fix this and upload new patch. Thanks
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
Signed-off-by: soumi.manna <[email protected]>
Signed-off-by: Soumi Manna <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
If the declaration does not have an [[intel::fpga_memory]] attribute,
we create one as an implicit attribute.
During refactoring work with [[intel::max_replicates()]] attribute, we somehow
dropped the implicit memory attribute.
This patch fixes the problem.
Signed-off-by: soumi.manna [email protected]