diff --git a/CHANGELOG.md b/CHANGELOG.md index 2d22bbbbdf..01d7b2ec87 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -27,6 +27,9 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. interface are now often better - although there are still cases where you end up with hashed names. (#2172) +* In some cases, GPU failures would not be reported properly if a + previous failure was pending. + ## [0.25.20] ### Added diff --git a/rts/c/backends/cuda.h b/rts/c/backends/cuda.h index 8c91d8cf4e..64fa9a37b7 100644 --- a/rts/c/backends/cuda.h +++ b/rts/c/backends/cuda.h @@ -17,10 +17,10 @@ static char* get_failure_msg(int failure_idx, int64_t args[]); if (serror) { \ if (!ctx->error) { \ ctx->error = serror; \ - return bad; \ } else { \ free(serror); \ } \ + return bad; \ } \ } diff --git a/rts/c/backends/hip.h b/rts/c/backends/hip.h index 63aad6b042..5eae7c68f4 100644 --- a/rts/c/backends/hip.h +++ b/rts/c/backends/hip.h @@ -17,10 +17,10 @@ static char* get_failure_msg(int failure_idx, int64_t args[]); if (serror) { \ if (!ctx->error) { \ ctx->error = serror; \ - return bad; \ } else { \ free(serror); \ } \ + return bad; \ } \ } diff --git a/rts/c/backends/opencl.h b/rts/c/backends/opencl.h index e5bae526af..f9b1f9b91c 100644 --- a/rts/c/backends/opencl.h +++ b/rts/c/backends/opencl.h @@ -30,10 +30,10 @@ static char* get_failure_msg(int failure_idx, int64_t args[]); if (serror) { \ if (!ctx->error) { \ ctx->error = serror; \ - return bad; \ } else { \ free(serror); \ } \ + return bad; \ } \ }