-
Committer:
Lawrence Mitchell
-
Date:
2012-04-17 11:49:11 UTC
-
mto:
(4003.1.39 fluidity)
-
mto:
This revision was merged to the branch mainline in
revision
3984.
-
Revision ID:
lawrence.mitchell@ed.ac.uk-20120417114911-82uckx7nedmf4q7h
Add procedure to abort if we're in an omp parallel region
Some set up routines are known not to be thread-safe. If called in a
parallel region, race conditions may lead to invalid code. To guard
against accidental usage in a threaded region, add an abort to known
thread-unsafe functions. The new subroutine
abort_if_in_parallel_region wraps this check and should be called at
the beginning of thread-unsafe procedures.