* ./hurricane:

- Change: In Instance & Cell, do *not* materialize unplaced instances.
        This is to avoid overloading the QuadTree at point (0,0) and besides
        has no senses. Uses the PlacementStatus state.
    - Bug: In Viewer CMakeLists.txt, put tool include directories first.
This commit is contained in:
Jean-Paul Chaput 2010-06-08 12:02:03 +00:00
parent 294867edc0
commit c293c57fb8
4 changed files with 29 additions and 13 deletions

View File

@ -258,9 +258,13 @@ void Cell::flattenNets(bool buildRings)
void Cell::materialize() void Cell::materialize()
// ********************* // *********************
{ {
for_each_instance(instance, getInstances()) instance->materialize(); end_for; forEach ( Instance*, iinstance, getInstances() ) {
for_each_net(net, getNets()) net->materialize(); end_for; if ( iinstance->getPlacementStatus() != Instance::PlacementStatus::UNPLACED )
for_each_marker(marker, getMarkers()) marker->materialize(); end_for; iinstance->materialize();
}
forEach ( Net* , inet , getNets () ) inet ->materialize();
forEach ( Marker*, imarker, getMarkers() ) imarker->materialize();
} }
void Cell::unmaterialize() void Cell::unmaterialize()

View File

@ -303,7 +303,7 @@ InstanceFilter Instance::getIsNotUnplacedFilter()
void Instance::materialize() void Instance::materialize()
// ************************* // *************************
{ {
if (!isMaterialized()) { if (not isMaterialized()) {
Box boundingBox = getBoundingBox(); Box boundingBox = getBoundingBox();
if (!boundingBox.isEmpty()) { if (!boundingBox.isEmpty()) {
QuadTree* quadTree = _cell->_getQuadTree(); QuadTree* quadTree = _cell->_getQuadTree();
@ -375,10 +375,17 @@ void Instance::setTransformation(const Transformation& transformation)
void Instance::setPlacementStatus(const PlacementStatus& placementstatus) void Instance::setPlacementStatus(const PlacementStatus& placementstatus)
// ********************************************************************** // **********************************************************************
{ {
// if (placementstatus != _placementStatus) { if (placementstatus != _placementStatus) {
// Invalidate(true); invalidate(true);
if (_placementStatus == PlacementStatus::UNPLACED)
materialize ();
else if ( placementstatus == PlacementStatus::UNPLACED )
unmaterialize ();
_placementStatus = placementstatus; _placementStatus = placementstatus;
// }
}
} }
void Instance::setMasterCell(Cell* masterCell, bool secureFlag) void Instance::setMasterCell(Cell* masterCell, bool secureFlag)
@ -449,7 +456,12 @@ void Instance::_postCreate()
end_for; end_for;
} }
bool autoMaterialization = not autoMaterializationIsDisabled();
disableAutoMaterialization();
Inherit::_postCreate(); Inherit::_postCreate();
if ( autoMaterialization ) enableAutoMaterialization();
} }
void Instance::_preDestroy() void Instance::_preDestroy()

View File

@ -1,7 +1,7 @@
include_directories ( ${PYTHON_INCLUDE_PATH} include_directories ( ${HURRICANE_SOURCE_DIR}/src/hurricane
${HURRICANE_SOURCE_DIR}/src/hurricane
${HURRICANE_SOURCE_DIR}/src/isobar ${HURRICANE_SOURCE_DIR}/src/isobar
${PYTHON_INCLUDE_PATH}
) )
set ( sources ProxyProperty.cpp set ( sources ProxyProperty.cpp
PyBox.cpp PyBox.cpp

View File

@ -1,9 +1,9 @@
include ( ${QT_USE_FILE} ) include ( ${QT_USE_FILE} )
include_directories ( ${Boost_INCLUDE_DIRS} include_directories ( ${HURRICANE_SOURCE_DIR}/src/hurricane
${HURRICANE_SOURCE_DIR}/src/hurricane ${HURRICANE_SOURCE_DIR}/src/viewer
${HURRICANE_SOURCE_DIR}/src/viewer ) ${Boost_INCLUDE_DIRS} )
set ( mocincludes hurricane/viewer/HApplication.h set ( mocincludes hurricane/viewer/HApplication.h
hurricane/viewer/PaletteItem.h hurricane/viewer/PaletteItem.h