SeriesRequestGenerator.hh revision 7553
12SN/A/*
29448SAndreas.Sandberg@ARM.com * Copyright (c) 1999-2008 Mark D. Hill and David A. Wood
39920Syasuko.eckert@amd.com * All rights reserved.
47338SAli.Saidi@ARM.com *
57338SAli.Saidi@ARM.com * Redistribution and use in source and binary forms, with or without
67338SAli.Saidi@ARM.com * modification, are permitted provided that the following conditions are
77338SAli.Saidi@ARM.com * met: redistributions of source code must retain the above copyright
87338SAli.Saidi@ARM.com * notice, this list of conditions and the following disclaimer;
97338SAli.Saidi@ARM.com * redistributions in binary form must reproduce the above copyright
107338SAli.Saidi@ARM.com * notice, this list of conditions and the following disclaimer in the
117338SAli.Saidi@ARM.com * documentation and/or other materials provided with the distribution;
127338SAli.Saidi@ARM.com * neither the name of the copyright holders nor the names of its
137338SAli.Saidi@ARM.com * contributors may be used to endorse or promote products derived from
147338SAli.Saidi@ARM.com * this software without specific prior written permission.
151762SN/A *
162SN/A * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
172SN/A * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
182SN/A * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
192SN/A * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
202SN/A * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
212SN/A * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
222SN/A * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
232SN/A * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
242SN/A * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
252SN/A * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
262SN/A * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
272SN/A */
282SN/A
292SN/A//
302SN/A// This Deterministic Generator generates GETX requests for all nodes in the
312SN/A// system.  The GETX requests are generated one at a time in round-robin fashion
322SN/A// 0...1...2...etc.
332SN/A//
342SN/A
352SN/A#ifndef __CPU_DIRECTEDTEST_SERIESREQUESTGENERATOR_HH__
362SN/A#define __CPU_DIRECTEDTEST_SERIESREQUESTGENERATOR_HH__
372SN/A
382SN/A#include "cpu/directedtest/RubyDirectedTester.hh"
392SN/A#include "cpu/directedtest/DirectedGenerator.hh"
402665Ssaidi@eecs.umich.edu#include "mem/protocol/SeriesRequestGeneratorStatus.hh"
412665Ssaidi@eecs.umich.edu#include "params/SeriesRequestGenerator.hh"
422SN/A
432SN/Aclass SeriesRequestGenerator : public DirectedGenerator
448779Sgblack@eecs.umich.edu{
458779Sgblack@eecs.umich.edu  public:
468779Sgblack@eecs.umich.edu    typedef SeriesRequestGeneratorParams Params;
472439SN/A    SeriesRequestGenerator(const Params *p);
488779Sgblack@eecs.umich.edu
498229Snate@binkert.org    ~SeriesRequestGenerator();
506216Snate@binkert.org
51146SN/A    bool initiate();
52146SN/A    void performCallback(uint proc, Addr address);
53146SN/A
54146SN/A  private:
55146SN/A    SeriesRequestGeneratorStatus m_status;
566216Snate@binkert.org    Addr m_address;
576658Snate@binkert.org    uint m_active_node;
588229Snate@binkert.org    uint m_addr_increment_size;
591717SN/A    bool m_issue_writes;
608887Sgeoffrey.blake@arm.com};
618887Sgeoffrey.blake@arm.com
62146SN/A#endif //__CPU_DIRECTEDTEST_SERIESREQUESTGENERATOR_HH__
6310061Sandreas@sandberg.pp.se
641977SN/A