| { | |
| "name": "reference_loop_029", | |
| "definition": "loop_029", | |
| "dataset": "simd-loop", | |
| "author": "reference", | |
| "spec": { | |
| "language": "cpp", | |
| "target_hardware": [ | |
| "aarch64" | |
| ], | |
| "entry_point": "kernel.cpp::inner_loop_029", | |
| "dependencies": [], | |
| "isa_features": [], | |
| "compile_flags": [ | |
| "-O2", | |
| "-std=c++14", | |
| "-fno-vectorize", | |
| "-fno-slp-vectorize" | |
| ], | |
| "link_flags": [] | |
| }, | |
| "sources": [ | |
| { | |
| "path": "loop_029.h", | |
| "content": "// Auto-generated by scripts/gen_simd_loop_harness.py \u2014 do not hand-edit.\n#pragma once\n#include <stdint.h>\n\nstruct loop_029_data {\n double *input;\n int64_t *scale;\n double *output;\n int64_t size;\n};\n\n#ifdef __cplusplus\nextern \"C\" {\n#endif\nint armbench_entry_loop_029(void *input, void *scale, int64_t n, void *res_out);\n#ifdef __cplusplus\n}\n#endif\n" | |
| }, | |
| { | |
| "path": "loop_029.cpp", | |
| "content": "// Auto-generated by scripts/gen_simd_loop_harness.py \u2014 do not hand-edit.\n#include \"loop_029.h\"\n#include <stdint.h>\n\nextern \"C\" void inner_loop_029(struct loop_029_data *data);\n\nextern \"C\" int armbench_entry_loop_029(void *input, void *scale, int64_t n, void *res_out) {\n struct loop_029_data data;\n data.input = static_cast<double *>(input);\n data.scale = static_cast<int64_t *>(scale);\n data.output = static_cast<double *>(res_out);\n data.size = static_cast<int64_t>(n);\n inner_loop_029(&data);\n return 0;\n}\n" | |
| }, | |
| { | |
| "path": "kernel.cpp", | |
| "content": "#include \"loop_029.h\"\n#include <stdint.h>\n\nextern \"C\" void inner_loop_029(struct loop_029_data * data) {\n double *input = data->input;\n int64_t *scale = data->scale;\n double *output = data->output;\n int64_t size = data->size;\n\n for (int64_t i = 0; i < size; i++) {\n output[i] = __builtin_scalbn(input[i], (int)scale[i]);\n }\n}\n" | |
| } | |
| ], | |
| "description": "Scalar reference (auto-vectorization disabled) for loop_029. Baseline for speedup measurement." | |
| } | |