Skip to content

[SYCL][ESIMD] Update ESIMD tests and add raw send support. #2482

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 4 commits into from
Oct 1, 2020

Conversation

kychendev
Copy link
Contributor

Update ESIMD tests and add raw send support.

@kychendev kychendev requested a review from a team as a code owner September 16, 2020 18:11
@kychendev kychendev requested a review from rbegam September 16, 2020 18:11
@kychendev kychendev force-pushed the private/kchen-esimd-patch1 branch from 597f92e to ced5805 Compare September 16, 2020 21:38
@romanovvlad
Copy link
Contributor

@kbobrovs @rbegam @DenisBakhvalov Could you please review?

@@ -643,6 +643,198 @@ media_block_store(AccessorTy acc, unsigned x, unsigned y, simd<T, m * n> vals) {
SYCL_EXTERNAL void slm_init(uint32_t size) {}

#endif

template <typename AccessorTy>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please document this API

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added comment.

}

/// \brief Raw sends load.
///
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please provide some comments what is "Raw send".
Does it model "send" instruction from https://01.org/sites/default/files/documentation/intel-gfx-prm-osrc-icllp-vol02a-commandreference-instructions_2.pdf? Maybe it makes sense to add a link then?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this API is used to implement the send messages. Added link to the open source document.

@@ -1838,7 +1838,7 @@ template <typename T0, typename T1, int SZ> struct esimd_apply_reduced_min {

template <typename T0, typename T1, int SZ,
template <typename RT, typename T, int N> class OpType>
T1 esimd_reduce_single(simd<T1, SZ> v) {
T0 esimd_reduce_single(simd<T1, SZ> v) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change does not seem to be related to raw_send.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right, as you can see from the change list, this patch includes other local changes including ESIMD tests update and a reduction test fix.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NIT: it's good to have proper and meaningful names for template types instead of indexed ones.

///
/// @execSize the execution size, which must be a compile time constant.
///
/// @sfid the shared function ID, which must be a compile time constant.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the API would be hard to use w/o some more info on what exDesc, msgDesc and sfid can be.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These correspond to the different send message encoding fields and are described in the open source reference document (added link in the comment). This API is intended for expert programmers who will need to read the reference manual in order to program the desired send message function.

/// a compile time constant (optional - default to 0).
///
/// @mask the predicate to specify enabled channels (optional - default to on).
///
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add info what this operation returns

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added comment.

/// \brief Raw sends load.
///
/// @msgDst the destination operand of send message.
///
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it is not clear how this parameter is to be used - it is passed by value, yet it is a destination.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's the old value of the destination operand - updated comment to clarify this.

@kychendev kychendev force-pushed the private/kchen-esimd-patch1 branch 2 times, most recently from 9d01503 to 2e742b0 Compare September 20, 2020 00:23
@kychendev kychendev force-pushed the private/kchen-esimd-patch1 branch from 2e742b0 to 64968c1 Compare September 20, 2020 00:33
@romanovvlad
Copy link
Contributor

@kbobrovs @rbegam Could you please re-review?

kbobrovs
kbobrovs previously approved these changes Sep 25, 2020
@kbobrovs
Copy link
Contributor

@kychendev, I took the liberty to commit few minor comments fixes to approve and speed up the process. Feel free to roll back if needed.

@kychendev
Copy link
Contributor Author

@kbobrovs, LGTM. However I see 4 checks failing now, which were passing before. Could you help double check if it's test env issue, or what needs to be changed?

@kbobrovs
Copy link
Contributor

@kychendev, sorry for typo - restarted the checks.

@kbobrovs
Copy link
Contributor

@intel/llvm-reviewers-runtime , ping. Please review/approve

@kbobrovs kbobrovs merged commit c25dcdf into intel:sycl Oct 1, 2020
alexbatashev pushed a commit to alexbatashev/llvm that referenced this pull request Oct 5, 2020
…_wrapper

* upstream/sycl: (1021 commits)
  [SYCL] Enable async_work_group_copy for scalar and vector bool types (intel#2582)
  [SYCL] Fix element type in handler::copy (intel#2590)
  [NFC][SYCL] Remove unnecessary if condition (intel#2585)
  [SYCL][NFC] Fix SYCL lit test execution on a system w/o GPU (intel#2584)
  [SYCL] Add error handling for non-uniform work group size case (intel#2569)
  [SYCL][ESIMD] Preserve undef initializer for globals in ESIMDLowerVecArg pass (intel#2555)
  [SYCL] Make Level-Zero events visible on the host (intel#2576)
  [Driver][SYCL][NFC] Add help information for -Wno-sycl-strict (intel#2570)
  [SYCL] Relax test to work in Win32 environment. (intel#2580)
  [SYCL] Emit suppressed warnings from SYCL headers (intel#2575)
  [SYCL][NFC] Cover more classes with ABI tests (intel#2577)
  [SYCL][ESIMD] Update ESIMD tests and add raw send support. (intel#2482)
  [SYCL] Make ESIMD on-device tests require linux,gpu,opencl. (intel#2560)
  [SYCL] Release commands with no dependencies after they're enqueued (intel#2492)
  [SYCL] Add multi-device and multi-platform support for SYCL_DEVICE_ALLOWLIST  (intel#2483)
  [SYCL] Try to enqueue host command depencies (intel#2561)
  [SYCL][ESIMD][NFC] Align namespace name with the spec guidelines (intel#2573)
  [SYCL][NFC] Add class layout ABI tests for memory objects (intel#2559)
  [SYCL] Change adress space for global variables (intel#2534)
  [NFC][SYCL] Fix comment. (intel#2541)
  ...
kbenzie added a commit to kbenzie/intel-llvm that referenced this pull request Feb 17, 2025
Get rid of extra-confounding test helper code
Chenyang-L pushed a commit that referenced this pull request Feb 18, 2025
Get rid of extra-confounding test helper code
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants