You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[SYCL] Add support for new spelling of FPGA kernel attribute scheduler_target_fmax_mhz (#2618)
Clang support for FPGA kernel attribute
[[intelfpga::scheduler_target_fmax_mhz()]] was added on commit 20013e2.
commit 5949228 updated all FPGA attribute spellings that currently used
intelfpga:: prefixes to intel:: in all lowercase to avoid mismatch
between our namespace in SYCL (which use intel::) and the prefixes
we used for FPGA attributes in LLVM.
This patches
1. Enable attribute spelling with intel:: prefix, without disabling the previous one.
2. Provide a deprecation warning for the previous attribute spelling.
3. Modify the tests and documentation.
Signed-off-by: Soumi Manna <[email protected]>
[[intelfpga::scheduler_target_fmax_mhz(0)]] int Var = 0; // expected-error{{'scheduler_target_fmax_mhz' attribute only applies to functions}}
39
+
[[intel::scheduler_target_fmax_mhz(0)]] int Var = 0; // expected-error{{'scheduler_target_fmax_mhz' attribute only applies to functions}}
36
40
37
41
cl::sycl::kernel_single_task<classtest_kernel4>(
38
-
[]() [[intelfpga::scheduler_target_fmax_mhz(1048577)]]{}); // expected-error{{'scheduler_target_fmax_mhz' attribute requires integer constant between 0 and 1048576 inclusive}}
42
+
[]() [[intel::scheduler_target_fmax_mhz(1048577)]]{}); // expected-error{{'scheduler_target_fmax_mhz' attribute requires integer constant between 0 and 1048576 inclusive}}
39
43
40
44
cl::sycl::kernel_single_task<classtest_kernel5>(
41
-
[]() [[intelfpga::scheduler_target_fmax_mhz(-4)]]{}); // expected-error{{'scheduler_target_fmax_mhz' attribute requires integer constant between 0 and 1048576 inclusive}}
45
+
[]() [[intel::scheduler_target_fmax_mhz(-4)]]{}); // expected-error{{'scheduler_target_fmax_mhz' attribute requires integer constant between 0 and 1048576 inclusive}}
42
46
43
47
cl::sycl::kernel_single_task<classtest_kernel6>(
44
-
[]() [[intelfpga::scheduler_target_fmax_mhz(1), intelfpga::scheduler_target_fmax_mhz(2)]]{}); // expected-warning{{attribute 'scheduler_target_fmax_mhz' is already applied with different parameters}}
48
+
[]() [[intel::scheduler_target_fmax_mhz(1), intel::scheduler_target_fmax_mhz(2)]]{}); // expected-warning{{attribute 'scheduler_target_fmax_mhz' is already applied with different parameters}}
0 commit comments