From: rahuel Date: Fri, 14 Oct 2005 11:44:04 +0000 (+0000) Subject: Debug of MacroNodes : developpement of missing code for Gate management of MacroNodes X-Git-Tag: V2_2_6~13 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=4e35eea73015f81c8a86baa6591cd1e26e4b39e5;p=modules%2Fsuperv.git Debug of MacroNodes : developpement of missing code for Gate management of MacroNodes --- diff --git a/src/GraphExecutor/DataFlowExecutor_DataFlow.cxx b/src/GraphExecutor/DataFlowExecutor_DataFlow.cxx index a1da842..82cb5fc 100644 --- a/src/GraphExecutor/DataFlowExecutor_DataFlow.cxx +++ b/src/GraphExecutor/DataFlowExecutor_DataFlow.cxx @@ -183,6 +183,18 @@ bool GraphExecutor::DataFlow::OutputOfAny( const char * aNodeName , RetVal = Graph()->AddOutputData( aNodeName , ToServiceParameterName , aValue ) ; GraphBase::OutPort * anOutPort = aMacroNode->GetChangeOutPort( ToServiceParameterName ) ; int i ; + for ( i = 0 ; i < aMacroNode->GetNodeOutPortsSize() ; i++ ) { + cdebug << "Out" << i << " " << aMacroNode->GetNodeOutPort( i )->PortName() << " " + << aMacroNode->GetChangeNodeOutPort( i )->State() << " Done=" + << aMacroNode->GetChangeNodeOutPort( i )->Done() << " " ; + if ( GraphBase::Base::_prof_debug ) { + aMacroNode->GetNodeOutPort( i )->StringValue( *GraphBase::Base::_fdebug ) ; + } + if ( aMacroNode->GetChangeNodeOutPort( i )->IsGate() ) { + cdebug << " BoolValue " << aMacroNode->GetChangeNodeOutPort( i )->BoolValue() ; + } + cdebug << endl ; + } // Loop over Inports linked to that OutPort of the MacroNode for ( i = 0 ; i < anOutPort->InPortsSize() ; i++ ) { const char * ToNodeName = anOutPort->ChangeInPorts( i )->NodeName() ; @@ -204,11 +216,21 @@ bool GraphExecutor::DataFlow::OutputOfAny( const char * aNodeName , << "->SendSomeDataReady( " << aNodeName << " ) sts " << sts << " " << aLinkedNode->State() << endl ; if ( sts ) { if ( aLinkedNode->State() == GraphExecutor::DataReadyState ) { - aLinkedNode->CreateNewThreadIf( true ) ; + cdebug << pthread_self() << "/" << aLinkedNode->ThreadNo() + << "GraphExecutor::DataFlow::OutputOfAny SendEvent(ExecuteEvent) to " + << aLinkedNode->Name() << endl ; +//JR 29.09.2005 Debug : +// aLinkedNode->CreateNewThreadIf( true ) ; + aLinkedNode->CreateNewThread( true ) ; aLinkedNode->UnLockDataWait() ; // aLinkedNode->DataUndef_AllDataReadyAction() ; aLinkedNode->SendEvent( GraphExecutor::ExecuteEvent ) ; } + else { + cdebug << pthread_self() << "/" << aLinkedNode->ThreadNo() + << "GraphExecutor::DataFlow::OutputOfAny NO SendEvent(ExecuteEvent) to " + << aLinkedNode->Name() << endl ; + } } } else if ( Graph()->GraphMacroLevel() != 0 ) {