Skip to content
This repository was archived by the owner on Mar 28, 2023. It is now read-only.

[SYCL][HIP] Adding basic atomics for HIP #1510

Merged
merged 3 commits into from
Jan 31, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/add.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
// See https://github.com/intel/llvm-test-suite/issues/867 for detailed status
// UNSUPPORTED: hip

// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-device-code-split=per_kernel -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: %GPU_RUN_PLACEHOLDER %t.out
// RUN: %CPU_RUN_PLACEHOLDER %t.out
Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/add_generic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend have had no support for the generic address space yet
// XFAIL: hip

#include "add.h"

int main() { add_test_all<access::address_space::generic_space>(); }
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/add_generic_local.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend have had no support for the generic address space yet.
// XFAIL: hip

#define TEST_GENERIC_IN_LOCAL 1

#include "add.h"
Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/add_generic_local_native_fp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend have had no support for the generic address space yet.
// XFAIL: hip

#define SYCL_USE_NATIVE_FP_ATOMICS
#define FP_TESTS_ONLY
#define TEST_GENERIC_IN_LOCAL 1
Expand Down
4 changes: 0 additions & 4 deletions SYCL/AtomicRef/add_generic_native_fp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend have had no support for the generic address space yet.
// HIP does not support native floating point atomics
// XFAIL: hip

#define SYCL_USE_NATIVE_FP_ATOMICS
#define FP_TESTS_ONLY

Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/add_local.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
// See https://github.com/intel/llvm-test-suite/issues/867 for detailed status
// UNSUPPORTED: hip

// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: %GPU_RUN_PLACEHOLDER %t.out
// RUN: %CPU_RUN_PLACEHOLDER %t.out
Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/add_local_native_fp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP does not support floating point atomics.
// XFAIL: hip

#define SYCL_USE_NATIVE_FP_ATOMICS
#define FP_TESTS_ONLY

Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/add_native_fp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// hip does not support native floating point atomics
// XFAIL: hip

#define SYCL_USE_NATIVE_FP_ATOMICS
#define FP_TESTS_ONLY

Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/and_generic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend have had no support for the generic address space yet
// XFAIL: hip

#include "and.h"

int main() { and_test_all<access::address_space::generic_space>(); }
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/and_generic_local.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend have had no support for the generic address space yet.
// XFAIL: hip

#define TEST_GENERIC_IN_LOCAL 1

#include "and.h"
Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/assignment_atomic64_generic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %GPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has had no support for the generic address space yet.
// XFAIL: hip

#include "assignment.h"
#include <iostream>
using namespace sycl;
Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/assignment_generic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %GPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has had no support for the generic address space yet
// XFAIL: hip

#include "assignment.h"
#include <iostream>
using namespace sycl;
Expand Down
4 changes: 2 additions & 2 deletions SYCL/AtomicRef/atomic_memory_order.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %GPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out
// L0, OpenCL, and HIP backends don't currently support
// L0, OpenCL backends don't currently support
// info::device::atomic_memory_order_capabilities
// UNSUPPORTED: level_zero || opencl || hip
// UNSUPPORTED: level_zero || opencl

// NOTE: General tests for atomic memory order capabilities.

Expand Down
2 changes: 1 addition & 1 deletion SYCL/AtomicRef/atomic_memory_order_acq_rel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
// RUN: %ACC_RUN_PLACEHOLDER %t.out
// L0, OpenCL, and HIP backends don't currently support
// info::device::atomic_memory_order_capabilities
// UNSUPPORTED: level_zero, opencl, hip
// UNSUPPORTED: level_zero, opencl

// NOTE: Tests fetch_add for acquire and release memory ordering.

Expand Down
2 changes: 1 addition & 1 deletion SYCL/AtomicRef/atomic_memory_order_seq_cst.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
// RUN: %ACC_RUN_PLACEHOLDER %t.out
// L0, OpenCL, and HIP backends don't currently support
// info::device::atomic_memory_order_capabilities
// UNSUPPORTED: level_zero, opencl, hip
// UNSUPPORTED: level_zero, opencl

#include "atomic_memory_order.h"
#include <iostream>
Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/compare_exchange_generic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has had no support for the generic address space yet
// XFAIL: hip

#include "compare_exchange.h"

