[Mesa-dev] [PATCH 1/2] clover: Catch errors from executing event action
Jan Vesely
jan.vesely at rutgers.edu
Tue Jul 17 14:38:46 UTC 2018
Abort all dependent events.
Signed-off-by: Jan Vesely <jan.vesely at rutgers.edu>
---
src/gallium/state_trackers/clover/core/event.cpp | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/src/gallium/state_trackers/clover/core/event.cpp b/src/gallium/state_trackers/clover/core/event.cpp
index cd5d786604..ed2b6ebdb8 100644
--- a/src/gallium/state_trackers/clover/core/event.cpp
+++ b/src/gallium/state_trackers/clover/core/event.cpp
@@ -51,7 +51,12 @@ event::trigger_self() {
void
event::trigger() {
if (wait_count() == 1)
- action_ok(*this);
+ try {
+ action_ok(*this);
+ } catch (error &e) {
+ for (event &ev : abort_self(e.get()))
+ ev.abort(e.get());
+ }
for (event &ev : trigger_self())
ev.trigger();
--
2.16.4
More information about the mesa-dev
mailing list