110152Satgutier@umich.edu/***************************************************************************** 210152Satgutier@umich.edu * McPAT 310152Satgutier@umich.edu * SOFTWARE LICENSE AGREEMENT 410152Satgutier@umich.edu * Copyright 2012 Hewlett-Packard Development Company, L.P. 510234Syasuko.eckert@amd.com * Copyright (c) 2010-2013 Advanced Micro Devices, Inc. 610152Satgutier@umich.edu * All Rights Reserved 710152Satgutier@umich.edu * 810152Satgutier@umich.edu * Redistribution and use in source and binary forms, with or without 910152Satgutier@umich.edu * modification, are permitted provided that the following conditions are 1010152Satgutier@umich.edu * met: redistributions of source code must retain the above copyright 1110152Satgutier@umich.edu * notice, this list of conditions and the following disclaimer; 1210152Satgutier@umich.edu * redistributions in binary form must reproduce the above copyright 1310152Satgutier@umich.edu * notice, this list of conditions and the following disclaimer in the 1410152Satgutier@umich.edu * documentation and/or other materials provided with the distribution; 1510152Satgutier@umich.edu * neither the name of the copyright holders nor the names of its 1610152Satgutier@umich.edu * contributors may be used to endorse or promote products derived from 1710152Satgutier@umich.edu * this software without specific prior written permission. 1810152Satgutier@umich.edu 1910152Satgutier@umich.edu * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 2010152Satgutier@umich.edu * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 2110152Satgutier@umich.edu * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 2210152Satgutier@umich.edu * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 2310152Satgutier@umich.edu * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 2410152Satgutier@umich.edu * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 2510152Satgutier@umich.edu * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 2610152Satgutier@umich.edu * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 2710152Satgutier@umich.edu * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 2810152Satgutier@umich.edu * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 2910234Syasuko.eckert@amd.com * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 3010152Satgutier@umich.edu * 3110152Satgutier@umich.edu ***************************************************************************/ 3210152Satgutier@umich.edu 3310152Satgutier@umich.edu#ifndef ARRAY_H_ 3410152Satgutier@umich.edu#define ARRAY_H_ 3510152Satgutier@umich.edu 3610152Satgutier@umich.edu#include <iostream> 3710152Satgutier@umich.edu#include <string> 3810152Satgutier@umich.edu 3910152Satgutier@umich.edu#include "basic_components.h" 4010152Satgutier@umich.edu#include "cacti_interface.h" 4110152Satgutier@umich.edu#include "component.h" 4210152Satgutier@umich.edu#include "const.h" 4310152Satgutier@umich.edu#include "parameter.h" 4410152Satgutier@umich.edu 4510152Satgutier@umich.eduusing namespace std; 4610152Satgutier@umich.edu 4710234Syasuko.eckert@amd.comclass ArrayST : public McPATComponent { 4810234Syasuko.eckert@amd.compublic: 4910234Syasuko.eckert@amd.com static double area_efficiency_threshold; 5010152Satgutier@umich.edu 5110234Syasuko.eckert@amd.com // These are used for the CACTI interface. 5210234Syasuko.eckert@amd.com static int ed; 5310234Syasuko.eckert@amd.com static int delay_wt; 5410234Syasuko.eckert@amd.com static int cycle_time_wt; 5510234Syasuko.eckert@amd.com static int area_wt; 5610234Syasuko.eckert@amd.com static int dynamic_power_wt; 5710234Syasuko.eckert@amd.com static int leakage_power_wt; 5810234Syasuko.eckert@amd.com static int delay_dev; 5910234Syasuko.eckert@amd.com static int cycle_time_dev; 6010234Syasuko.eckert@amd.com static int area_dev; 6110234Syasuko.eckert@amd.com static int dynamic_power_dev; 6210234Syasuko.eckert@amd.com static int leakage_power_dev; 6310234Syasuko.eckert@amd.com static int cycle_time_dev_threshold; 6410152Satgutier@umich.edu 6510234Syasuko.eckert@amd.com InputParameter l_ip; 6610234Syasuko.eckert@amd.com enum Device_ty device_ty; 6710234Syasuko.eckert@amd.com bool opt_local; 6810234Syasuko.eckert@amd.com enum Core_type core_ty; 6910234Syasuko.eckert@amd.com bool is_default; 7010234Syasuko.eckert@amd.com uca_org_t local_result; 7110234Syasuko.eckert@amd.com statsDef stats_t; 7210152Satgutier@umich.edu 7310234Syasuko.eckert@amd.com ArrayST(XMLNode* _xml_data, const InputParameter *configure_interface, 7410234Syasuko.eckert@amd.com string _name, enum Device_ty device_ty_, double _clockRate = 0.0f, 7510234Syasuko.eckert@amd.com bool opt_local_ = true, 7610234Syasuko.eckert@amd.com enum Core_type core_ty_ = Inorder, bool _is_default = true); 7710234Syasuko.eckert@amd.com void computeArea(); 7810234Syasuko.eckert@amd.com void computeEnergy(); 7910234Syasuko.eckert@amd.com void compute_base_power(); 8010234Syasuko.eckert@amd.com ~ArrayST(); 8110152Satgutier@umich.edu 8210234Syasuko.eckert@amd.com void leakage_feedback(double temperature); 8310152Satgutier@umich.edu}; 8410152Satgutier@umich.edu 8510234Syasuko.eckert@amd.com#endif /* ARRAY_H_ */ 86