Skip to content

rocBLAS calls do not produce correct results #419

@evaleev

Description

@evaleev

HIP/ROCm support introduced in #418 is only minimally functional at the moment (but already sufficient to provide HIP support in https://github.com/devreal/ttg/tree/ttg-device-support-master-coro-with-stream-tasks) but when trying to use rocBLAS (via ICL's blaspp C++ API) it seems that nothing happens. Here's a simplified version of examples/device/device_task:

// copy data from arg.data() to result.data()
blas::copy(result.size(), arg.data(), 1, device_data(result.storage()), 1,
             queue);
hipStreamSynchronize(queue.stream());
TA_ASSERT(result.data()[0] == arg.data()[0]);

It fails in the assertion. Meanwhile

hipMemcpyAsync(result.data(),arg.data(),result.size()*sizeof(double),device::MemcpyDefault, stream);
hipStreamSynchronize(stream);
TA_ASSERT(result.data()[0] == arg.data()[0]);

succeeds.

Note that result.data() and arg.data() point to the unified memory (allocated via hipMallocManaged). So the only working hypothesis is that rocBLAS does not support operations on data in UM ...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions