I am attempting to run Alex Ionescu's WinIPT interface in a virtual machine, and having no success. (This is a Windows 10 Pro host running a Windows 10 VM and both are the 18363 update)
I have successfully built and run Intel's driver as well as Alex's toolchain on the host, and processed the trace with ptxed. I have also run Intel's cpuid utility, and verified that the INTEL_PROCESSOR_TRACE feature is active on the host. However, when I run the utility in a VM, it does not display the INTEL_PROCESSOR_TRACE flag, and indeed, the driver returns an error that the feature is not enabled.
I've attempted to run the same setup in several different virtual environments, including the latest versions of VirtualBox, VMWare Workstation, and Hyper-V.
When I enable the Hyper-V Platform, it silently disables the INTEL_PROCESSOR_TRACE feature on the host.
VMWare Workstation doesn't disable it directly, but when I tried to run my trace tool again on the host after starting the VM, it threw a BSoD, so I don't have high hopes there.
VirtualBox at least didn't take away any functionality, but even when I enabled the VT-x passthrough option, it still didn't have the flag set to enable IPT.
According to Microsoft, a process theoretically exists to enable this in Hyper-V, though I run into the aforementioned problem where it ends up disabled on my host:
Enabling performance monitoring components in a virtual machine
Has anyone gotten this to work? I'd prefer a solution in my current environment (Windows VM on Windows host), but I'd appreciate any insights using perf on Linux or any other approaches. I've also found some posts and questions from 2017 indicating IPT wasn't supported 'yet', but nothing within the past year or so. The technology and architecture seem to still be evolving, so really I'd like to know if anyone has had success in any form, as well as any insights on what to do or avoid.
Other resources:
Background on Intel Processor Tracing: Processor Tracing
Edited to add (2/10/2020)
Looking at the Microsoft instructions more carefully, they mention that you need "An Intel processor that supports IPT and the PT2GPA feature" to enable IPT in a virtual machine. According to Intel, the only architecture they have listed as supporting PT2GPA is Ice Lake.
The computer I'm currently working with is running an earlier microarchitectutre (Coffee Lake), which may explain the behavior I'm seeing where IPT is fine on the host. Can anyone confirm that they have it working on a more recent processor?