29 #include "G4String.hh"
43 tbb::concurrent_queue<const G4Run*>* out,
48 m_beamOnCondition(false)
56 #include <tbb/atomic.h>
58 tbb::atomic<int> counter;
115 G4int thisId = counter.fetch_and_increment();
154 localRM->G4RunManager::SetUserInitialization(
155 const_cast<G4VUserDetectorConstruction*>(detector));
157 localRM->SetUserInitialization(const_cast<G4VUserPhysicsList*>(physicslist));
166 localRM->Initialize();
172 std::vector<G4String>::const_iterator it = cmds.begin();
173 for(;it!=cmds.end();it++)
178 if ( macroFile ==
"" || macroFile ==
" " )
184 localRM->BeamOn(
m_nEvents,macroFile,numSelect);
193 localRM->SetNumberOfEventsToBeProcessed(
m_nEvents );
194 localRM->ConstructScoringWorlds();
195 localRM->RunInitialization();
232 return static_cast<tbb::task*
>(NULL);
virtual G4VSteppingVerbose * InitializeSteppingVerbose() const
static G4MTRunManager * GetMasterRunManager()
virtual void Build() const =0
virtual void SetupRNGEngine(const CLHEP::HepRandomEngine *aRNGEngine) const
const G4VUserPhysicsList * GetUserPhysicsList() const
tbb::concurrent_queue< const G4Run * > * m_output
G4int ApplyCommand(const char *aCommand)
static void BuildGeometryAndPhysicsVector()
std::vector< G4String > GetCommandStack()
virtual void WorkerStart() const
virtual void WorkerInitialize() const
static G4UImanager * GetUIpointer()
const CLHEP::HepRandomEngine * getMasterRandomEngine() const
G4int GetNumberOfSelectEvents() const
G4VUserActionInitialization * GetNonConstUserActionInitialization() const
tbbTask(G4int anId, tbb::concurrent_queue< const G4Run * > *output=0, G4int nEvts=1)
const G4UserWorkerInitialization * GetUserWorkerInitialization() const
void G4SetThreadId(G4int aNewValue)
const G4VUserActionInitialization * GetUserActionInitialization() const
virtual G4WorkerRunManager * CreateWorkerRunManager() const
static void SetInstance(G4VSteppingVerbose *Instance)
G4GLOB_DLL std::ostream G4cout
void SetUpForAThread(G4int tId)
G4String GetSelectMacro() const
const G4UserWorkerThreadInitialization * GetUserWorkerThreadInitialization() const
const G4VUserDetectorConstruction * GetUserDetectorConstruction() const