Skip to content

Metal fails silently when Atomix is used with an unsupported operation #54

@efaulhaber

Description

@efaulhaber

MWE:

using KernelAbstractions, Atomix, Metal

@kernel function mykernel(result)
    i = @index(Global)
    Atomix.@atomic result[i] = 1
end

result = Metal.zeros(Int, 1)
mykernel(MetalBackend())(result, ndrange=1)
result

The result is

1-element MtlVector{Int64, Metal.PrivateStorage}:
 0

without any errors.

On CUDA, this error is thrown:
https://github.com/JuliaConcurrent/Atomix.jl/blob/main/ext/AtomixCUDAExt.jl#L13-L15

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions