First of all, thank you all people involved in the examples document. It's a great work!
I'm trying to learn about the new 'cancel' directive and I find the examples a bit complicated. In addition to them, I propose a very simple example like this:
- Code: Select all
greater_than_limit = 1;
It only checks if a vector contains any element (no matter which of them) is greater than a defined limit. If this simple function is parallelized via OpenMP 4, I think it could be stopped with 'cancel', but I don't know how. I suggest the addition of this simple example to the document