RubyPrefetcher.py revision 13665:9c7fe3811b88
16167SN/A# Copyright (c) 2012 Mark D. Hill and David A. Wood 26167SN/A# All rights reserved. 36167SN/A# 410036SAli.Saidi@ARM.com# Redistribution and use in source and binary forms, with or without 58835SAli.Saidi@ARM.com# modification, are permitted provided that the following conditions are 610036SAli.Saidi@ARM.com# met: redistributions of source code must retain the above copyright 77892SN/A# notice, this list of conditions and the following disclaimer; 87892SN/A# redistributions in binary form must reproduce the above copyright 97892SN/A# notice, this list of conditions and the following disclaimer in the 106167SN/A# documentation and/or other materials provided with the distribution; 116167SN/A# neither the name of the copyright holders nor the names of its 126167SN/A# contributors may be used to endorse or promote products derived from 139864Snilay@cs.wisc.edu# this software without specific prior written permission. 148835SAli.Saidi@ARM.com# 159864Snilay@cs.wisc.edu# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 169864Snilay@cs.wisc.edu# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 1710036SAli.Saidi@ARM.com# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 188835SAli.Saidi@ARM.com# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 198835SAli.Saidi@ARM.com# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 208835SAli.Saidi@ARM.com# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 2110063Snilay@cs.wisc.edu# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 227077SN/A# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 239864Snilay@cs.wisc.edu# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 248673SN/A# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 258721SN/A# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 268835SAli.Saidi@ARM.com# 278835SAli.Saidi@ARM.com# Authors: Nilay Vaish 287935SN/A 297935SN/Afrom m5.SimObject import SimObject 307935SN/Afrom m5.params import * 317935SN/Afrom m5.proxy import * 327935SN/A 337935SN/Afrom m5.objects.System import System 347935SN/A 358983Snate@binkert.orgclass Prefetcher(SimObject): 366167SN/A type = 'Prefetcher' 379864Snilay@cs.wisc.edu cxx_class = 'Prefetcher' 389864Snilay@cs.wisc.edu cxx_header = "mem/ruby/structures/Prefetcher.hh" 399864Snilay@cs.wisc.edu 4010036SAli.Saidi@ARM.com num_streams = Param.UInt32(4, 419864Snilay@cs.wisc.edu "Number of prefetch streams to be allocated") 429864Snilay@cs.wisc.edu pf_per_stream = Param.UInt32(1, "Number of prefetches per stream") 436167SN/A unit_filter = Param.UInt32(8, 446167SN/A "Number of entries in the unit filter array") 459864Snilay@cs.wisc.edu nonunit_filter = Param.UInt32(8, 4610063Snilay@cs.wisc.edu "Number of entries in the non-unit filter array") 476167SN/A train_misses = Param.UInt32(4, "") 489864Snilay@cs.wisc.edu num_startup_pfs = Param.UInt32(1, "") 496167SN/A cross_page = Param.Bool(False, """True if prefetched address can be on a 506167SN/A page different from the observed address""") 518835SAli.Saidi@ARM.com sys = Param.System(Parent.any, "System this prefetcher belongs to") 526167SN/A