A QEMU based framework for instrumenting x86 programs from Python