The tracer utility provides a log of Intel® Media Server Studio API calls and parameters by placing a shim between the main libmfx library and the application. It is a useful debugging tool.
To enable it, copy the original library to a new name and copy the tracer shim over the original library. This means that the shim will be executed instead. Run these steps as root
# cd /opt/intel/mediasdk/lib64 # cp libmfxhw64-p.so.1.16 libmfxhw64-p.so.1.16.REAL # cp ../tools/tracer/libmfx-tracer.so libmfxhw64-p.so.1.16
Then configure the tracer library. Run these steps as the user who will run the app to be traced.
$ cd /opt/intel/mediasdk/tools/tracer $ ./mfx-tracer-config core.type file core.file ~/mfxtracer.log
The last step is where it all comes together. Add a line to the ~/.mfxtracer file to point the shim to the real library:
$ cat ~/.mfxtracer [core] edit = 1 file = /home/user/mfxtracer.log type = file lib = /opt/intel/mediasdk/lib64/libmfxhw64-p.so.1.16.REAL
Now when you run a Media Server Studio application you will see a logfile with the application process #.
$ ls mfxtracer_*.log mfxtracer_22580.log
To return to normal operation and disable tracing, copy the "REAL" library back to the original name.
#cd /opt/intel/mediasdk/lib64 # cp libmfxhw64-p.so.1.16.REAL libmfxsw64-p.so.1.16 cp: overwrite ‘libmfxsw64-p.so.1.16’? y