]> git.djapps.eu Git - pkg/ggml/sources/ggml/commit
cuda : suppress 'noreturn' warn in no_device_code (llama/8414)
authorDaniel Bevenius <redacted>
Thu, 11 Jul 2024 15:53:42 +0000 (17:53 +0200)
committerGeorgi Gerganov <redacted>
Sat, 27 Jul 2024 15:26:12 +0000 (18:26 +0300)
commitc01efb10727cd9ad2f23cd91ed3feead17571aa5
tree53815a9152fc3eda6b67962b1fc4d53d015fcdd0
parent41fac7e3344a3e98245f4d88593efcb3dadb38fa
cuda : suppress 'noreturn' warn in no_device_code (llama/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
/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>
src/ggml-cuda/common.cuh