I'm looking for signed kernel mode drivers which will give user mode code access to the PMC and IBS facilities on recent AMD CPUs. I need this in order to run timing tests on software I've been writing.

I wrote kernel mode drivers to do these functions, running via the Service Manager. The drivers are unsigned, and I don't plan on spending the money to obtain a signing key.

I know how to disable DSE on Windows 10. However I don't really like the idea for security reasons. I use these drivers to run timing tests on software on my system. I'd like to use someone else's system for comparison, but I don't expect another person to disable DSE on their system and install my drivers.

So I would prefer to find an existing device driver for Windows 10 for the PMC and IBS facilities, which can simply be installed on my system and accessed as named devices.


PMC is the Performance Monitor Counters, each of which counts certain events. They can be read in user code with the RDPMC instruction (if enabled by some CR bit). Kernel code is required to associate a counter with a type of event, enable periodic interrupts, and write a value. If a counter interrupts, the PC will be a few instructions before or after the one that caused the event that overflowed the counter.

IBS is a periodic sampling of instructions and will interrupt the CPU. Unlike the PMC, the IBS will record the exact PC of the instruction that overflowed the counter, and will record some other information about that instruction. It requires kernel mode to handle the interrupts, collect the sample data, and eventually transfer one or more samples to a user mode client.