| 2574 | } |
| 2575 | |
| 2576 | int |
| 2577 | Castro::okToContinue () |
| 2578 | { |
| 2579 | if (level > 0) { |
| 2580 | return 1; |
| 2581 | } |
| 2582 | |
| 2583 | int test = 1; |
| 2584 | |
| 2585 | if (signalStopJob) { |
| 2586 | test = 0; |
| 2587 | if (ParallelDescriptor::IOProcessor()) { |
| 2588 | std::cout << " Signalling a stop of the run due to signalStopJob = true." << std::endl; |
| 2589 | } |
| 2590 | } |
| 2591 | else if (parent->dtLevel(level) < dt_cutoff * parent->cumTime()) { |
| 2592 | test = 0; |
| 2593 | if (ParallelDescriptor::IOProcessor()) { |
| 2594 | std::cout << " Signalling a stop of the run because dt < dt_cutoff * time." << std::endl; |
| 2595 | } |
| 2596 | } |
| 2597 | |
| 2598 | return test; |
| 2599 | } |
| 2600 | |
| 2601 | void |
| 2602 | Castro::FluxRegCrseInit() { |