* cache.cxx (cache_component::read_line): Set the overall latency
for a cache line fill to the latency of the first downstream read,
not the last.
+2002-04-09 Ben Elliston <bje@redhat.com>
+
+ * cache.cxx (cache_component::read_line): Set the overall latency
+ for a cache line fill to the latency of the first downstream read,
+ not the last.
+
2001-12-27 Frank Ch. Eigler <fche@redhat.com>
* cache.cxx (CacheListTypes, CacheCreate): Support hw-cache-buffer-8
cache_component::read_line (cache_line& line)
{
bus::status st;
+ int overall_latency = 0;
host_int_4 base = acache.tag_to_addr (line.tag ());
for (host_int_4 offset = 0; offset < line_size; offset += 4)
{
sid::big_int_4 data;
st = downstream->read (base + offset, data);
+ // Latency for line fills is the latency of the first read
+ if (offset == 0)
+ overall_latency = st.latency;
if (st != bus::ok)
return st;
line.insert (offset, data);
line.unlock ();
line.clean ();
line.validate ();
+ st.latency = overall_latency;
return st;
}