]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commit
cuda : suppress 'noreturn' warn in no_device_code (#8414)
authorDaniel Bevenius <redacted>
Thu, 11 Jul 2024 15:53:42 +0000 (17:53 +0200)
committerGitHub <redacted>
Thu, 11 Jul 2024 15:53:42 +0000 (17:53 +0200)
commitb078c619aa4e97fe726d61b0b5499a2e19a418a4
tree5629a38ec80a5e55278f0713666764db0bab3890
parent808aba39161e5d7ca2ff24110b5aa14d2e536988
cuda : suppress 'noreturn' warn in no_device_code (#8414)

* cuda : suppress 'noreturn' warn in no_device_code

This commit adds a while(true) loop to the no_device_code function in
common.cuh. This is done to suppress the warning:

```console
/ggml/src/ggml-cuda/template-instances/../common.cuh:346:1: warning:
function declared 'noreturn' should not return [-Winvalid-noreturn]
  346 | }
      | ^
```

The motivation for this is to reduce the number of warnings when
compilng with GGML_HIPBLAS=ON.

Signed-off-by: Daniel Bevenius <redacted>
* squash! cuda : suppress 'noreturn' warn in no_device_code

Update __trap macro instead of using a while loop to suppress the
warning.

Signed-off-by: Daniel Bevenius <redacted>
---------

Signed-off-by: Daniel Bevenius <redacted>
ggml/src/ggml-cuda/common.cuh