Open lfmeadow opened 4 years ago
@lfmeadow there has been quite a bit progress in level-zero since you filed this. Did you ever got it working?
(I'm not involved with L0 development, just wondering.)
thanks @eero-t .
@lfmeadow please check. You can also see the ze_tracer implementation here https://github.com/intel/pti-gpu/tree/master/tools/ze_tracer for reference implementation and also tracing tests here, https://github.com/oneapi-src/level-zero-tests/tree/master/layer_tests/tracing which look similar to your reproducer.
I tried to write a simple tool that I can load with LD_PRELOAD (in the spirit of MPI tools for example, or OpenCL interposers). It seems to initialize OK but it doesn't get called. One problem is that I can't get to the device handles that the runtime initializes, however the level0 spec seems to imply that I should be able to open the device again. Code attached. Is this hopeless? Seems like there should be a way to have third-party tools invoked.
tool.cpp.txt