blob: 36257a5baee0441458ad07ce27426cf0d62d458e [file] [log] [blame]
David Butcherba4ccf52013-04-22 12:19:32 +01001#pragma version(1)
2#pragma rs java_package_name(android.renderscript.cts)
3
4typedef struct Floats {
5 float fa;
6 float fb;
7 float fc;
8} Floats;
9
Stephen Hinesb3d8d4f2013-05-02 02:14:50 -070010void fma_f32_1(const Floats *in, float *out) {
David Butcherba4ccf52013-04-22 12:19:32 +010011 *out = fma(in->fa, in->fb, in->fc);
Stephen Hinesb3d8d4f2013-05-02 02:14:50 -070012}
13
14typedef struct Floats2 {
15 float2 fa;
16 float2 fb;
17 float2 fc;
18} Floats2;
19
20void fma_f32_2(const Floats2 *in, float2 *out) {
21 *out = fma(in->fa, in->fb, in->fc);
22}
23
24typedef struct Floats3 {
25 float3 fa;
26 float3 fb;
27 float3 fc;
28} Floats3;
29
30void fma_f32_3(const Floats3 *in, float3 *out) {
31 *out = fma(in->fa, in->fb, in->fc);
32}
33
34typedef struct Floats4 {
35 float4 fa;
36 float4 fb;
37 float4 fc;
38} Floats4;
39
40void fma_f32_4(const Floats4 *in, float4 *out) {
41 *out = fma(in->fa, in->fb, in->fc);
42}