Skip to content

Commit 8dc10ea

Browse files
authored
Merge pull request #876 from JuliaGPU/gb/paralleltestitems
2 parents 480ab50 + b04509e commit 8dc10ea

61 files changed

Lines changed: 468 additions & 388 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

test/Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
1515
Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
1616
PrettyTables = "08abe8d2-0d0c-5749-adfa-8a2ac140af0d"
1717
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
18-
ReTestItems = "817f1d60-ba6b-4fd5-9520-3cf149f6a823"
18+
ParallelTestRunner = "d3525ed8-44d0-4b2c-a655-542cee43accc"
1919
SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf"
2020
SpecialFunctions = "276daf66-3868-5448-9aa4-cd146d93841b"
2121
StaticArrays = "90137ffa-7385-5640-81b9-e52037218182"

test/codegen/codegen.jl

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
using Test
2+
using AMDGPU
3+
using AMDGPU: Device, ROCArray, @roc
4+
using AMDGPU.Device: sync_workgroup
5+
using KernelAbstractions: @atomic
6+
17
@testset "Synchronization" begin
28
function synckern()
39
sync_workgroup()

test/core_tests.jl

Lines changed: 3 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,8 @@
1-
@testitem "core" setup=[TSCore] begin
2-
3-
import AMDGPU: @allowscalar
4-
1+
using Test
2+
using AMDGPU
53
using AMDGPU: HIP, Runtime, Device, Mem
6-
using KernelAbstractions: @atomic
74

8-
AMDGPU.allowscalar(false)
9-
10-
macro grab_output(ex, io=stdout)
11-
quote
12-
mktemp() do fname, fout
13-
ret = nothing
14-
open(fname, "w") do fout
15-
if $io == stdout
16-
redirect_stdout(fout) do
17-
ret = $(esc(ex))
18-
end
19-
elseif $io == stderr
20-
redirect_stderr(fout) do
21-
ret = $(esc(ex))
22-
end
23-
end
24-
end
25-
ret, read(fname, String)
26-
end
27-
end
28-
end
5+
@testset "core" begin
296

307
@testset "Functional" begin
318
@test AMDGPU.has_rocm_gpu() isa Bool
@@ -78,9 +55,4 @@ end
7855
@test d == deepcopy(d)
7956
end
8057

81-
include("codegen/codegen.jl")
82-
include("rocarray/base.jl")
83-
include("rocarray/broadcast.jl")
84-
include("tls.jl")
85-
8658
end

test/core_testsetup.jl

Lines changed: 0 additions & 12 deletions
This file was deleted.

test/device/array.jl

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
using Test
2+
using AMDGPU
3+
using AMDGPU: Device, ROCArray, @roc, rocconvert
4+
using AMDGPU.Device: workitemIdx, workgroupIdx, workgroupDim
5+
import LinearAlgebra
6+
17
@testset "ROCDeviceArray array interface" begin
28
x = ROCArray(zeros(Int, 1, 2, 3, 4))
39
xd = rocconvert(x)

test/device/exceptions.jl

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
using Test
2+
using AMDGPU
3+
using AMDGPU: Device, ROCArray, @roc
4+
using AMDGPU.Device: workitemIdx
5+
using StaticArrays
6+
17
@testset "Exceptions" begin
28
function oob_kernel(X)
39
X[0] = 1

test/device/execution_control.jl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
using Test
2+
using AMDGPU
3+
using AMDGPU: Device, ROCArray, @roc
4+
using AMDGPU.Device: workitemIdx
5+
16
@testset "Execution Control Intrinsics" begin
27
@testset "sendmsg/sendmsghalt/endpgm" begin
38
function exec_ctl_kernel()

test/device/hostcall.jl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
using Test
2+
using AMDGPU
3+
using AMDGPU: Device, ROCArray, @roc
4+
using AMDGPU.Device: HostCallHolder, hostcall!
5+
16
@testset "Hostcall" begin
27

38
@testset "Call: No return or arguments" begin

test/device/indexing.jl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
using Test
2+
using AMDGPU
3+
using AMDGPU: Device, ROCArray, @roc
4+
using AMDGPU.Device: workitemIdx, workgroupIdx, workgroupDim, gridItemDim, gridGroupDim
5+
16
@testset "Kernel Indexing" begin
27
function idx_kern(X)
38
X[1] = workitemIdx().x

test/device/launch.jl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
using Test
2+
using AMDGPU
3+
using AMDGPU: Device, Runtime, ROCArray, @roc, @ROCStaticLocalArray, HIPStream
4+
using AMDGPU.Device: workitemIdx, workgroupIdx, workgroupDim, gridItemDim, gridGroupDim
5+
16
@testset "Launch Options" begin
27
kernel() = nothing
38

0 commit comments

Comments
 (0)