crossbar.h revision 10234
110152Satgutier@umich.edu/***************************************************************************** 210152Satgutier@umich.edu * McPAT/CACTI 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 3410152Satgutier@umich.edu#ifndef __CROSSBAR__ 3510152Satgutier@umich.edu#define __CROSSBAR__ 3610152Satgutier@umich.edu 3710152Satgutier@umich.edu#include <assert.h> 3810152Satgutier@umich.edu 3910152Satgutier@umich.edu#include <iostream> 4010152Satgutier@umich.edu 4110152Satgutier@umich.edu#include "basic_circuit.h" 4210152Satgutier@umich.edu#include "cacti_interface.h" 4310152Satgutier@umich.edu#include "component.h" 4410152Satgutier@umich.edu#include "mat.h" 4510152Satgutier@umich.edu#include "parameter.h" 4610152Satgutier@umich.edu#include "wire.h" 4710152Satgutier@umich.edu 4810234Syasuko.eckert@amd.comclass Crossbar : public Component { 4910234Syasuko.eckert@amd.compublic: 5010152Satgutier@umich.edu Crossbar( 5110234Syasuko.eckert@amd.com double in, 5210234Syasuko.eckert@amd.com double out, 5310234Syasuko.eckert@amd.com double flit_sz, 5410234Syasuko.eckert@amd.com TechnologyParameter::DeviceType *dt = &(g_tp.peri_global)); 5510152Satgutier@umich.edu ~Crossbar(); 5610152Satgutier@umich.edu 5710152Satgutier@umich.edu void print_crossbar(); 5810152Satgutier@umich.edu double output_buffer(); 5910152Satgutier@umich.edu void compute_power(); 6010152Satgutier@umich.edu 6110152Satgutier@umich.edu double n_inp, n_out; 6210152Satgutier@umich.edu double flit_size; 6310152Satgutier@umich.edu double tri_inp_cap, tri_out_cap, tri_ctr_cap, tri_int_cap; 6410152Satgutier@umich.edu 6510234Syasuko.eckert@amd.comprivate: 6610234Syasuko.eckert@amd.com double CB_ADJ; 6710234Syasuko.eckert@amd.com /* 6810234Syasuko.eckert@amd.com * Adjust factor of the height of the cross-point (tri-state buffer) cell (layout) in crossbar 6910234Syasuko.eckert@amd.com * buffer is adjusted to get an aspect ratio of whole cross bar close to one; 7010234Syasuko.eckert@amd.com * when adjust the ratio, the number of wires route over the tri-state buffers does not change, 7110234Syasuko.eckert@amd.com * however, the effective wiring pitch changes. Specifically, since CB_ADJ will increase 7210234Syasuko.eckert@amd.com * during the adjust, the tri-state buffer will become taller and thiner, and the effective wiring pitch 7310234Syasuko.eckert@amd.com * will increase. As a result, the height of the crossbar (area.h) will increase. 7410234Syasuko.eckert@amd.com */ 7510152Satgutier@umich.edu 7610234Syasuko.eckert@amd.com TechnologyParameter::DeviceType *deviceType; 7710152Satgutier@umich.edu double TriS1, TriS2; 7810152Satgutier@umich.edu double min_w_pmos, Vdd; 7910152Satgutier@umich.edu 8010152Satgutier@umich.edu}; 8110152Satgutier@umich.edu 8210152Satgutier@umich.edu 8310152Satgutier@umich.edu 8410152Satgutier@umich.edu 8510152Satgutier@umich.edu#endif 86