Hi,

 

No operation in Gecode is thread safe (by design). So, when you want to
create a clone of a space, only one thread can do that at a time (and you
have make sure that clone is called with false as argument for share). If
that turns out to be a bottleneck for your application: if you have created
an unshared clone c from a space s, then of course two threads can create
clones in parallel: one from c and one from s.

 

Christian

 

From: [email protected] [mailto:[email protected]] On Behalf
Of Jérémie Vautard
Sent: Friday, May 29, 2009 1:46 PM
To: gecode list
Subject: [gecode-users] Thread-safe space copying

 

Hi all, 

 

I have several threads that might clone a same Gecode::Space object at the
same time. Is the Space.clone(...) method thread safe, or should I ensure
that it is never concurently called ? 

 

Cheers, 

 

 

-- 

Jérémie Vautard

Doctorant/Ph-D Student

LIFO - Laboratoire d'Informatique Fondamentale d'Orléans

Batiment IIIA

Rue Léonard de Vinci

B.P. 6759

F-45067 ORLEANS Cedex 2 

Tel: (+33) 02 38 49 48 57

Cell: (+33) 06 65 11 51 7(

http://www.univ-orleans.fr/lifo/Membres/vautard

 

_______________________________________________
Gecode users mailing list
[email protected]
https://www.gecode.org/mailman/listinfo/gecode-users

Reply via email to