67 dst->SEType = src->SEType ;
68 dst->NLayers = src->NLayers ;
69 dst->Offset = src->Offset ;
75 dst->Pointer.Layer =
layer_clone (src->Pointer.Layer) ;
79 dst->Pointer.Die =
die_clone (src->Pointer.Die) ;
85 dst->Pointer = src->Pointer ;
87 if (src->TopSink != NULL) dst->TopSink =
heat_sink_clone (src->TopSink) ;
88 if (src->BottomSink != NULL) dst->BottomSink =
heat_sink_clone (src->BottomSink) ;
182 "%s die %s %s floorplan \"%s\" ;\n",
193 "%s layer %s %s ;\n",
201 fprintf (stderr,
"Warning: found stack element type none\n") ;
206 fprintf (stderr,
"Undefined stack element type %d\n", stkel->
SEType) ;
224 return layer_offset ;
241 char name[50] =
"xyaxis_";
242 strcat(name,stkel->
Id);
244 FILE *filexy = fopen (name,
"w") ;
247 fprintf (stderr,
"Cannot create text file for x axis in the non-uniform scenario\n") ;
253 for (Non_uniform_cellListNode_t* cell_i = dimensions->
Cell_list.First; cell_i != NULL; cell_i = cell_i->Next)
255 if (cell_i->Data.layer_info == layer_offset)
257 fprintf (stream,
"%7.3f ", *(temperatures+counter)) ;
258 fprintf (filexy,
"%5.2f\t%5.2f\t%5.2f\t%5.2f\n", cell_i->Data.left_x, cell_i->Data.left_y, cell_i->Data.length,cell_i->Data.width) ;
262 fprintf (stream,
"\n") ;
280 fprintf (stream,
"%7.3f ", *temperatures++) ;
283 fprintf (stream,
"\n") ;
302 char name[50] =
"xyaxis_";
303 strcat(name,stkel->
Id);
305 FILE *filexy = fopen (name,
"w") ;
308 fprintf (stderr,
"Cannot create text file for x axis in the non-uniform scenario\n") ;
314 for (Non_uniform_cellListNode_t* cell_i = dimensions->
Cell_list.First; cell_i != NULL; cell_i = cell_i->Next)
316 if (cell_i->Data.layer_info == layer_offset)
318 fprintf (stream,
"%7.3f ", *(sources+counter)) ;
319 fprintf (filexy,
"%5.2f\t%5.2f\t%5.2f\t%5.2f\n", cell_i->Data.left_x, cell_i->Data.left_y, cell_i->Data.length,cell_i->Data.width) ;
323 fprintf (stream,
"\n") ;
340 fprintf (stream,
"%7.3f ", *sources++) ;
343 fprintf (stream,
"\n") ;
void die_free(Die_t *die)
Die_t * die_clone(Die_t *die)
CellIndex_t get_cell_offset_in_stack(Dimensions_t *dimensions, CellIndex_t layer_index, CellIndex_t row_index, CellIndex_t column_index)
CellIndex_t last_column(Dimensions_t *dimensions)
CellIndex_t first_column(Dimensions_t *dimensions)
CellIndex_t first_row(Dimensions_t *dimensions)
CellIndex_t last_row(Dimensions_t *dimensions)
Quantity_t get_number_of_floorplan_elements_floorplan(Floorplan_t *floorplan)
HeatSink_t * heat_sink_clone(HeatSink_t *hsink)
void heat_sink_free(HeatSink_t *hsink)
void layer_free(Layer_t *layer)
Layer_t * layer_clone(Layer_t *layer)
void stack_element_copy(StackElement_t *dst, StackElement_t *src)
void stack_element_print_power_map(StackElement_t *stkel, Dimensions_t *dimensions, Source_t *sources, FILE *stream)
void stack_element_destroy(StackElement_t *stkel)
void stack_element_init(StackElement_t *stkel)
CellIndex_t get_source_layer_offset(StackElement_t *stkel)
StackElement_t * stack_element_calloc(void)
void stack_element_print_thermal_map(StackElement_t *stkel, Dimensions_t *dimensions, Temperature_t *temperatures, FILE *stream)
Quantity_t get_number_of_floorplan_elements_stack_element(StackElement_t *stkel)
StackElement_t * stack_element_clone(StackElement_t *stkel)
bool stack_element_same_id(StackElement_t *stkel, StackElement_t *other)
void stack_element_print(StackElement_t *stkel, FILE *stream, String_t prefix)
void stack_element_free(StackElement_t *stkel)
void string_init(String_t *string)
bool string_equal(String_t *string, String_t *other)
void string_destroy(String_t *string)
void string_copy(String_t *dst, String_t *src)
CellIndex_t SourceLayerOffset
CellIndex_t SourceLayerOffset
Collections of all the structures that are needed for the thermal simulation.
Non_uniform_cellList_t Cell_list
Structure used to store data about the stack element that compose the 2D/3D stack.
StackElementType_t SEType
@ TDICE_STACK_ELEMENT_NONE
Undefined type.
@ TDICE_STACK_ELEMENT_LAYER
Layer.
@ TDICE_STACK_ELEMENT_CHANNEL
Channel.
@ TDICE_STACK_ELEMENT_DIE
Die.