-
Notifications
You must be signed in to change notification settings - Fork 796
[SYCL][DOC] Add extension for FPGA kernel interface properties #5715
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
[SYCL][DOC] Add extension for FPGA kernel interface properties #5715
Conversation
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
| |`ip_interface_streaming` | ||
| |The `ip_interface_streaming` property adds the requirement that the kernel must | ||
| have dedicated ports for input / output signals in the generated | ||
| Register Transfer Level (RTL) module. |
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.
I would drop the mention of RTL. It confuses things to refer to the description of the hardware as being separate from the hardware itself.
Also, I think your intent is for this to apply to both control and data signals. Can you state the explicitly? And assuming that this should apply to data signals as well, should it apply to all inputs/outputs from the kernel, i.e. pipes as well, or only kernel arguments?
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.
Added explicit statement. Specified that it should apply to kernel arguments and control flow signals only. Including pipes seems to make sense. I need to think a bit more about including them.
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
| *a = *b + *c; | ||
| } | ||
|
|
||
| auto get(sycl::ext::oneapi::experimental::properties_tag) { |
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.
Is this a magic function that encode the properties? How it is connected to the single_task below?
| |`pipelined_kernel` | ||
| | The `pipelined_kernel` property directs the compiler to pipeline calls to the | ||
| kernel so that multiple invocations of the kernel can be in flight | ||
| simultaneously. |
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.
Do you mean several instances of a single_task or this is pipelining at the work-item level?
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.
This refers to several instances of a kernel, most commonly a single_task kernel. It does not refer to pipelining of work-items. However, there's no reason this couldn't be applied to a parallel_for kernel to request that successive launches of that kernel be pipelined in addition to the usual work item pipelining. In such a kernel, the work items could be injected into the datapath one after another and, after the last work item from a given kernel invocation has been injected, the first work-item of the next invocation could be injected without waiting for the pipeline to drain.
I don't see much value in a control to enable or disable pipelining at the work-item level because that's nearly always beneficial. This invocation pipelining is more situational though as it only provides value if the user intends to launch the same kernel multiple times.
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
|
ping @intel/dpcpp-specification-reviewers |
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
…/tiwaria1/llvm into fpga_kernel_interface_properties
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
steffenlarsen
left a comment
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!
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
…ace_properties.asciidoc Co-authored-by: GarveyJoe <[email protected]>
Co-authored-by: GarveyJoe <[email protected]>
keryell
left a comment
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.
pipelined could be simplified to take a single parameter with value false, true or some II value.
The current cartesian product with 2 parameters is useless since false and an II is meaningless.
|
Also having a default |
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Show resolved
Hide resolved
| the following extensions: | ||
|
|
||
| - link:../experimental/sycl_ext_oneapi_properties.asciidoc[sycl_ext_oneapi_properties] | ||
| - link:sycl_ext_oneapi_kernel_properties.asciidoc[sycl_ext_oneapi_kernel_properties] |
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.
Links are broken
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.
They seem to be working now.
oneapi properties is in experimental folder: https://github.com/intel/llvm/tree/sycl/sycl/doc/extensions/experimental
and oneapi kernel properties will be in the proposed folder after 5755 PR goes in : https://github.com/intel/llvm/pull/5755/files
|
@steffenlarsen I addressed the remaining comments. Please review and merge this PR. Based on your namespace comment on a different PR I have updated the namespace here to be |
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
steffenlarsen
left a comment
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.
Just a few more comments, then I think I'm happy!
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Outdated
Show resolved
Hide resolved
sycl/doc/extensions/proposed/sycl_ext_intel_fpga_kernel_interface_properties.asciidoc
Show resolved
Hide resolved
Hey Steffen, I addressed the other comments. Please take a look. |
steffenlarsen
left a comment
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!
SYCL extension contains the following new kernel properties
streaming_interface<...>register_map_interface<...>The first two properties take enum arguments that provide the compiler information about whether the logic downstream to the kernel will back-pressure the kernel or not.
pipelined<N>Takes an integer, non-zero values specify minimum cycles between kernel invocations, and 0 specifies that pipelining should be disabled.