1

In c++ When we parallelize the loop using OpenMP directives, how should we do if we use a instance of the class in the loop and want to keep some members of the class to be private across all threads and others to be shared ?

4

1 回答 1

0

非静态类成员不能单独选择为私有或共享。您只能使整个类对象共享或私有。

于 2012-05-04T16:34:53.337 回答