Debian Codegraph @

clang/test/CodeGen/AArch64/neon-fp8-intrinsics/acle_neon_fscale.c

raw
1 // NOTE: Assertions have been autogenerated by utils/update_cc_test_checks.py UTC_ARGS: --version 4
2 // REQUIRES: aarch64-registered-target
3 #include <arm_neon.h>
4
5 // RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +neon -target-feature +fp8 -O3 -emit-llvm -o - %s | FileCheck %s
6 // RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +neon -target-feature +fp8 -S -O3 -o /dev/null %s
7
8 // CHECK-LABEL: define dso_local <4 x half> @test_vscale_f16(
9 // CHECK-SAME: <4 x half> noundef [[VN:%.*]], <4 x i16> noundef [[VM:%.*]]) local_unnamed_addr #[[ATTR0:[0-9]+]] {
10 // CHECK-NEXT: entry:
11 // CHECK-NEXT: [[FSCALE2_I:%.*]] = tail call <4 x half> @llvm.aarch64.neon.fp8.fscale.v4f16(<4 x half> [[VN]], <4 x i16> [[VM]])
12 // CHECK-NEXT: ret <4 x half> [[FSCALE2_I]]
13 //
14 float16x4_t test_vscale_f16(float16x4_t vn, int16x4_t vm) {
15 return vscale_f16(vn, vm);
16 }
17
18 // CHECK-LABEL: define dso_local <8 x half> @test_vscaleq_f16(
19 // CHECK-SAME: <8 x half> noundef [[VN:%.*]], <8 x i16> noundef [[VM:%.*]]) local_unnamed_addr #[[ATTR0]] {
20 // CHECK-NEXT: entry:
21 // CHECK-NEXT: [[FSCALE2_I:%.*]] = tail call <8 x half> @llvm.aarch64.neon.fp8.fscale.v8f16(<8 x half> [[VN]], <8 x i16> [[VM]])
22 // CHECK-NEXT: ret <8 x half> [[FSCALE2_I]]
23 //
24 float16x8_t test_vscaleq_f16(float16x8_t vn, int16x8_t vm) {
25 return vscaleq_f16(vn, vm);
26
27 }
28
29 // CHECK-LABEL: define dso_local <2 x float> @test_vscale_f32(
30 // CHECK-SAME: <2 x float> noundef [[VN:%.*]], <2 x i32> noundef [[VM:%.*]]) local_unnamed_addr #[[ATTR0]] {
31 // CHECK-NEXT: entry:
32 // CHECK-NEXT: [[FSCALE2_I:%.*]] = tail call <2 x float> @llvm.aarch64.neon.fp8.fscale.v2f32(<2 x float> [[VN]], <2 x i32> [[VM]])
33 // CHECK-NEXT: ret <2 x float> [[FSCALE2_I]]
34 //
35 float32x2_t test_vscale_f32(float32x2_t vn, int32x2_t vm) {
36 return vscale_f32(vn, vm);
37
38 }
39
40 // CHECK-LABEL: define dso_local <4 x float> @test_vscaleq_f32(
41 // CHECK-SAME: <4 x float> noundef [[VN:%.*]], <4 x i32> noundef [[VM:%.*]]) local_unnamed_addr #[[ATTR0]] {
42 // CHECK-NEXT: entry:
43 // CHECK-NEXT: [[FSCALE2_I:%.*]] = tail call <4 x float> @llvm.aarch64.neon.fp8.fscale.v4f32(<4 x float> [[VN]], <4 x i32> [[VM]])
44 // CHECK-NEXT: ret <4 x float> [[FSCALE2_I]]
45 //
46 float32x4_t test_vscaleq_f32(float32x4_t vn, int32x4_t vm) {
47 return vscaleq_f32(vn, vm);
48
49 }
50
51 // CHECK-LABEL: define dso_local <2 x double> @test_vscale_f64(
52 // CHECK-SAME: <2 x double> noundef [[VN:%.*]], <2 x i64> noundef [[VM:%.*]]) local_unnamed_addr #[[ATTR0]] {
53 // CHECK-NEXT: entry:
54 // CHECK-NEXT: [[FSCALE2_I:%.*]] = tail call <2 x double> @llvm.aarch64.neon.fp8.fscale.v2f64(<2 x double> [[VN]], <2 x i64> [[VM]])
55 // CHECK-NEXT: ret <2 x double> [[FSCALE2_I]]
56 //
57 float64x2_t test_vscale_f64(float64x2_t vn, int64x2_t vm) {
58 return vscaleq_f64(vn, vm);
59 }