-
Notifications
You must be signed in to change notification settings - Fork 130
[SYCL][ESIMD] Add test on simd load ctor #769
Conversation
CI on Windows platform failed due to issue, that is not related to this PR. |
|
||
bool passed = true; | ||
const auto types = get_tested_types<tested_types::all>(); | ||
const auto dims = get_all_dimensions(); |
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.
Nit for future: please rename dimensions
to vector_lengths
or sizes
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.
dimensions
will be changed to one of suggested names for all tests in the one of next PR`
// flag. | ||
// It is expected for destination simd instance to store a bitwise same data as | ||
// the reference one. | ||
|
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.
Nits (can be added later)
- accessor-based load constructor not tested? If tested elsewhere, this should be called smth like usm_ctor*...
- most popular alignment for loading as a block will be overaligned<16>{} - oword. This is minimum requirement for block load. Not tested.
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.
accessor-based load constructor not tested
We are going to add tests on accessor-based load constructor in separate PR
most popular alignment for loading as a block will be overaligned<16>{} - oword. This is minimum requirement for block load. Not tested.
For overaligned we are using std::max_align_t
that means we will use synonymous with the largest scalar type, which is long double
on most platforms.
In the test we defined it here
Launch tests with this alignment type here
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.
For overaligned we are using std::max_align_t that means we will use synonymous with the largest scalar type, which is long double on most platforms.
we don't really care about any other platforms here, and long double is not a native type in Intel GPUs. So 16 is not driven by any type, but rather the "oword alignment" requirement for all block loads. In that sense, std::max_align_t gives wrong idea.
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.
so please extend the testcases with oword alignment.
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.
Alignment will be changed in one of next PRs
@kbobrovs All verifications has passed. Could you merge this PR? |
The test uses reference data and different alignment flags. Invokes simd constructors in different contexts with provided reference data and alignment flag.
It is expected for destination simd instance to store a bitwise same data as the reference one.