16145SN/A/* 26386SN/A * Copyright (c) 1999-2008 Mark D. Hill and David A. Wood 37553SN/A * Copyright (c) 2009-2010 Advanced Micro Devices, Inc. 46386SN/A * All rights reserved. 56386SN/A * 66386SN/A * Redistribution and use in source and binary forms, with or without 76386SN/A * modification, are permitted provided that the following conditions are 86386SN/A * met: redistributions of source code must retain the above copyright 96386SN/A * notice, this list of conditions and the following disclaimer; 106386SN/A * redistributions in binary form must reproduce the above copyright 116386SN/A * notice, this list of conditions and the following disclaimer in the 126386SN/A * documentation and/or other materials provided with the distribution; 136386SN/A * neither the name of the copyright holders nor the names of its 146386SN/A * contributors may be used to endorse or promote products derived from 156386SN/A * this software without specific prior written permission. 166386SN/A * 176386SN/A * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 186386SN/A * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 196386SN/A * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 206386SN/A * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 216386SN/A * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 226386SN/A * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 236386SN/A * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 246386SN/A * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 256386SN/A * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 266386SN/A * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 276386SN/A * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 286386SN/A */ 296145SN/A 307632SBrad.Beckmann@amd.com#include "cpu/testers/directedtest/DirectedGenerator.hh" 3111793Sbrandon.potter@amd.com 328832SAli.Saidi@ARM.com#include "sim/system.hh" 336145SN/A 347553SN/ADirectedGenerator::DirectedGenerator(const Params *p) 358832SAli.Saidi@ARM.com : SimObject(p), 3612680Sgiacomo.travaglini@arm.com masterId(p->system->getMasterId(this)) 376145SN/A{ 387553SN/A m_num_cpus = p->num_cpus; 397553SN/A m_directed_tester = NULL; 406145SN/A} 416145SN/A 4211320Ssteve.reinhardt@amd.comvoid 437553SN/ADirectedGenerator::setDirectedTester(RubyDirectedTester* directed_tester) 446145SN/A{ 457553SN/A assert(m_directed_tester == NULL); 467553SN/A m_directed_tester = directed_tester; 476145SN/A} 48