Some minor errors observed in while experimenting with a sample

nadeesh t v nadeeshtv at gmail.com
Tue Dec 16 23:12:21 UTC 2025


Hi Gary,
I tried with the latest build and I can reproduce reported issue *3* with
the TestArrays
```

*diff --git a/hat/tests/src/main/java/hat/test/TestArrays.java
b/hat/tests/src/main/java/hat/test/TestArrays.java*

*index b5aed9f85da..3dccbaabf8c 100644*

*--- a/hat/tests/src/main/java/hat/test/TestArrays.java*

*+++ b/hat/tests/src/main/java/hat/test/TestArrays.java*

@@ -42,7 +42,7 @@



 public class TestArrays {



-    @Reflect

+    //@Reflect

     public static int squareit(int v) {

         return  v * v;


```
With the following command `java -cp hat/job.jar hat.java test ffi-opencl
hat.test.TestArrays`
```

HAT Engine Testing Framework

Testing Backend: hat.backend.ffi.OpenCLBackend

UNSUPPORTED (log once): buildComputeProgram: cl2Metal failed

buildStatus =failed

logLen = 186 log  = program_source:70:37: error: implicit declaration of
function 'squareit' is invalid in OpenCL

        array->array[(long)HAT_GIX]=squareit(value);

                                    ^


what?hat.test.TestArrays::squareKernel(hat.KernelContext,
hat.buffer.S32Array):void java.lang.IllegalStateException: OpenCL program
failed to compilejava.lang.IllegalStateException: OpenCL program failed to
compile

at
hat.backend.ffi.OpenCLBackend.lambda$dispatchKernel$0(OpenCLBackend.java:58)

at java.base/java.util.HashMap.computeIfAbsent(HashMap.java:1229)

at hat.backend.ffi.OpenCLBackend.dispatchKernel(OpenCLBackend.java:47)

at
hat.ComputeContext.dispatchKernelWithComputeRange(ComputeContext.java:133)

at hat.ComputeContext.dispatchKernel(ComputeContext.java:111)
```
Regards,
Nadeesh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/babylon-dev/attachments/20251217/63b54e54/attachment-0001.htm>


More information about the babylon-dev mailing list