nanoBench | running small microbenchmarks on recent Intel | Performance Testing library
kandi X-RAY | nanoBench Summary
kandi X-RAY | nanoBench Summary
nanoBench is a Linux-based tool for running small microbenchmarks on recent Intel and AMD x86 CPUs. The microbenchmarks are evaluated using hardware performance counters. The reading of the performance counters is implemented in a way that incurs only minimal overhead. There are two variants of the tool: A user-space implementation and a kernel module. The kernel module makes it possible to benchmark privileged instructions, to use uncore performance counters, and it can allow for more accurate measurement results as it disables interrupts and preemptions during measurements. The disadvantage of the kernel module compared to the user-space variant is that it is quite risky to allow arbitrary code to be executed in kernel space. Therefore, the kernel module should not be used on a production system. nanoBench is used for running the microbenchmarks for obtaining the latency, throughput, and port usage data that is available on uops.info.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Run the program .
- Returns a list of LatConfigLists .
- Get the latency of the given instruction .
- Get the list of divor configs .
- Get the throughput of each instruction .
- Return all instructions that are not supported .
- Get information about a CPU
- Construct an instruction instance from an instruction node .
- Get TPConfig for division .
- Extract the basic latencies from each instruction .
nanoBench Key Features
nanoBench Examples and Code Snippets
Community Discussions
Trending Discussions on nanoBench
QUESTION
On recent Intel CPUs, the POP
instruction usually has a throughput of 2 instructions per cycle. However, when using register R12
(or RSP
, which has the same encoding except for the prefix), the throughput drops to 1 per cycle if the instructions go through the legacy decoders (the throughput stays at around 2 per cycle if the µops come from the DSB).
This can be reproduced using nanoBench as follows:
...ANSWER
Answered 2020-Nov-12 at 01:52Workaround: the pop r/m64
encoding of pop r12
doesn't have this decode penalty. (Thanks @Andreas for testing my guess.)
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install nanoBench
You can use nanoBench like any standard Python library. You will need to make sure that you have a development environment consisting of a Python distribution including header files, a compiler, pip, and git installed. Make sure that your pip, setuptools, and wheel are up to date. When using pip it is generally recommended to install packages in a virtual environment to avoid changes to the system.
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page