[code-reflection] Integrated: Minor logging changes for HAT ModuleOp support
Ruby Chen
duke at openjdk.org
Wed Aug 13 07:57:27 UTC 2025
On Tue, 12 Aug 2025 16:57:25 GMT, Ruby Chen <duke at openjdk.org> wrote:
> Add more descriptive logs for ModuleOp backend in HAT.
>
> To use the ModuleOp backend, pass `moduleOp` as an arg to the `hat/run.java` script when running a HAT example. For example, running the `mandel` example with the `ffi-opencl` backend and `moduleOp` enabled can be done with
>
> java @hat/run moduleOp ffi-opencl squares
>
> Adding `moduleOp` sets `-DmoduleOp=true` and passes it to the backend, which uses the flag to choose between the original `CallGraph` implementation and the new `moduleOp` implementation.
>
> `ModuleOpWrapper` now contains `createTransitiveInvokeModule()`, which creates a `ModuleOp` representing a call graph when given an entrypoint. This method is called in `KernelCallGraph` and `ComputeCallGraph` to generate their respective call graphs. The kernel and compute call graph classes also maintain a map of buffer accesses, along with structures storing other useful methods.
>
> The `C99FFIBackend`, `CudaBackend`, `MockBackend`, and `C99HATKernelBuilder` access call graphs structures differently depending on the `moduleOp` flag.
This pull request has now been integrated.
Changeset: ae9adb6f
Author: Ruby Chen <ruby.r.chen at gmail.com>
Committer: Gary Frost <gfrost at openjdk.org>
URL: https://git.openjdk.org/babylon/commit/ae9adb6f1c2be8d54a2d7a4dc3ee6d5e3352dac1
Stats: 13 lines in 5 files changed: 10 ins; 0 del; 3 mod
Minor logging changes for HAT ModuleOp support
-------------
PR: https://git.openjdk.org/babylon/pull/521
More information about the babylon-dev
mailing list