From: Gabor Dozsa Date: Wed, 23 Jan 2019 15:15:16 +0000 (+0000) Subject: cpu: Disable MinorCPU value forwarding with write strobes X-Git-Tag: v19.0.0.0~152 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=bd32682445150c234f83872e135bc959247a4065;p=gem5.git cpu: Disable MinorCPU value forwarding with write strobes Change-Id: I7cb50b80b70fcf43ab23eb9e7333d16328993fe1 Signed-off-by: Gabor Dozsa Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/19173 Reviewed-by: Jason Lowe-Power Maintainer: Jason Lowe-Power Tested-by: kokoro --- diff --git a/src/cpu/minor/lsq.cc b/src/cpu/minor/lsq.cc index dea776c9e..8bbda030c 100644 --- a/src/cpu/minor/lsq.cc +++ b/src/cpu/minor/lsq.cc @@ -142,10 +142,18 @@ LSQ::LSQRequest::containsAddrRangeOf( LSQ::AddrRangeCoverage LSQ::LSQRequest::containsAddrRangeOf(LSQRequestPtr other_request) { - return containsAddrRangeOf(request->getPaddr(), request->getSize(), + AddrRangeCoverage ret = containsAddrRangeOf( + request->getPaddr(), request->getSize(), other_request->request->getPaddr(), other_request->request->getSize()); + /* If there is a strobe mask then store data forwarding might not be + * correct. Instead of checking enablemant of every byte we just fall back + * to PartialAddrRangeCoverage to prohibit store data forwarding */ + if (ret == FullAddrRangeCoverage && request->isMasked()) + ret = PartialAddrRangeCoverage; + return ret; } + bool LSQ::LSQRequest::isBarrier() {