summaryrefslogtreecommitdiffstats
path: root/src/include/usr/hwas
diff options
context:
space:
mode:
authorMatthew Raybuck <matthew.raybuck@ibm.com>2019-02-26 14:24:31 -0600
committerDaniel M. Crowell <dcrowell@us.ibm.com>2019-03-01 09:02:52 -0600
commitd2899da82cb004acbcba439673dc1dfb02ae6fb6 (patch)
treebe96bb25c3135dcf2c274fb5e879a03067415a16 /src/include/usr/hwas
parent37e67698be56632c6505990dc3375136494d2a67 (diff)
downloadtalos-hostboot-d2899da82cb004acbcba439673dc1dfb02ae6fb6.tar.gz
talos-hostboot-d2899da82cb004acbcba439673dc1dfb02ae6fb6.zip
Improve performance of Partial Good logic
The function PARTIAL_GOOD::findRulesForTarget() would call masterProcChipTargetHandle() to figure out if a rule applied to a specific target based on the ATTR_MODEL of a system. Since finding the master proc that way is an expensive operation, findRulesForTarget() will now use an instance variable initialized once instead of querying for it repeatedly thereby increasing performance substantially. Change-Id: I6e9c01daf356fe21d76d920f5d3210717f5094c1 CQ:SW450113 Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/72620 Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Reviewed-by: Nicholas E. Bofferding <bofferdn@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com> Reviewed-by: Ilya Smirnov <ismirno@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Diffstat (limited to 'src/include/usr/hwas')
-rw-r--r--src/include/usr/hwas/common/pgLogic.H4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/include/usr/hwas/common/pgLogic.H b/src/include/usr/hwas/common/pgLogic.H
index cfe5d599f..1adf5509f 100644
--- a/src/include/usr/hwas/common/pgLogic.H
+++ b/src/include/usr/hwas/common/pgLogic.H
@@ -420,6 +420,7 @@ namespace PARTIAL_GOOD
struct PartialGoodRulesTable
{
+ PartialGoodRulesTable();
~PartialGoodRulesTable();
/**
@@ -444,6 +445,9 @@ namespace PARTIAL_GOOD
pgLogic_t &o_pgLogic) const;
private:
+
+ mutable TARGETING::TargetHandle_t iv_pMasterProc;
+
// A map that will hold all of the PG rules for all targets. If a target
// doesn't have a pg checking logic or special rules it will still be
// represented in this map because the generic algorithm will consider
OpenPOWER on IntegriCloud