Ticket #22 (new task)

Opened 1 year ago

Last modified 1 year ago

multi-thread

Reported by: jordi Owned by: nobody
Priority: major Milestone: indiscussion
Component: planetsim Version: PlanetSim 3
Keywords: multithread Cc:

Description

Report by Max: Multithreaded implementation would be nice because we have access to a quadcore opteron and planetsim uses only one core.

Change History

follow-up: ↓ 2   Changed 1 year ago by jordi

yes. You aren't the first person to state the same. But, because any simulation is based mainly in the main thread that operates in the loop of Network.simulate(), do you have any idea to deal it with? We should find any way of parallelization of this main loop. I think it won't be an easy task.

in reply to: ↑ 1   Changed 1 year ago by max

Replying to jordi:

yes. You aren't the first person to state the same. But, because any simulation is based mainly in the main thread that operates in the loop of Network.simulate(), do you have any idea to deal it with? We should find any way of parallelization of this main loop. I think it won't be an easy task.

maybe if we divide the nodes in the network in #process thread groups (i.e. for dualcore):

Thread1: Node1.process()....NodeX.process()

Thread2: NodeX+1.process()...NodeZ.process()

when all threads are done:

- deliverMessages

- currentStep++

....goto process

Note: See TracTickets for help on using tickets.