Skip to content
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

[Modes] DPC++ backend #494

Merged
merged 116 commits into from
Sep 9, 2021
Merged

[Modes] DPC++ backend #494

merged 116 commits into from
Sep 9, 2021

Conversation

kris-rowe
Copy link
Member

Description

This PR implements a new OCCA backend using Data Parallel C++ (DPC++).

Highlights

  • Using freely available DPC++ implementations, this backend can be run on CPUs, GPUs, and FPGAs.
  • Memory allocation/deallocation is handled using the DPC++ USM functions, which are now part of the SYCL 2020 standard.
  • OKL kernels are translated to lambda functions for transparency and performance purposes.
  • @outer and @inner loop indices are mapped to work-group IDs and work-items, respectively — similar to OpenCL.

Building

Currently only building with CMake is supported.

Coverage

During development the Intel oneAPI DPC++ compiler was used. Intel GPU hardware was used for testing, including the JLSE Aurora testbeds at ALCF. In the near future testing will be expanded to included other DPC++ implementations and other vendor hardware.

Acknowledgements

This work was completed jointly by ALCF and Intel, with contributions from

  • Anoop Madhusoodhanan Prabha (Intel)
  • Cedric Andreolli (Intel)
  • Kris Rowe (ALCF)
  • Phillipe Thierry (Intel)
  • Saumil Patel (ALCF)

subarnar and others added 30 commits August 6, 2020 22:40
…that we can discuss

don't know how it reflects to our implementation.

I also solved all the problems for compiling this file in many other files.

The file memory.cpp can now be compiled without error with dpcpp compiler.
Revert "It compiles now :) but won't work before we find a way to enqueue arguments"

This reverts commit ecfc203.
…SYCL kernel doesn't accept virtual functions."

This reverts commit 26e7398.
…a way to enqueue arguments""

This reverts commit 8e2aacd.
This reverts commit 0d4e35b.
@codecov
Copy link

codecov bot commented Sep 8, 2021

Codecov Report

Merging #494 (6f26f6e) into main (e39975c) will increase coverage by 0.56%.
The diff coverage is 75.00%.

❗ Current head 6f26f6e differs from pull request most recent head e9bdde7. Consider uploading reports for the commit e9bdde7 to get more accurate results
Impacted file tree graph

@@            Coverage Diff             @@
##             main     #494      +/-   ##
==========================================
+ Coverage   75.68%   76.24%   +0.56%     
==========================================
  Files         253      261       +8     
  Lines       19109    19399     +290     
==========================================
+ Hits        14462    14791     +329     
+ Misses       4647     4608      -39     
Impacted Files Coverage Δ
src/occa/internal/bin/occa.cpp 37.20% <0.00%> (-0.78%) ⬇️
src/occa/internal/lang/expr/dpcppAtomicNode.hpp 0.00% <0.00%> (ø)
src/occa/internal/lang/expr/exprNode.cpp 80.82% <ø> (ø)
src/occa/internal/lang/modes/withLauncher.cpp 96.34% <ø> (ø)
src/occa/internal/lang/printer.hpp 100.00% <ø> (ø)
src/occa/internal/lang/type/pointer.cpp 47.82% <ø> (-0.45%) ⬇️
src/occa/internal/lang/type/type.cpp 79.16% <ø> (+4.16%) ⬆️
src/occa/internal/lang/type/lambda.cpp 55.35% <55.35%> (ø)
src/occa/internal/lang/expr/lambdaNode.cpp 70.00% <70.00%> (ø)
src/occa/internal/lang/modes/dpcpp.cpp 79.47% <79.47%> (ø)
... and 33 more

@tcew
Copy link
Collaborator

tcew commented Sep 8, 2021

The MacOS gcc-9 test fails curiously with

./tests/run_examples: line 108: cd: /Users/runner/work/occa/occa/examples/c/03_inline_okl: No such file or directory

I am not sure what is out of sync here.

kris-rowe and others added 2 commits September 8, 2021 16:31
Co-authored-by: David Medina <dmed256@gmail.com>
@kris-rowe kris-rowe merged commit 182f3d7 into libocca:main Sep 9, 2021
@kris-rowe kris-rowe mentioned this pull request Sep 9, 2021
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.

5 participants