Skip to content

OpenCL compiler does not support fract() #101

Closed
@gerd-sk

Description

@gerd-sk

If I try to compile an OpenCL kernel that calls the fract() function, I get the following error:

ld.lld: error: undefined hidden symbol: fract(float, float AS0*)

referenced by fract.cl:7 (/home/EU/despalig/Documents/RadeonGPUAnalyzer/projects/221026-150246/Clone0/fract.cl:7)
/tmp/despalig/fract-220ba7.o:(src_MyKernel)
referenced by fract.cl:7 (/home/EU/despalig/Documents/RadeonGPUAnalyzer/projects/221026-150246/Clone0/fract.cl:7)
/tmp/despalig/fract-220ba7.o:(src_MyKernel)
fract.cl.txt

The kernel code is:
__kernel void src_MyKernel(__global float *out, __global const float *in)
{
int index = get_global_linear_id();
float dummy;

out[index] = fract(in[index], &dummy);

}

I have used RGA shipped with RadeonDeveloperToolSuite-2022-08-01-115. Application version: 2.6.2.38 (07/25/2022).
I am running this on Ubuntu 20.04 Linux.

This kernel runs fine on my machine. Offline analysis with RGA fails. I suspect the OpenCL libraries shipped with RGA are obsolete.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions