-
Notifications
You must be signed in to change notification settings - Fork 787
Implement work_group_static / work_group_scratch_memory #15061
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
Merged
Merged
Changes from all commits
Commits
Show all changes
83 commits
Select commit
Hold shift + click to select a range
aa87907
WIP work_group_static
Naghasan 1a92e2d
fist stab at a combined compile-runtime property
Naghasan 7d686cf
clang format and use SYCLScope attr rather than local address space t…
Naghasan e5fd086
Merge branch 'sycl' into work_group_static
Naghasan 7746d8e
add more testing
Naghasan cabdbf3
fix up interface and update extension proposal
Naghasan 1567b92
restrict test
Naghasan 817f293
Merge branch 'sycl' into work_group_static
Naghasan a392e4e
use https for UR
Naghasan 149f98f
clang format
Naghasan 10edb4a
clang-format using proper version
Naghasan 57114bc
change type for local memory size
Naghasan 6cb38eb
fix unit test
Naghasan 1982e4b
fix testing
Naghasan 8ddbb3c
fix test and added few comments
Naghasan 4f465fd
Split compile-time property key and value
sommerlukas 08c716d
quick clean up
Naghasan cdbd3f5
Merge branch 'sycl' into work_group_static
Naghasan c65dee9
format
Naghasan 0a3a20e
fix merge issue
Naghasan 06d4028
sync with UR tip
Naghasan f66b4ce
format with clang 18
Naghasan 66521ac
Fix lit test
Naghasan 8ee4cd4
fix symbol check on windows
Naghasan adfe81f
Fix property query and improve tests
sommerlukas 1ffd092
Remove outdated test
sommerlukas 34483a6
Merge branch 'sycl' into work_group_static
Naghasan f3b997b
Merge branch 'sycl' into work_group_static
Naghasan bcfcbb0
sync and fix test
Naghasan e064618
fix test include
Naghasan c35b6ff
format
Naghasan e65025d
Merge branch 'sycl' into work_group_static
Naghasan ab311af
Merge branch 'sycl' into work_group_static
Naghasan 5752615
Address comments
Naghasan 416f7ff
Merge branch 'sycl' into work_group_static
Naghasan 9409de9
add test and improve diags
Naghasan 4112fbf
Add fmoreimprovments
Naghasan 033f773
apply more feedback
Naghasan 8110c20
Add test for sycl-graph
Naghasan 32d2d37
split extension into static and dynamic case, add more tests
Naghasan dafc3dd
Merge branch 'sycl' into work_group_static
Naghasan 0963146
fix include test
Naghasan c5f2ebb
address comments and disable dynamic tests on gen12 (not locally repr…
Naghasan 6cf6a96
document interaction of sycl_ext_oneapi_work_group_scratch_memory wit…
Naghasan 675f9ff
address review comments
Naghasan 5c8461b
Merge branch 'sycl' into work_group_static
Naghasan 8cd4e2e
fix merge conflict issue
Naghasan 803764e
fix missing enum handling
Naghasan 2f4cdae
clang format
Naghasan 986c9ff
Merge branch 'sycl' into work_group_static_tmp
Naghasan 5237f69
Create hybrid runtime prop with compile time info
Naghasan 5bc8157
Move builtins definitions to their own file
Naghasan dc71a36
format
Naghasan 9a1421c
forgot file
Naghasan 566bebd
Address review comments
Naghasan 7c609b6
Apply suggestions from code review
Naghasan 56bd349
make alignment a constexpr variable to be more explicit
Naghasan 8d121ec
Merge branch 'sycl' into work_group_static
Naghasan a881995
format
Naghasan 9a505ae
fix UR commit hash
Naghasan 9cefd48
add tracker and UR squash commit
Naghasan eea2241
remove eq/neq operator
Naghasan c163fb1
Merge branch 'sycl' into work_group_static
Naghasan 430bd9c
address last feedbacks
Naghasan 44ada24
fix save issue
Naghasan 94bb685
update ur tag
Naghasan ca0b450
Merge branch 'sycl' into work_group_static
Naghasan 0beea9d
Merge branch 'sycl' into work_group_static
Naghasan 5192c25
add missing include
Naghasan 7f210e2
format
Naghasan b95ecfd
include
Naghasan fa0f7c4
Merge branch 'sycl' into work_group_static
Naghasan af1bc10
Merge branch 'sycl' into work_group_static
Naghasan b728c9c
Merge branch 'sycl' into work_group_static
Naghasan 33ea3b0
Bump UR tag
callumfare 3b3f327
Bump UR tag to test UR PR
callumfare 921c64b
Merge branch 'sycl' into work_group_static
callumfare 32589ef
disable hip
Naghasan e7b4372
Merge branch 'sycl' into work_group_static
Naghasan 435c65a
Merge branch 'sycl' into work_group_static
Naghasan 39158c3
Merge branch 'sycl' into work_group_static
Naghasan 97a417a
tag
Naghasan 32d8e16
[UR] Update tag to 5acc824 for UR #2403.
martygrant File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
// Verify the use of wg_scope is correctly diagnosed. | ||
// RUN: %clang_cc1 -fsycl-is-device -verify %s | ||
Naghasan marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
class [[__sycl_detail__::wg_scope]] G1 {}; | ||
class [[__sycl_detail__::wg_scope]] G2 { | ||
G2() = default; | ||
G2(int i) : i(i) {} | ||
int i; | ||
}; | ||
|
||
class [[__sycl_detail__::wg_scope]] G3 { | ||
~G3() = default; | ||
}; | ||
|
||
class [[__sycl_detail__::wg_scope]] B4 { // expected-error {{SYCL work group scope only applies to class with a trivial default constructor}} | ||
B4() {} | ||
}; | ||
|
||
class [[__sycl_detail__::wg_scope]] B5 { // expected-error {{SYCL work group scope only applies to class with a trivial destructor}} | ||
~B5() {} | ||
}; | ||
|
||
class [[__sycl_detail__::wg_scope]] B6 { // expected-error {{SYCL work group scope only applies to class with a trivial default constructor}} | ||
B6() {} | ||
~B6() {} | ||
}; | ||
|
||
template <typename T> class [[__sycl_detail__::wg_scope]] B7 { // #B7 | ||
public: | ||
T obj; | ||
}; | ||
|
||
struct Valid {}; | ||
struct InvalidCtor { | ||
InvalidCtor() {} | ||
}; | ||
struct InvalidDtor { | ||
~InvalidDtor() {} | ||
}; | ||
struct InvalidCDtor { | ||
InvalidCDtor() {} | ||
~InvalidCDtor() {} | ||
}; | ||
|
||
B7<Valid> b7; | ||
// expected-error@#B7 {{SYCL work group scope only applies to class with a trivial default constructor}} | ||
// expected-note@+1 {{in instantiation of template class 'B7<InvalidCtor>' requested here}} | ||
B7<InvalidCtor> b9; | ||
// expected-error@#B7 {{SYCL work group scope only applies to class with a trivial destructor}} | ||
// expected-note@+1 {{in instantiation of template class 'B7<InvalidDtor>' requested here}} | ||
B7<InvalidDtor> b10; | ||
// expected-error@#B7 {{SYCL work group scope only applies to class with a trivial default constructor}} | ||
// expected-note@+1 {{in instantiation of template class 'B7<InvalidCDtor>' requested here}} | ||
B7<InvalidCDtor> b11; | ||
|
||
template <typename T> class [[__sycl_detail__::wg_scope]] B12 { // #B12 | ||
public: | ||
B12() = default; | ||
~B12() = default; | ||
T obj; | ||
}; | ||
|
||
B12<Valid> b12; | ||
// expected-error@#B12 {{SYCL work group scope only applies to class with a trivial default constructor}} | ||
// expected-note@+1 {{in instantiation of template class 'B12<InvalidCtor>' requested here}} | ||
B12<InvalidCtor> b13; | ||
|
||
class B14 { | ||
G1 field; // expected-error {{non-static data member is of a type with a SYCL work group scope attribute applied to it}} | ||
}; | ||
|
||
template <typename T> class B15 { | ||
T field; // #B15-field | ||
}; | ||
|
||
// expected-error@#B15-field {{non-static data member is of a type with a SYCL work group scope attribute applied to it}} | ||
// expected-note@+1 {{in instantiation of template class 'B15<G1>' requested here}} | ||
B15<G1> b15; | ||
|
||
G1 g16; | ||
static G1 g17; | ||
|
||
struct Wrap { | ||
static G1 g18; | ||
}; | ||
|
||
__attribute__((sycl_device)) void ref_func() { | ||
G1 g19; | ||
static G1 g20; | ||
|
||
(void)g16; | ||
(void)g17; | ||
(void)Wrap::g18; | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.