From 3742cc9137b43d1e42957d8b440044fa9e95e907 Mon Sep 17 00:00:00 2001 From: Gabe Black Date: Tue, 19 Dec 2017 23:44:39 -0800 Subject: cpu: Add a pointer to a generic Nop StaticInst. This can be used whenever generic code needs a filler instruction that doesn't do anything. Change-Id: Ib245d3e880a951e229eb315a09ecc7c47e6ae00f Reviewed-on: https://gem5-review.googlesource.com/6823 Reviewed-by: Andreas Sandberg Maintainer: Andreas Sandberg --- src/cpu/static_inst.hh | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/cpu/static_inst.hh') diff --git a/src/cpu/static_inst.hh b/src/cpu/static_inst.hh index a4077e1d0..79f45d828 100644 --- a/src/cpu/static_inst.hh +++ b/src/cpu/static_inst.hh @@ -205,6 +205,9 @@ class StaticInst : public RefCounted, public StaticInstFlags /// Pointer to a statically allocated "null" instruction object. static StaticInstPtr nullStaticInstPtr; + /// Pointer to a statically allocated generic "nop" instruction object. + static StaticInstPtr nopStaticInstPtr; + /// The binary machine instruction. const ExtMachInst machInst; -- cgit v1.2.3