Skip to content

jax.debug.print statement support for PJRT devices #29138

@tapspatel

Description

@tapspatel

When jit compiling graphs from jax that have jax.debug.print(), the following stablehlo custom call gets inserted into the graph

stablehlo.custom_call @xla_ffi_python_cpu_callback

However, this pass is not available in PJRT devices due to PJRT not linking against openxla (see "Toolchain Independent" from https://opensource.googleblog.com/2023/05/pjrt-simplifying-ml-hardware-and-framework-integration.html).

jax.debug.print() is extremely useful for any model developer, and it would be extremely beneficial to have this enabled for PJRT devices.

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