| 8716 | // ggml_compute_forward_step |
| 8717 | |
| 8718 | static void ggml_compute_forward_step_f32( |
| 8719 | const struct ggml_compute_params * params, |
| 8720 | const struct ggml_tensor * src0, |
| 8721 | struct ggml_tensor * dst) { |
| 8722 | assert(params->ith == 0); |
| 8723 | assert(ggml_are_same_shape(src0, dst)); |
| 8724 | |
| 8725 | if (params->type == GGML_TASK_INIT || params->type == GGML_TASK_FINALIZE) { |
| 8726 | return; |
| 8727 | } |
| 8728 | |
| 8729 | const int n = ggml_nrows(src0); |
| 8730 | const int nc = src0->ne[0]; |
| 8731 | |
| 8732 | assert(dst->nb[0] == sizeof(float)); |
| 8733 | assert(src0->nb[0] == sizeof(float)); |
| 8734 | |
| 8735 | for (int i = 0; i < n; i++) { |
| 8736 | ggml_vec_step_f32(nc, |
| 8737 | (float *) ((char *) dst->data + i*( dst->nb[1])), |
| 8738 | (float *) ((char *) src0->data + i*(src0->nb[1]))); |
| 8739 | } |
| 8740 | } |
| 8741 | |
| 8742 | static void ggml_compute_forward_step( |
| 8743 | const struct ggml_compute_params * params, |
no test coverage detected