112027Sjungma@eit.uni-kl.de/*****************************************************************************
212027Sjungma@eit.uni-kl.de
312027Sjungma@eit.uni-kl.de  Licensed to Accellera Systems Initiative Inc. (Accellera) under one or
412027Sjungma@eit.uni-kl.de  more contributor license agreements.  See the NOTICE file distributed
512027Sjungma@eit.uni-kl.de  with this work for additional information regarding copyright ownership.
612027Sjungma@eit.uni-kl.de  Accellera licenses this file to you under the Apache License, Version 2.0
712027Sjungma@eit.uni-kl.de  (the "License"); you may not use this file except in compliance with the
812027Sjungma@eit.uni-kl.de  License.  You may obtain a copy of the License at
912027Sjungma@eit.uni-kl.de
1012027Sjungma@eit.uni-kl.de    http://www.apache.org/licenses/LICENSE-2.0
1112027Sjungma@eit.uni-kl.de
1212027Sjungma@eit.uni-kl.de  Unless required by applicable law or agreed to in writing, software
1312027Sjungma@eit.uni-kl.de  distributed under the License is distributed on an "AS IS" BASIS,
1412027Sjungma@eit.uni-kl.de  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
1512027Sjungma@eit.uni-kl.de  implied.  See the License for the specific language governing
1612027Sjungma@eit.uni-kl.de  permissions and limitations under the License.
1712027Sjungma@eit.uni-kl.de
1812027Sjungma@eit.uni-kl.de *****************************************************************************/
1912027Sjungma@eit.uni-kl.de
2012027Sjungma@eit.uni-kl.de/*****************************************************************************
2112027Sjungma@eit.uni-kl.de
2212027Sjungma@eit.uni-kl.de  sc_status.h -- Definition of the simulation phases
2312027Sjungma@eit.uni-kl.de
2412027Sjungma@eit.uni-kl.de  Original Author: Philipp A. Hartmann, OFFIS, 2013-02-15
2512027Sjungma@eit.uni-kl.de
2612027Sjungma@eit.uni-kl.de  CHANGE LOG AT THE END OF THE FILE
2712027Sjungma@eit.uni-kl.de *****************************************************************************/
2812027Sjungma@eit.uni-kl.de
2912027Sjungma@eit.uni-kl.de#ifndef SC_STATUS_H_INCLUDED_
3012027Sjungma@eit.uni-kl.de#define SC_STATUS_H_INCLUDED_
3112027Sjungma@eit.uni-kl.de
3212027Sjungma@eit.uni-kl.de#include <iosfwd>
3312027Sjungma@eit.uni-kl.de
3412027Sjungma@eit.uni-kl.denamespace sc_core {
3512027Sjungma@eit.uni-kl.de
3612027Sjungma@eit.uni-kl.de// simulation status codes
3712027Sjungma@eit.uni-kl.de
3812027Sjungma@eit.uni-kl.deconst int SC_SIM_OK        = 0;
3912027Sjungma@eit.uni-kl.deconst int SC_SIM_ERROR     = 1;
4012027Sjungma@eit.uni-kl.deconst int SC_SIM_USER_STOP = 2;
4112027Sjungma@eit.uni-kl.de
4212027Sjungma@eit.uni-kl.deenum sc_status
4312027Sjungma@eit.uni-kl.de{   // sc_get_status values:
4412027Sjungma@eit.uni-kl.de    SC_UNITIALIZED=0x00,                 // initialize() not called yet
4512027Sjungma@eit.uni-kl.de
4612027Sjungma@eit.uni-kl.de    SC_ELABORATION               = 0x01, // during module hierarchy construction
4712027Sjungma@eit.uni-kl.de    SC_BEFORE_END_OF_ELABORATION = 0x02, // during before_end_of_elaboration()
4812027Sjungma@eit.uni-kl.de    SC_END_OF_ELABORATION        = 0x04, // during end_of_elaboration()
4912027Sjungma@eit.uni-kl.de    SC_START_OF_SIMULATION       = 0x08, // during start_of_simulation()
5012027Sjungma@eit.uni-kl.de
5112027Sjungma@eit.uni-kl.de    SC_RUNNING                   = 0x10, // initialization, evaluation or update
5212027Sjungma@eit.uni-kl.de    SC_PAUSED                    = 0x20, // when scheduler stopped by sc_pause()
5312027Sjungma@eit.uni-kl.de    SC_STOPPED                   = 0x40, // when scheduler stopped by sc_stop()
5412027Sjungma@eit.uni-kl.de    SC_END_OF_SIMULATION         = 0x80, // during end_of_simulation()
5512027Sjungma@eit.uni-kl.de
5612027Sjungma@eit.uni-kl.de    // detailed simulation phases (for dynamic callbacks)
5712027Sjungma@eit.uni-kl.de    SC_END_OF_INITIALIZATION     = 0x100, // after initialization
5812027Sjungma@eit.uni-kl.de//    SC_END_OF_EVALUATION         = 0x200, // between eval and update
5912027Sjungma@eit.uni-kl.de    SC_END_OF_UPDATE             = 0x400, // after update/notify phase
6012027Sjungma@eit.uni-kl.de    SC_BEFORE_TIMESTEP           = 0x800, // before next time step
6112027Sjungma@eit.uni-kl.de
6212027Sjungma@eit.uni-kl.de    SC_STATUS_LAST               = SC_BEFORE_TIMESTEP,
6312027Sjungma@eit.uni-kl.de    SC_STATUS_ANY                = 0xdff
6412027Sjungma@eit.uni-kl.de};
6512027Sjungma@eit.uni-kl.de
6612027Sjungma@eit.uni-kl.de// pretty-printing of sc_status values
6712027Sjungma@eit.uni-kl.destd::ostream& operator << ( std::ostream&, sc_status );
6812027Sjungma@eit.uni-kl.de
6912027Sjungma@eit.uni-kl.de} // namespace sc_core
7012027Sjungma@eit.uni-kl.de
7112027Sjungma@eit.uni-kl.de/*****************************************************************************
7212027Sjungma@eit.uni-kl.de
7312027Sjungma@eit.uni-kl.de  MODIFICATION LOG - modifiers, enter your name, affiliation, date and
7412027Sjungma@eit.uni-kl.de  changes you are making here.
7512027Sjungma@eit.uni-kl.de
7612027Sjungma@eit.uni-kl.de      Name, Affiliation, Date:
7712027Sjungma@eit.uni-kl.de  Description of Modification:
7812027Sjungma@eit.uni-kl.de
7912027Sjungma@eit.uni-kl.de *****************************************************************************/
8012027Sjungma@eit.uni-kl.de
8112027Sjungma@eit.uni-kl.de#endif /* SC_STATUS_H_INCLUDED_ */
8212027Sjungma@eit.uni-kl.de// Taf!
8312027Sjungma@eit.uni-kl.de
84