| 1/* Copyright (c) 2012 Massachusetts Institute of Technology 2 * 3 * Permission is hereby granted, free of charge, to any person obtaining a copy 4 * of this software and associated documentation files (the "Software"), to deal 5 * in the Software without restriction, including without limitation the rights 6 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7 * copies of the Software, and to permit persons to whom the Software is 8 * furnished to do so, subject to the following conditions: 9 * 10 * The above copyright notice and this permission notice shall be included in 11 * all copies or substantial portions of the Software. 12 * 13 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 16 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 18 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 19 * THE SOFTWARE. 20 */ 21
|
28 // Set the pointer to a standard cell library 29 void setStdCellLib(const StdCellLib* std_cell_lib_); 30 // Get the pointer to the standard cell library 31 const StdCellLib* getStdCellLib() const; 32 33 // Return a cloned copy of this instance 34 virtual TechModel* clone() const; 35 // Override readFile function to include multiple technology files 36 virtual void readFile(const String& filename_); 37 38 // Transistor 39 // Returns the leakage current of NMOS transistors, given the transistor stakcing, transistor widths, and input combination 40 double calculateNmosLeakageCurrent(unsigned int num_stacks_, double uni_stacked_mos_width_, unsigned int input_vector_) const; 41 double calculateNmosLeakageCurrent(unsigned int num_stacks_, const vector<double>& stacked_mos_widths_, unsigned int input_vector_) const; 42 // Returns the leakage current of PMOS transistors, given the transistor stakcing, transistor widths, and input combination 43 double calculatePmosLeakageCurrent(unsigned int num_stacks_, double uni_stacked_mos_width_, unsigned int input_vector_) const; 44 double calculatePmosLeakageCurrent(unsigned int num_stacks_, const vector<double>& stacked_mos_widths_, unsigned int input_vector_) const; 45 // Returns the leakage current, given the transistor stakcing, transistor widths, input combination, 46 // and technology information (vdd, subthreshold swing, subthreshold dibl swing) 47 double calculateLeakageCurrentFactor(unsigned int num_stacks_, const vector<double>& stacked_mos_widths_, unsigned int input_vector_, double vdd_, double subthreshold_swing_, double dibl_swing_) const; 48 49 // Wire 50 // Check if the wire layer exist 51 bool isWireLayerExist(const String& layer_name_) const; 52 const std::set<String>* getAvailableWireLayers() const; 53 // Return wire capacitance for given wire layer, wire width, wire spacing, and wire length 54 double calculateWireCapacitance(const String& layer_name_, double width_, double spacing_, double length_) const; 55 // Return wire resistance for given wire layer, wire width, and wire length 56 double calculateWireResistance(const String& layer_name_, double width_, double length_) const; 57 58 private: 59 // Private copy constructor. Use clone to perform copy operation 60 TechModel(const TechModel& tech_model_); 61 62 private: 63 // A pointer to a standard cell library 64 const StdCellLib* m_std_cell_lib_; 65 // A set of available wire layers 66 std::set<String>* m_available_wire_layers_;
| 52 // Set the pointer to a standard cell library 53 void setStdCellLib(const StdCellLib* std_cell_lib_); 54 // Get the pointer to the standard cell library 55 const StdCellLib* getStdCellLib() const; 56 57 // Return a cloned copy of this instance 58 virtual TechModel* clone() const; 59 // Override readFile function to include multiple technology files 60 virtual void readFile(const String& filename_); 61 62 // Transistor 63 // Returns the leakage current of NMOS transistors, given the transistor stakcing, transistor widths, and input combination 64 double calculateNmosLeakageCurrent(unsigned int num_stacks_, double uni_stacked_mos_width_, unsigned int input_vector_) const; 65 double calculateNmosLeakageCurrent(unsigned int num_stacks_, const vector<double>& stacked_mos_widths_, unsigned int input_vector_) const; 66 // Returns the leakage current of PMOS transistors, given the transistor stakcing, transistor widths, and input combination 67 double calculatePmosLeakageCurrent(unsigned int num_stacks_, double uni_stacked_mos_width_, unsigned int input_vector_) const; 68 double calculatePmosLeakageCurrent(unsigned int num_stacks_, const vector<double>& stacked_mos_widths_, unsigned int input_vector_) const; 69 // Returns the leakage current, given the transistor stakcing, transistor widths, input combination, 70 // and technology information (vdd, subthreshold swing, subthreshold dibl swing) 71 double calculateLeakageCurrentFactor(unsigned int num_stacks_, const vector<double>& stacked_mos_widths_, unsigned int input_vector_, double vdd_, double subthreshold_swing_, double dibl_swing_) const; 72 73 // Wire 74 // Check if the wire layer exist 75 bool isWireLayerExist(const String& layer_name_) const; 76 const std::set<String>* getAvailableWireLayers() const; 77 // Return wire capacitance for given wire layer, wire width, wire spacing, and wire length 78 double calculateWireCapacitance(const String& layer_name_, double width_, double spacing_, double length_) const; 79 // Return wire resistance for given wire layer, wire width, and wire length 80 double calculateWireResistance(const String& layer_name_, double width_, double length_) const; 81 82 private: 83 // Private copy constructor. Use clone to perform copy operation 84 TechModel(const TechModel& tech_model_); 85 86 private: 87 // A pointer to a standard cell library 88 const StdCellLib* m_std_cell_lib_; 89 // A set of available wire layers 90 std::set<String>* m_available_wire_layers_;
|