xla icon indicating copy to clipboard operation
xla copied to clipboard

A better python API for accessing profiled instructions

Open yliu120 opened this issue 1 year ago • 3 comments

A previous PR https://github.com/openxla/xla/pull/15170 adds a python binding for accessing the profiled instruction.

Actually the API previously added contains repeated logic with get_fdo_profile, which works very similar as the added get_instructions_profile. The only difference is that get_fdo_profile writes to a string.

In essense, we only need to parse the proto to Python objects, if users really want to do so.

This PR also adds a GPU test for the new API.

yliu120 avatar Jul 25 '24 07:07 yliu120