Hi,
would anyone object to making mgiza depend on -std=c++11? I checked, it compiles and works. Since I am contemplating to bring some order into the threading issues, I would appreciate to get rid of pthread, boost::thread and make use of <thread>, <mutex> and stuff. Also it seems <mutex> is faster than pthreads mutexes.

Best,
Marcin

W dniu 22.12.2014 o 17:44, Marcin Junczys-Dowmunt pisze:

Hi Rico,

there is more going on than that. I just disabled all those locks for testing and nothing changes (funnily it's not even crashing). I will try to have a look. Rewriting everything so each thread get's thread-specific datastructures might be more than I am ready to do though. On the other hand, sounds like a good plan for Christmas.

Best,

Marcin

W dniu 2014-12-22 16:12, Rico Sennrich napisaƂ(a):

Marcin Junczys-Dowmunt <junczys@...> writes:
will try to have a look what is going on there (I dread the code), but if
anyone has some ideas, the same experience or wants to help that would be
most welcome. It seems Model 1 is fine, and speed improves with a greater
number of threads, but the other models are off. Also htop shows mgiza is
mostly in kernel-mode (all red bars instead of green) once the HMM
iterations start.

Hi Marcin,

looking at hmm.cpp (lines 446-485), some counts get synchronized between
threads for every sentence. Maybe I missed something and the counts actually
need to be synchronized ASAP, but it looks to me as if every thread could
work with its own data structure, with a single synchronization between
threads after the loop.

best wishes,
Rico

_______________________________________________
Moses-support mailing list
Moses-support@mit.edu  <mailto:Moses-support@mit.edu>
http://mailman.mit.edu/mailman/listinfo/moses-support



_______________________________________________
Moses-support mailing list
Moses-support@mit.edu
http://mailman.mit.edu/mailman/listinfo/moses-support

_______________________________________________
Moses-support mailing list
Moses-support@mit.edu
http://mailman.mit.edu/mailman/listinfo/moses-support

Reply via email to