// NOTE: File has been autogenerated by utils/aarch64_builtins_test_generator.py
// RUN: %clang_cc1 %s -fsyntax-only -triple aarch64-none-linux-gnu -target-feature +bf16 -target-feature +sme -target-feature +sve -verify=guard

// REQUIRES: aarch64-registered-target

#include <arm_sve.h>

// Properties: guard="sve,bf16" streaming_guard="" flags=""

void test(void) {
  svbfloat16_t svbfloat16_t_val;
  svfloat32_t svfloat32_t_val;

  svbfmmla(svfloat32_t_val, svbfloat16_t_val, svbfloat16_t_val);
  svbfmmla_f32(svfloat32_t_val, svbfloat16_t_val, svbfloat16_t_val);
}

void test_streaming(void) __arm_streaming{
  svbfloat16_t svbfloat16_t_val;
  svfloat32_t svfloat32_t_val;

  // guard-error@+1 {{builtin can only be called from a non-streaming function}}
  svbfmmla(svfloat32_t_val, svbfloat16_t_val, svbfloat16_t_val);
  // guard-error@+1 {{builtin can only be called from a non-streaming function}}
  svbfmmla_f32(svfloat32_t_val, svbfloat16_t_val, svbfloat16_t_val);
}

void test_streaming_compatible(void) __arm_streaming_compatible{
  svbfloat16_t svbfloat16_t_val;
  svfloat32_t svfloat32_t_val;

  // guard-error@+1 {{builtin can only be called from a non-streaming function}}
  svbfmmla(svfloat32_t_val, svbfloat16_t_val, svbfloat16_t_val);
  // guard-error@+1 {{builtin can only be called from a non-streaming function}}
  svbfmmla_f32(svfloat32_t_val, svbfloat16_t_val, svbfloat16_t_val);
}
