8#ifndef BOOKSHELFPARSER_DATABASE_H
9#define BOOKSHELFPARSER_DATABASE_H
32typedef unsigned int uint32_t;
43 using base_type::size_type;
44 using base_type::value_type;
45 using base_type::allocator_type;
56 IntegerArray(size_type n,
const value_type& val,
const allocator_type& alloc = allocator_type())
57 : base_type(n, val, alloc) {}
67 using base_type::size_type;
68 using base_type::value_type;
69 using base_type::allocator_type;
80 StringArray(size_type n,
const value_type& val,
const allocator_type& alloc = allocator_type())
81 : base_type(n, val, alloc) {}
89 virtual void print(ostream&)
const {};
131 virtual void print(ostream& ss)
const
133 ss <<
"//////// Row ////////" << endl
135 <<
"orient = " <<
orient << endl
170 NetPin(
string& nn,
char d,
double x,
double y,
double w,
double h,
string& pn)
185 NetPin(
string& nn,
char d,
double x,
double y,
double w,
double h)
218 virtual void print(ostream& ss)
const
220 ss <<
"//////// Net ////////" << endl
221 <<
"net_name = " <<
net_name << endl;
222 for (uint32_t i = 0; i <
vNetPin.size(); ++i)
223 ss <<
"(" <<
vNetPin[i].node_name <<
", " <<
vNetPin[i].pin_name <<
") "
242 ShapeBox(
string& n,
double x,
double y,
double w,
double h)
273 virtual void print(ostream& ss)
const
275 ss <<
"//////// NodeShape ////////" << endl
277 for (uint32_t i = 0; i < vShapeBox.size(); ++i)
278 ss << vShapeBox[i].name
279 <<
" @(" << vShapeBox[i].origin[0] <<
", " << vShapeBox[i].origin[1] <<
") "
280 <<
" w/h (" << vShapeBox[i].size[0] <<
", " << vShapeBox[i].size[1] <<
")"
302 layer = std::numeric_limits<int>::max();
352 virtual void print(ostream& ss)
const
354 ss <<
"//////// RouteInfo ////////" << endl;
356 ss <<
"numLayers = " <<
numLayers << endl;
357 ss <<
"vVerticalCapacity = ";
361 ss <<
"vHorizontalCapacity = ";
365 ss <<
"vMinWireWidth = ";
369 ss <<
"vMinWireSpacing = ";
373 ss <<
"vViaSpacing = ";
374 for (
unsigned int i = 0; i <
vViaSpacing.size(); ++i)
433 void bookshelf_user_cbk_reminder(
const char* str)
const;
Base class for bookshelf database. Only pure virtual functions are defined. User needs to inheritat...
virtual void set_bookshelf_node_position(string const &, double, double, string const &, string const &, bool)=0
set node position
virtual void add_bookshelf_terminal(string &, int, int)=0
add terminal
virtual void resize_bookshelf_shapes(int)
set number of shapes
virtual void resize_bookshelf_blockage_layers(int)
set number of blockage nodes with layers
virtual void resize_bookshelf_pin(int)=0
set number of pins
virtual void add_bookshelf_terminal_NI(string &, int, int)
add terminal_NI
virtual void add_bookshelf_node(string &, int, int, bool)=0
add node
virtual void add_bookshelf_row(Row const &)=0
add row
virtual void add_bookshelf_net(Net const &)=0
add net
virtual void set_bookshelf_net_weight(string const &name, double w)
set net weight
virtual void set_bookshelf_route_info(RouteInfo const &)
set routing information
virtual void add_bookshelf_blockage_layers(string const &, vector< string > const &)
set blockages with layers
virtual void add_bookshelf_niterminal_layer(string const &, string const &)
set NI terminal with layers
virtual void resize_bookshelf_row(int)=0
set number of rows
virtual void set_bookshelf_shape(NodeShape const &)
set node shapes
virtual void resize_bookshelf_node_terminals(int, int)=0
set number of terminals
virtual void resize_bookshelf_net(int)=0
set number of nets
virtual void set_bookshelf_design(string &)=0
set design name
virtual void resize_bookshelf_niterminal_layers(int)
set number of NI terminals with layers
virtual void bookshelf_end()=0
a callback when a bookshelf file reaches to the end
IntegerArray(const allocator_type &alloc=allocator_type())
IntegerArray(size_type n, const value_type &val, const allocator_type &alloc=allocator_type())
StringArray(size_type n, const value_type &val, const allocator_type &alloc=allocator_type())
StringArray(const allocator_type &alloc=allocator_type())
namespace for BookshelfParser
describe blockage node name, blocked layer list
string node_name
node name
void reset()
reset all data members
vector< int > vLayer
layer list
void reset()
reset all data members
IOPinLayer(string &name, int l)
constructor
Temporary data structures to hold parsed data. Base class for all temporary data structures.
virtual void print(ostream &) const
print data members
friend ostream & operator<<(ostream &ss, Item const &rhs)
net to describe interconnection of netlist
void reset()
reset all data members
virtual void print(ostream &ss) const
NetPin(string &nn, char d, double x, double y, double w, double h, string &pn)
void reset()
reset all data members
double offset[2]
offset (x, y) to node origin
double size[2]
sizes (x, y) of pin
string node_name
node name
NetPin(string &nn, char d, double x, double y, double w, double h)
node shape to describe the shapes of node
void reset()
reset all data members
string node_name
node name
virtual void print(ostream &ss) const
information for routing to describe .route refer to DAC 2012 contest http://archive....
double gridOrigin[2]
Absolute coordinates of the origin of the grid (grid_lowerleft_X grid_lowerleft_Y).
vector< int > vMinWireSpacing
min wire spacing for each layer
int numGrids[2]
global routing grids in X and Y
double tileSize[2]
tile_width, tile_height
virtual void print(ostream &ss) const
vector< int > vViaSpacing
via spacing per layer
void reset()
reset all data members
int blockagePorosity
Porosity for routing blockages (Zero implies the blockage completely blocks overlapping routing track...
int numLayers
number of layers
vector< int > vVerticalCapacity
vertical capacity at each layer
vector< int > vMinWireWidth
min wire width for each layer
vector< int > vHorizontalCapacity
horizontal capacity at each layer
virtual void print(ostream &ss) const
int32_t site_num
number of sites
int32_t site_spacing
spacing of a site
string site_orient_str
orientation of a site in string
void reset()
reset all data members
int32_t site_width
width of a site
int32_t site_orient
orientation of a site, one of these two will be valid
int32_t site_symmetry
symmetry of a site
void reset()
reset all data members
ShapeBox(string &n, double x, double y, double w, double h)
constructor
double origin[2]
lower left corner of the box
double size[2]
width and height