From 146bbebeab7c18d8c415dfe73d1114777dcda9ca Mon Sep 17 00:00:00 2001 From: CompatHelper Julia Date: Thu, 14 Mar 2024 20:55:26 +0000 Subject: [PATCH] CompatHelper: bump compat for GPUCompiler to 0.25 --- Project.toml | 2 +- src/compiler/compiler.jl | 10 +--------- test/compiler.jl | 4 ++-- 3 files changed, 4 insertions(+), 12 deletions(-) diff --git a/Project.toml b/Project.toml index 79608d3..0689cb8 100644 --- a/Project.toml +++ b/Project.toml @@ -20,7 +20,7 @@ libcxxwrap_julia_jll = "3eaa8342-bff7-56a5-9981-c04077f7cee7" [compat] Clang = "0.14, 0.17.4" CxxWrap = "0.14" -GPUCompiler = "0.21.4" +GPUCompiler = "0.25" JSON = "0.21.4" LLVM = "6" LinearAlgebra = "1" diff --git a/src/compiler/compiler.jl b/src/compiler/compiler.jl index 75f65fc..9619da9 100644 --- a/src/compiler/compiler.jl +++ b/src/compiler/compiler.jl @@ -36,15 +36,7 @@ macro device_override(ex) ex = eval(ex) error() end - code = quote - $GPUCompiler.@override($method_table, $ex) - end - if isdefined(Base.Experimental, Symbol("@overlay")) - return esc(code) - else - push!(overrides, code) - return - end + return esc(:( Base.Experimental.@overlay($method_table, $ex) )) end macro device_function(ex) diff --git a/test/compiler.jl b/test/compiler.jl index e9de74b..2823b5f 100644 --- a/test/compiler.jl +++ b/test/compiler.jl @@ -58,8 +58,8 @@ function test_compiler_program(device) end # Test some invalid kernels - @test_throws KernelError @codelet graph f_access_out_scalar(x::VertexScalar{Float32, Out}) = @ipushow x[] - @test_throws KernelError @codelet graph f_set_in_scalar(x::VertexScalar{Float32, In}) = x[] = 3.14f0 + @test_throws InvalidIRError @codelet graph f_access_out_scalar(x::VertexScalar{Float32, Out}) = @ipushow x[] + @test_throws InvalidIRError @codelet graph f_set_in_scalar(x::VertexScalar{Float32, In}) = x[] = 3.14f0 # This function would contain a reference to a literal pointer, likely an # invalid memory address on the IPU.