llama.cpp/ggml/src/kompute-shaders
Daniel Bevenius 06943a69f6
ggml : move rope type enum to ggml.h (#8949)
* ggml : move rope type enum to ggml.h

This commit moves the `llama_rope_type` enum from `llama.h` to
`ggml.h` and changes its name to `ggml_rope_type`.

The motivation for this change is to address the TODO in `llama.h` and
use the enum in ggml.

Note: This commit does not change the `mode` parameter to be of type
`enum ggml_rope_type`. The name `mode` and its usage suggest that it
might be more generic and possibly used as a bit field for multiple
flags. Further investigation/discussion may be needed to determine
if `mode` should be restricted to RoPE types.

* squash! ggml : move rope type enum to ggml.h

This commit removes GGML_ROPE_TYPE_NONE and GGML_ROPE_TYPE_GLM from
ggml.h, and back the llama_rope_type enum.

I've kept the assert for GGML_ROPE_TYPE_GLM as I'm not sure if it is
safe to remove it yet.

* squash! ggml : move rope type enum to ggml.h

This commit removes the enum ggml_rope_type from ggml.h and replaces it
with a define (GGML_ROPE_TYPE_NEOX). This define is used in the code to
check if the mode is set to GPT-NeoX. Also the enum llama_rope_type has
been updated to reflect this change.

* squash! ggml : move rope type enum to ggml.h

This commit contains a suggestion enable the GGML_ROPE_TYPE_NEOX
macro/define to be passed to the shader compiler.

* squash! ggml : move rope type enum to ggml.h

This commit fixes the editorconfig-checker warnings.

* squash! ggml : move rope type enum to ggml.h

Update comment for ggml_rope function.

* Revert "squash! ggml : move rope type enum to ggml.h"

This reverts commit 6261222bd0.

* squash! ggml : move rope type enum to ggml.h

Add GGML_ROPE_TYPE_NEOX to rope_common.comp.

* remove extra line

---------

Co-authored-by: slaren <slarengh@gmail.com>
2024-08-13 21:13:15 +02:00
..
common.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_add.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_addrow.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_cpy_f16_f16.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_cpy_f16_f32.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_cpy_f32_f16.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_cpy_f32_f32.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_diagmask.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_gelu.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_getrows_f16.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_getrows_f32.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_getrows_q4_0.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_getrows_q4_1.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_getrows_q6_k.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_getrows.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_mul_mat_f16.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_mul_mat_mat_f32.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_mul_mat_q4_0.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_mul_mat_q4_1.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_mul_mat_q6_k.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_mul_mat_q8_0.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_mul_mv_q_n_pre.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_mul_mv_q_n.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_mul.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_norm.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_relu.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_rmsnorm.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_rope_f16.comp ggml : move rope type enum to ggml.h (#8949) 2024-08-13 21:13:15 +02:00
op_rope_f32.comp ggml : move rope type enum to ggml.h (#8949) 2024-08-13 21:13:15 +02:00
op_scale_8.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_scale.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_silu.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
op_softmax.comp llama : reorganize source code + improve CMake (#8006) 2024-06-26 18:33:02 +03:00
rope_common.comp ggml : move rope type enum to ggml.h (#8949) 2024-08-13 21:13:15 +02:00