OpenMP break, continue, return and exceptions

Firstly, my gsoc schedule is a bit unusual, as I will be largely unavailable for heavy coding until the second week of July.

So I’ve been working on OpenMP support, and now it is possible to use break, continue and return in parallel code, by trapping them inside the parallel construct and then propagating after them after the parallel construct. Of course, if you’re returning from multiple threads at the same time, it’s unspecified which value will be returned. Also, if you’re breaking out of these sections, the index variable has an undefined value afterwards (but it is known to be within the range of the prange parameters).

Today Robert merged my with gil branch, so you can now even use GIL-code inside parallel sections, and have exceptions propagate from them. And of course you can still surround those with gil blocks with a nogil-mode try/finally.

About markflorisson

Blog for the Cython gsoc 2011
This entry was posted in Uncategorized. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s