int main() {
Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/compare_exchange_generic_local.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has had no support for the generic address space yet.
// XFAIL: hip

#define TEST_GENERIC_IN_LOCAL 1

#include "compare_exchange.h"
Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/exchange_generic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend have had no support for the generic address space yet
// XFAIL: hip

#include "exchange.h"

int main() { exchange_test_all<access::address_space::generic_space>(); }
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/exchange_generic_local.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend have had no support for the generic address space yet.
// XFAIL: hip

#define TEST_GENERIC_IN_LOCAL 1

#include "exchange.h"
Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/load_generic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has had no support for the generic address space yet
// XFAIL: hip

#include "load.h"

int main() { load_test_all<access::address_space::generic_space>(); }
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/load_generic_local.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has had no support for the generic address space yet.
// XFAIL: hip

#define TEST_GENERIC_IN_LOCAL 1

#include "load.h"
Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/max.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
// See https://github.com/intel/llvm-test-suite/issues/867 for detailed status
// UNSUPPORTED: hip

// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: %GPU_RUN_PLACEHOLDER %t.out
// RUN: %CPU_RUN_PLACEHOLDER %t.out
Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/max_generic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has had no support for the generic address space yet
// XFAIL: hip

#include "max.h"

int main() { max_test_all<access::address_space::generic_space>(); }
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/max_generic_local.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has had no support for the generic address space yet.
// XFAIL: hip

#define TEST_GENERIC_IN_LOCAL 1

#include "max.h"
Expand Down
4 changes: 0 additions & 4 deletions SYCL/AtomicRef/max_generic_local_native_fp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has had no support for the generic address space yet.
// HIP dees not support native floating point atomics
// XFAIL: hip

#define SYCL_USE_NATIVE_FP_ATOMICS
#define FP_TESTS_ONLY
#define TEST_GENERIC_IN_LOCAL 1
Expand Down
4 changes: 0 additions & 4 deletions SYCL/AtomicRef/max_generic_native_fp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has had no support for the generic address space yet.
// HIP does not support native floating point atomics
// XFAIL: hip

#define SYCL_USE_NATIVE_FP_ATOMICS
#define FP_TESTS_ONLY

Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/max_local.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP does not support floating point atomics.
// UNSUPPORTED: hip

#include "max.h"

int main() { max_test_all<access::address_space::local_space>(); }
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/max_local_native_fp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP does not support native floating point atomics
// XFAIL: hip

#define SYCL_USE_NATIVE_FP_ATOMICS
#define FP_TESTS_ONLY

Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/max_native_fp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP does not support native floating point atomics
// XFAIL: hip

#define SYCL_USE_NATIVE_FP_ATOMICS
#define FP_TESTS_ONLY

Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/min.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
// See https://github.com/intel/llvm-test-suite/issues/867 for detailed status
// UNSUPPORTED: hip

// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: %GPU_RUN_PLACEHOLDER %t.out
// RUN: %CPU_RUN_PLACEHOLDER %t.out
Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/min_generic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has had no support for the generic address space yet
// XFAIL: hip

#include "min.h"

int main() { min_test_all<access::address_space::generic_space>(); }
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/min_generic_local.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has had no support for the generic address space yet
// XFAIL: hip

#define TEST_GENERIC_IN_LOCAL 1

#include "min.h"
Expand Down
4 changes: 0 additions & 4 deletions SYCL/AtomicRef/min_generic_local_native_fp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has had no support for the generic address space yet.
// HIP does not support native floating point atomics
// XFAIL: hip

#define SYCL_USE_NATIVE_FP_ATOMICS
#define FP_TESTS_ONLY
#define TEST_GENERIC_IN_LOCAL 1
Expand Down
4 changes: 0 additions & 4 deletions SYCL/AtomicRef/min_generic_native_fp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has had no support for the generic address space yet.
// HIP does not support native floating point atomics
// XFAIL: hip

#define SYCL_USE_NATIVE_FP_ATOMICS
#define FP_TESTS_ONLY

Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/min_local.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
// See https://github.com/intel/llvm-test-suite/issues/867 for detailed status
// UNSUPPORTED: hip

// RUN: %clangxx -fsycl -fsycl-unnamed-lambda -fsycl-targets=%sycl_triple %s -o %t.out
// RUN: %GPU_RUN_PLACEHOLDER %t.out
// RUN: %CPU_RUN_PLACEHOLDER %t.out
Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/min_local_native_fp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP does not support native floating point atomics
// XFAIL: hip

#define SYCL_USE_NATIVE_FP_ATOMICS
#define FP_TESTS_ONLY

Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/min_native_fp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP does not support native floating point atomics
// XFAIL: hip

#define SYCL_USE_NATIVE_FP_ATOMICS
#define FP_TESTS_ONLY

Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/or_generic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend have had no support for the generic address space yet
// XFAIL: hip

#include "or.h"

int main() { or_test_all<access::address_space::generic_space>(); }
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/or_generic_local.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend have had no support for the generic address space yet.
// XFAIL: hip

#define TEST_GENERIC_IN_LOCAL 1

#include "or.h"
Expand Down
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/store_generic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has no support for the generic address space yet
// XFAIL: hip

#include "store.h"

int main() { store_test_all<access::address_space::generic_space>(); }
3 changes: 0 additions & 3 deletions SYCL/AtomicRef/store_generic_local.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@
// RUN: %CPU_RUN_PLACEHOLDER %t.out
// RUN: %ACC_RUN_PLACEHOLDER %t.out

// HIP backend has no support for the generic address space yet
// XFAIL: hip

#define TEST_GENERIC_IN_LOCAL 1

#include "store.h"
Expand Down
Loading