From e3878336134c19230759ef9d22ee2732ae5f39ba Mon Sep 17 00:00:00 2001 From: Gabe Black Date: Fri, 13 Mar 2020 03:44:43 -0700 Subject: [PATCH] arch,kern: Rename some function events to have better names. Rename many of the Event classes to have more succinct or consistent names, and fix various style issues. Change-Id: Ib322da31d81e7a245a00d21786c2aa417c9f2cde Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/26703 Reviewed-by: Gabe Black Maintainer: Gabe Black Tested-by: kokoro --- src/arch/arm/freebsd/fs_workload.cc | 10 ++--- src/arch/arm/freebsd/fs_workload.hh | 6 +-- src/arch/arm/linux/fs_workload.cc | 56 +++++++++++++------------ src/arch/arm/linux/fs_workload.hh | 26 ++++++------ src/arch/mips/linux/system.cc | 2 +- src/arch/mips/linux/system.hh | 16 ++++---- src/kern/freebsd/events.cc | 9 ++--- src/kern/freebsd/events.hh | 12 +++--- src/kern/linux/events.cc | 7 ++-- src/kern/linux/events.hh | 63 ++++++++++++++++------------- src/kern/system_events.hh | 10 ++--- 11 files changed, 111 insertions(+), 106 deletions(-) diff --git a/src/arch/arm/freebsd/fs_workload.cc b/src/arch/arm/freebsd/fs_workload.cc index 1792273d0..33e012642 100644 --- a/src/arch/arm/freebsd/fs_workload.cc +++ b/src/arch/arm/freebsd/fs_workload.cc @@ -56,20 +56,20 @@ FsFreebsd::FsFreebsd(Params *p) : ArmISA::FsWorkload(p), enableContextSwitchStatsDump(p->enable_context_switch_stats_dump) { if (p->panic_on_panic) { - kernelPanicEvent = addKernelFuncEventOrPanic( + kernelPanic = addKernelFuncEventOrPanic( "panic", "Kernel panic in simulated kernel"); } else { #ifndef NDEBUG - kernelPanicEvent = addKernelFuncEventOrPanic("panic"); + kernelPanic = addKernelFuncEventOrPanic("panic"); #endif } if (p->panic_on_oops) { - kernelOopsEvent = addKernelFuncEventOrPanic( + kernelOops = addKernelFuncEventOrPanic( "oops_exit", "Kernel oops in guest"); } - uDelaySkipEvent = addKernelFuncEvent>( + skipUDelay = addKernelFuncEvent>( "DELAY", "DELAY", 1000, 0); } @@ -123,7 +123,7 @@ FsFreebsd::initState() FsFreebsd::~FsFreebsd() { - delete uDelaySkipEvent; + delete skipUDelay; } } // namespace ArmISA diff --git a/src/arch/arm/freebsd/fs_workload.hh b/src/arch/arm/freebsd/fs_workload.hh index 0e767a50c..b7d8e26e4 100644 --- a/src/arch/arm/freebsd/fs_workload.hh +++ b/src/arch/arm/freebsd/fs_workload.hh @@ -78,17 +78,17 @@ class FsFreebsd : public ArmISA::FsWorkload private: /** Event to halt the simulator if the kernel calls panic() */ - PCEvent *kernelPanicEvent = nullptr; + PCEvent *kernelPanic = nullptr; /** Event to halt the simulator if the kernel calls oopses */ - PCEvent *kernelOopsEvent = nullptr; + PCEvent *kernelOops = nullptr; /** * PC based event to skip udelay(