From 341dbf266258dcbdb1e5e9f09c244b8ac271faaf Mon Sep 17 00:00:00 2001 From: Andreas Hansson Date: Sat, 27 Sep 2014 09:08:36 -0400 Subject: arch: Use const StaticInstPtr references where possible This patch optimises the passing of StaticInstPtr by avoiding copying the reference-counting pointer. This avoids first incrementing and then decrementing the reference-counting pointer. --- src/cpu/minor/func_unit.hh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/cpu/minor/func_unit.hh') diff --git a/src/cpu/minor/func_unit.hh b/src/cpu/minor/func_unit.hh index 34da579b6..d99e527e8 100644 --- a/src/cpu/minor/func_unit.hh +++ b/src/cpu/minor/func_unit.hh @@ -257,7 +257,7 @@ class FUPipeline : public FUPipelineBase, public FuncUnit /** Find the extra timing information for this instruction. Returns * NULL if no decode info. is found */ - MinorFUTiming *findTiming(StaticInstPtr inst); + MinorFUTiming *findTiming(const StaticInstPtr &inst); /** Step the pipeline. Allow multiple steps? */ void advance(); -- cgit v1.2.3