Commit 74ffed8
authored
[SYCL][NewOffloadModel] Support optional kernel features and fix ocloc argument parsing (#20470)
This patch adds support for optional kernel features and fixes ocloc
command parsing with the following changes:
(1) Enable optional kernel features for the new offloading model by
passing the device architecture name to the `sycl-post-link` command
constructed in `ClangLinkerWrapper.cpp`. This invokes `sycl-post-link`
with the device architecture when Intel GPU targets are specified in
`-fsycl-targets`. A new test has been added in `aot-gpu.cpp` to verify
this functionality.
(2) The original implementation in `ClangLinkerWrapper.cpp` incorrectly
constructed `ocloc` command line arguments by concatenating all
arguments into a single string, causing parsing failures in the
executor. This patch fixes the issue by properly splitting arguments on
whitespace boundaries and rejoining them into a correctly formatted
command string.
(3) Add test cases running with `-O0 -g` flag to `fp64-conv-emu-1.cpp`
and `fp64-conv-emu-2.cpp`
The following tests now pass (fail before) with the new offload model
after applying this patch:
1. fp64-conv-emu-1.cpp
2. fp64-conv-emu-2.cpp
3. AOT/double.cpp
4. AOT/half.cpp
5. AOT/reqd-sg-size.cpp
6. BFloat16/bfloat16_example_aot_gpu.cpp
7. DeviceArchitecture/device_architecture_comparison_on_device_aot.cpp
8. AOT/fallback.cpp1 parent 97efb4f commit 74ffed8
File tree
4 files changed
+30
-3
lines changed- clang
- test/Driver
- tools/clang-linker-wrapper
- sycl/test-e2e/OptionalKernelFeatures
4 files changed
+30
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
66 | | - | |
| 66 | + | |
| 67 | + | |
67 | 68 | | |
68 | 69 | | |
69 | 70 | | |
70 | 71 | | |
71 | 72 | | |
72 | 73 | | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
73 | 80 | | |
74 | 81 | | |
75 | 82 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
727 | 727 | | |
728 | 728 | | |
729 | 729 | | |
| 730 | + | |
| 731 | + | |
| 732 | + | |
| 733 | + | |
| 734 | + | |
| 735 | + | |
| 736 | + | |
| 737 | + | |
| 738 | + | |
| 739 | + | |
| 740 | + | |
| 741 | + | |
| 742 | + | |
| 743 | + | |
| 744 | + | |
730 | 745 | | |
731 | 746 | | |
732 | 747 | | |
733 | | - | |
734 | 748 | | |
735 | 749 | | |
736 | 750 | | |
| |||
748 | 762 | | |
749 | 763 | | |
750 | 764 | | |
751 | | - | |
| 765 | + | |
752 | 766 | | |
753 | 767 | | |
754 | 768 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
23 | 26 | | |
24 | 27 | | |
25 | 28 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
23 | 23 | | |
24 | 24 | | |
25 | 25 | | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
26 | 29 | | |
27 | 30 | | |
28 | 31 | | |
| |||
0 commit comments