Debian Codegraph @

src/f32-vsqrt/gen/f32-vsqrt-scalar-sqrt-u1.c

raw symbols SCIP
1 // Auto-generated file. Do not edit!
2 // Template: src/f32-vsqrt/scalar-sqrt.c.in
3 // Generator: tools/xngen
4 //
5 // Copyright 2020 Google LLC
6 //
7 // This source code is licensed under the BSD-style license found in the
8 // LICENSE file in the root directory of this source tree.
9
10 #include <assert.h>
11 #include <math.h>
12
13 #include "xnnpack/common.h"
14 #include "xnnpack/vunary.h"
15
16
17 void xnn_f32_vsqrt_ukernel__scalar_sqrt_u1(
18 size_t batch,
19 const float* input,
20 float* output,
21 const struct xnn_f32_default_params params[restrict XNN_MIN_ELEMENTS(1)])
22 {
23 assert(batch != 0);
24 assert(batch % sizeof(float) == 0);
25 assert(input != NULL);
26 assert(output != NULL);
27
28 for (; batch >= sizeof(float); batch -= sizeof(float)) {
29 const float vx = *input++;
30 const float vy = sqrtf(vx);
31 *output++ = vy;
32 }
33 }