From 340a16ac1c5731d4def3bfea98b9ed0e53b92d57 Mon Sep 17 00:00:00 2001 From: Gabe Black Date: Sun, 30 Aug 2020 01:31:20 -0700 Subject: [PATCH] cpu: Get rid of the IsThreadSync StaticInst flag. This flag was never set and only checked in one place. If it was set, it would have triggered a panic there. Change-Id: I934a0346837c66bae8ce06f50027003bfd47083d Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/33737 Reviewed-by: Jason Lowe-Power Reviewed-by: Andreas Sandberg Maintainer: Andreas Sandberg Tested-by: kokoro --- src/cpu/StaticInstFlags.py | 2 -- src/cpu/base_dyn_inst.hh | 1 - src/cpu/o3/commit_impl.hh | 5 ----- src/cpu/static_inst.hh | 1 - 4 files changed, 9 deletions(-) diff --git a/src/cpu/StaticInstFlags.py b/src/cpu/StaticInstFlags.py index 5b8507b28..acaa7bfca 100644 --- a/src/cpu/StaticInstFlags.py +++ b/src/cpu/StaticInstFlags.py @@ -78,8 +78,6 @@ class StaticInstFlags(Enum): 'IsCall', # Subroutine call. 'IsReturn', # Subroutine return. - 'IsThreadSync', # Thread synchronization operation. - 'IsSerializing', # Serializes pipeline: won't execute until all # older instructions have committed. 'IsSerializeBefore', diff --git a/src/cpu/base_dyn_inst.hh b/src/cpu/base_dyn_inst.hh index 60ca592cc..bfe0492f8 100644 --- a/src/cpu/base_dyn_inst.hh +++ b/src/cpu/base_dyn_inst.hh @@ -541,7 +541,6 @@ class BaseDynInst : public ExecContext, public RefCounted bool isIndirectCtrl() const { return staticInst->isIndirectCtrl(); } bool isCondCtrl() const { return staticInst->isCondCtrl(); } bool isUncondCtrl() const { return staticInst->isUncondCtrl(); } - bool isThreadSync() const { return staticInst->isThreadSync(); } bool isSerializing() const { return staticInst->isSerializing(); } bool isSerializeBefore() const diff --git a/src/cpu/o3/commit_impl.hh b/src/cpu/o3/commit_impl.hh index 75d065fd5..0d5cbe5db 100644 --- a/src/cpu/o3/commit_impl.hh +++ b/src/cpu/o3/commit_impl.hh @@ -1233,11 +1233,6 @@ DefaultCommit::commitHead(const DynInstPtr &head_inst, unsigned inst_num) return false; } - if (head_inst->isThreadSync()) { - // Not handled for now. - panic("Thread sync instructions are not handled yet.\n"); - } - // Check if the instruction caused a fault. If so, trap. Fault inst_fault = head_inst->getFault(); diff --git a/src/cpu/static_inst.hh b/src/cpu/static_inst.hh index 1a0e42c36..e536b8412 100644 --- a/src/cpu/static_inst.hh +++ b/src/cpu/static_inst.hh @@ -180,7 +180,6 @@ class StaticInst : public RefCounted, public StaticInstFlags bool isCondCtrl() const { return flags[IsCondControl]; } bool isUncondCtrl() const { return flags[IsUncondControl]; } - bool isThreadSync() const { return flags[IsThreadSync]; } bool isSerializing() const { return flags[IsSerializing] || flags[IsSerializeBefore] || flags[IsSerializeAfter]; } -- 2.30.2