summaryrefslogtreecommitdiff
path: root/src/cpu/kvm/BaseKvmCPU.py
diff options
context:
space:
mode:
authorAndreas Sandberg <Andreas.Sandberg@ARM.com>2013-04-22 13:20:32 -0400
committerAndreas Sandberg <Andreas.Sandberg@ARM.com>2013-04-22 13:20:32 -0400
commitf8f66fa3df3ef5b4e30ee86d33a4e95476ba425a (patch)
treed3880f7bfda96783c2535d3e690026b6d6478efb /src/cpu/kvm/BaseKvmCPU.py
parentdc83d234254861f142854bdf523581101c3d5c8d (diff)
downloadgem5-f8f66fa3df3ef5b4e30ee86d33a4e95476ba425a.tar.xz
kvm: Add experimental support for a perf-based execution timer
Add support for using the CPU cycle counter instead of a normal POSIX timer to generate timed exits to gem5. This should, in theory, provide better resolution when requesting timer signals. The perf-based timer requires a fairly recent kernel since it requires a working PERF_EVENT_IOC_PERIOD ioctl. This ioctl has existed in the kernel for a long time, but it used to be completely broken due to an inverted match when the kernel copied things from user space. Additionally, the ioctl does not change the sample period correctly on all kernel versions which implement it. It is currently only known to work reliably on kernel version 3.7 and above on ARM.
Diffstat (limited to 'src/cpu/kvm/BaseKvmCPU.py')
-rw-r--r--src/cpu/kvm/BaseKvmCPU.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/cpu/kvm/BaseKvmCPU.py b/src/cpu/kvm/BaseKvmCPU.py
index aa7ad4c2c..a8356ac5b 100644
--- a/src/cpu/kvm/BaseKvmCPU.py
+++ b/src/cpu/kvm/BaseKvmCPU.py
@@ -69,4 +69,5 @@ class BaseKvmCPU(BaseCPU):
return True
kvmVM = Param.KvmVM(Parent.any, 'KVM VM (i.e., shared memory domain)')
+ usePerfOverflow = Param.Bool(False, "Use perf event overflow counters (EXPERIMENTAL)")
hostFactor = Param.Float(1.0, "Cycle scale factor")