ggml: support CUDA's half type for aarch64(#1455)
support CUDA's half type for aarch64 in ggml_fp16_t definition
This commit is contained in:
parent
1f0bccb279
commit
8a25bd41b3
1 changed files with 3 additions and 1 deletions
4
ggml.h
4
ggml.h
|
@ -255,9 +255,11 @@
|
|||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef __ARM_NEON
|
||||
#if defined(__ARM_NEON) && !defined(GGML_CUDA_F16)
|
||||
// we use the built-in 16-bit float type
|
||||
typedef __fp16 ggml_fp16_t;
|
||||
#elif defined(GGML_CUDA_F16)
|
||||
typedef half ggml_fp16_t;
|
||||
#else
|
||||
typedef uint16_t ggml_fp16_t;
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue