mem: Use FromCache attribute in snoop filter allocation
authorAndreas Hansson <andreas.hansson@arm.com>
Fri, 12 Aug 2016 13:11:45 +0000 (14:11 +0100)
committerAndreas Hansson <andreas.hansson@arm.com>
Fri, 12 Aug 2016 13:11:45 +0000 (14:11 +0100)
commita23e914519de16061340db62d7a5dfc2cc7d027e
tree6e8edfa3f1893a64331823947a1ade57bc5eb102
parent721efa4d094197404a0df0d2bae6c27b4402c0ef
mem: Use FromCache attribute in snoop filter allocation

This patch improves the snoop filter allocation decisions by not only
looking at whether a port is snooping or not, but also if the packet
actually came from a cache. The issue with only looking at isSnooping
is that the CPU ports, for example, are snooping, but not actually
caching. Previously we ended up incorrectly allocating entries in
systems without caches (such as the atomic and timing quick
regressions). Eventually these misguided allocations caused the snoop
filter to panic due to an excessive size.

On the request path we now include the fromCache check on the packet
itself, and for responses we check if we actually have a snoop-filter
entry.

Change-Id: Idd2dbc4f00c7e07d331e9a02658aee30d0350d7e
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Reviewed-by: Stephan Diestelhorst <stephan.diestelhorst@arm.com>
Reviewed-by: Tony Gutierrez <anthony.gutierrez@amd.com>
src/mem/snoop_filter.cc