Skip to content

Commit b772f08

Browse files
committed
Address review comments.
1 parent cb8936f commit b772f08

File tree

6 files changed

+96
-37
lines changed

6 files changed

+96
-37
lines changed

clang/include/clang/Basic/DiagnosticSemaKinds.td

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3317,6 +3317,9 @@ def err_sve_vector_in_non_sve_target : Error<
33173317
"SVE vector type %0 cannot be used in a target without sve">;
33183318
def err_sve_vector_in_non_streaming_function : Error<
33193319
"SVE vector type %0 cannot be used in a non-streaming function">;
3320+
def err_sve_fixed_vector_in_streaming_function
3321+
: Error<"fixed width SVE vector type %0 cannot be used in a "
3322+
"%select{streaming|streaming-compatible}1 function">;
33203323
def err_attribute_riscv_rvv_bits_unsupported : Error<
33213324
"%0 is only supported when '-mrvv-vector-bits=<bits>' is specified with a "
33223325
"value of \"zvl\" or a power 2 in the range [64,65536]">;

clang/lib/Basic/Targets/AArch64.cpp

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -825,13 +825,23 @@ AArch64TargetInfo::getVScaleRange(const LangOptions &LangOpts,
825825
if (IsArmStreamingFunction == ArmStreamingKind::NotStreaming &&
826826
(LangOpts.VScaleMin || LangOpts.VScaleMax))
827827
return std::pair<unsigned, unsigned>(
828-
LangOpts.VScaleMin ? LangOpts.VScaleMin : 1, LangOpts.VScaleMax);
828+
LangOpts.VScaleMin ? LangOpts.VScaleMin : 1, LangOpts.VScaleMax ? LangOpts.VScaleMax : 16);
829829

830830
if (IsArmStreamingFunction == ArmStreamingKind::Streaming &&
831831
(LangOpts.VScaleStreamingMin || LangOpts.VScaleStreamingMax))
832832
return std::pair<unsigned, unsigned>(
833833
LangOpts.VScaleStreamingMin ? LangOpts.VScaleStreamingMin : 1,
834-
LangOpts.VScaleStreamingMax);
834+
LangOpts.VScaleStreamingMax ? LangOpts.VScaleStreamingMax : 16);
835+
836+
if (IsArmStreamingFunction == ArmStreamingKind::StreamingCompatible &&
837+
((LangOpts.VScaleMin && LangOpts.VScaleStreamingMin) ||
838+
(LangOpts.VScaleMax && LangOpts.VScaleStreamingMax))) {
839+
unsigned Min = std::min(LangOpts.VScaleMin ? LangOpts.VScaleMin : 1,
840+
LangOpts.VScaleStreamingMin ? LangOpts.VScaleStreamingMin : 1);
841+
unsigned Max = std::max(LangOpts.VScaleMax ? LangOpts.VScaleMax : 16,
842+
LangOpts.VScaleStreamingMax ? LangOpts.VScaleStreamingMax : 16);
843+
return std::pair(Min, Max);
844+
}
835845

836846
if (hasFeature("sve") || (FeatureMap && (FeatureMap->lookup("sve"))))
837847
return std::pair<unsigned, unsigned>(1, 16);

clang/lib/Driver/ToolChains/Clang.cpp

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1666,7 +1666,8 @@ void Clang::AddAArch64TargetArgs(const ArgList &Args,
16661666
}
16671667

16681668
// Handle -msve_vector_bits=<bits>
1669-
auto HandleVectorBits = [&](Arg *A, bool Streaming) {
1669+
auto HandleVectorBits = [&](Arg *A, StringRef VScaleMin,
1670+
StringRef VScaleMax) {
16701671
StringRef Val = A->getValue();
16711672
const Driver &D = getToolChain().getDriver();
16721673
if (Val == "128" || Val == "256" || Val == "512" || Val == "1024" ||
@@ -1677,8 +1678,6 @@ void Clang::AddAArch64TargetArgs(const ArgList &Args,
16771678
bool Invalid = Val.getAsInteger(10, Bits);
16781679
(void)Invalid;
16791680
assert(!Invalid && "Failed to parse value");
1680-
StringRef VScaleMax =
1681-
Streaming ? "-mvscale-streaming-max=" : "-mvscale-max=";
16821681
CmdArgs.push_back(
16831682
Args.MakeArgString(VScaleMax + llvm::Twine(Bits / 128)));
16841683
}
@@ -1687,8 +1686,6 @@ void Clang::AddAArch64TargetArgs(const ArgList &Args,
16871686
(void)Invalid;
16881687
assert(!Invalid && "Failed to parse value");
16891688

1690-
StringRef VScaleMin =
1691-
Streaming ? "-mvscale-streaming-min=" : "-mvscale-min=";
16921689
CmdArgs.push_back(
16931690
Args.MakeArgString(VScaleMin + llvm::Twine(Bits / 128)));
16941691
} else if (Val == "scalable") {
@@ -1700,9 +1697,9 @@ void Clang::AddAArch64TargetArgs(const ArgList &Args,
17001697
}
17011698
};
17021699
if (Arg *A = Args.getLastArg(options::OPT_msve_vector_bits_EQ))
1703-
HandleVectorBits(A, /*Streaming*/ false);
1700+
HandleVectorBits(A, "-mvscale-min=", "-mvscale-max=");
17041701
if (Arg *A = Args.getLastArg(options::OPT_msve_streaming_vector_bits_EQ))
1705-
HandleVectorBits(A, /*Streaming*/ true);
1702+
HandleVectorBits(A, "-mvscale-streaming-min=", "-mvscale-streaming-max=");
17061703

17071704
AddAAPCSVolatileBitfieldArgs(Args, CmdArgs);
17081705

clang/lib/Sema/Sema.cpp

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2270,6 +2270,21 @@ void Sema::checkTypeSupport(QualType Ty, SourceLocation Loc, ValueDecl *D) {
22702270
}
22712271
}
22722272
}
2273+
2274+
if (auto *VT = Ty->getAs<VectorType>();
2275+
VT && FD &&
2276+
(VT->getVectorKind() == VectorKind::SveFixedLengthData ||
2277+
VT->getVectorKind() == VectorKind::SveFixedLengthPredicate)) {
2278+
if (IsArmStreamingFunction(FD, /*IncludeLocallyStreaming=*/true)) {
2279+
Diag(Loc, diag::err_sve_fixed_vector_in_streaming_function) << Ty << 0;
2280+
} else if (const auto *FTy = FD->getType()->getAs<FunctionProtoType>()) {
2281+
if (FTy->getAArch64SMEAttributes() &
2282+
FunctionType::SME_PStateSMCompatibleMask) {
2283+
Diag(Loc, diag::err_sve_fixed_vector_in_streaming_function)
2284+
<< Ty << 1;
2285+
}
2286+
}
2287+
}
22732288
};
22742289

22752290
CheckType(Ty);
Lines changed: 36 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,53 +1,66 @@
11
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -mvscale-min=1 -mvscale-max=1 -emit-llvm -o - %s | \
2-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-MINMAX,CHECK-NOSTREAMING -D#VBITS=1
2+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-MINMAX,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE -D#VBITS=1
33
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -mvscale-min=2 -mvscale-max=2 -emit-llvm -o - %s | \
4-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-MINMAX,CHECK-NOSTREAMING -D#VBITS=2
4+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-MINMAX,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE -D#VBITS=2
55
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -mvscale-min=4 -mvscale-max=4 -emit-llvm -o - %s | \
6-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-MINMAX,CHECK-NOSTREAMING -D#VBITS=4
6+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-MINMAX,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE -D#VBITS=4
77
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -mvscale-min=8 -mvscale-max=8 -emit-llvm -o - %s | \
8-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-MINMAX,CHECK-NOSTREAMING -D#VBITS=8
8+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-MINMAX,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE -D#VBITS=8
99
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -mvscale-min=16 -mvscale-max=16 -emit-llvm -o - %s | \
10-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-MINMAX,CHECK-NOSTREAMING -D#VBITS=16
10+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-MINMAX,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE -D#VBITS=16
1111
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve2 -target-feature +sme -mvscale-min=1 -mvscale-max=1 -emit-llvm -o - %s | \
12-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-MINMAX,CHECK-NOSTREAMING -D#VBITS=1
12+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-MINMAX,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE -D#VBITS=1
1313
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve2 -target-feature +sme -mvscale-min=2 -mvscale-max=2 -emit-llvm -o - %s | \
14-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-MINMAX,CHECK-NOSTREAMING -D#VBITS=2
14+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-MINMAX,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE -D#VBITS=2
1515
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -mvscale-min=1 -emit-llvm -o - %s | \
16-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NOMAX,CHECK-NOSTREAMING -D#VBITS=1
16+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NOMAX,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE -D#VBITS=1
1717
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -mvscale-min=2 -emit-llvm -o - %s | \
18-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NOMAX,CHECK-NOSTREAMING -D#VBITS=2
18+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NOMAX,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE -D#VBITS=2
1919
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -mvscale-min=4 -emit-llvm -o - %s | \
20-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NOMAX,CHECK-NOSTREAMING -D#VBITS=4
20+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NOMAX,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE -D#VBITS=4
2121
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -mvscale-min=8 -emit-llvm -o - %s | \
22-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NOMAX,CHECK-NOSTREAMING -D#VBITS=8
22+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NOMAX,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE -D#VBITS=8
2323
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -mvscale-min=16 -emit-llvm -o - %s | \
24-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NOMAX,CHECK-NOSTREAMING -D#VBITS=16
24+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NOMAX,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE -D#VBITS=16
2525
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve2 -target-feature +sme -mvscale-min=1 -mvscale-max=0 -emit-llvm -o - %s | \
26-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-UNBOUNDED,CHECK-NOSTREAMING
26+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-UNBOUNDED,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE
2727
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -mvscale-min=1 -mvscale-max=0 -emit-llvm -o - %s | \
28-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-UNBOUNDED,CHECK-NOSTREAMING
28+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-UNBOUNDED,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE
2929
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -emit-llvm -o - %s | \
30-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NONE,CHECK-NOSTREAMING
30+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NONE,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE
3131
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -target-feature +sme -emit-llvm -o - %s | \
32-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NONE,CHECK-NOSTREAMING
32+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NONE,CHECK-NOSTREAMING,CHECK-NOCOMPATIBLE
3333
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -target-feature +sme -mvscale-streaming-min=1 -mvscale-streaming-max=1 -emit-llvm -o - %s | \
34-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NONE,CHECK-STREAMING -D#STREAMINGVBITS=1
34+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NONE,CHECK-STREAMING,CHECK-NOCOMPATIBLE -D#STREAMINGVBITS=1
3535
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -target-feature +sme -mvscale-streaming-min=4 -mvscale-streaming-max=4 -emit-llvm -o - %s | \
36-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NONE,CHECK-STREAMING -D#STREAMINGVBITS=4
36+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NONE,CHECK-STREAMING,CHECK-NOCOMPATIBLE -D#STREAMINGVBITS=4
3737
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -target-feature +sme -mvscale-streaming-min=4 -emit-llvm -o - %s | \
38-
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NONE,CHECK-STREAMING-NOMAX -D#STREAMINGVBITS=4
38+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NONE,CHECK-STREAMING-NOMAX,CHECK-NOCOMPATIBLE -D#STREAMINGVBITS=4
39+
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -target-feature +sme -mvscale-min=2 -mvscale-streaming-min=4 -emit-llvm -o - %s | \
40+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NOMAX,CHECK-STREAMING-NOMAX,CHECK-COMPATIBLE-NOMAX -D#VBITS=2 -D#STREAMINGVBITS=4
41+
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -target-feature +sme -mvscale-max=2 -mvscale-streaming-max=4 -emit-llvm -o - %s | \
42+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-NOMIN,CHECK-STREAMING-NOMIN,CHECK-COMPATIBLE-NOMIN -D#VBITS=2 -D#STREAMINGVBITS=4
43+
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +sme -target-feature +sme \
44+
// RUN: -mvscale-min=2 -mvscale-streaming-min=4 -mvscale-max=2 -mvscale-streaming-max=4 -emit-llvm -o - %s | \
45+
// RUN: FileCheck %s --check-prefixes=CHECK,CHECK-MINMAX,CHECK-STREAMING,CHECK-COMPATIBLE -D#VBITS=2 -D#STREAMINGVBITS=4
46+
3947

4048
// CHECK-LABEL: @func() #0
4149
// CHECK-LABEL: @func2() #1
4250
// CHECK-LABEL: @func3() #2
4351
// CHECK-MINMAX: attributes #0 = { {{.*}} vscale_range([[#VBITS]],[[#VBITS]]) {{.*}} }
44-
// CHECK-NOMAX: attributes #0 = { {{.*}} vscale_range([[#VBITS]],0) {{.*}} }
45-
// CHECK-UNBOUNDED: attributes #0 = { {{.*}} vscale_range(1,0) {{.*}} }
52+
// CHECK-NOMAX: attributes #0 = { {{.*}} vscale_range([[#VBITS]],16) {{.*}} }
53+
// CHECK-NOMIN: attributes #0 = { {{.*}} vscale_range(1,[[#VBITS]]) {{.*}} }
54+
// CHECK-UNBOUNDED: attributes #0 = { {{.*}} vscale_range(1,16) {{.*}} }
4655
// CHECK-NONE: attributes #0 = { {{.*}} vscale_range(1,16) {{.*}} }
4756
// CHECK-STREAMING: attributes #1 = { {{.*}} vscale_range([[#STREAMINGVBITS]],[[#STREAMINGVBITS]])
48-
// CHECK-STREAMING-NOMAX: attributes #1 = { {{.*}} vscale_range([[#STREAMINGVBITS]],0)
57+
// CHECK-STREAMING-NOMAX: attributes #1 = { {{.*}} vscale_range([[#STREAMINGVBITS]],16)
58+
// CHECK-STREAMING-NOMIN: attributes #1 = { {{.*}} vscale_range(1,[[#STREAMINGVBITS]]) {{.*}} }
4959
// CHECK-NOSTREAMING: attributes #1 = { {{.*}} vscale_range(1,16) {{.*}} }
50-
// CHECK: attributes #2 = { {{.*}} vscale_range(1,16) {{.*}} }
60+
// CHECK-NOCOMPATIBLE: attributes #2 = { {{.*}} vscale_range(1,16) {{.*}} }
61+
// CHECK-COMPATIBLE: attributes #2 = { {{.*}} vscale_range([[#VBITS]],[[#STREAMINGVBITS]]) {{.*}} }
62+
// CHECK-COMPATIBLE-NOMAX: attributes #2 = { {{.*}} vscale_range([[#VBITS]],16) {{.*}} }
63+
// CHECK-COMPATIBLE-NOMIN: attributes #2 = { {{.*}} vscale_range(1,[[#STREAMINGVBITS]]) {{.*}} }
5164
void func(void) {}
5265
__arm_locally_streaming void func2(void) {}
5366
void func3(void) __arm_streaming_compatible {}

clang/test/Sema/attr-arm-sve-vector-bits.c

Lines changed: 26 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +bf16 -ffreestanding -fsyntax-only -verify -mvscale-min=1 -mvscale-max=1 %s
2-
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +bf16 -ffreestanding -fsyntax-only -verify -mvscale-min=2 -mvscale-max=2 %s
3-
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +bf16 -ffreestanding -fsyntax-only -verify -mvscale-min=4 -mvscale-max=4 %s
4-
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +bf16 -ffreestanding -fsyntax-only -verify -mvscale-min=8 -mvscale-max=8 %s
5-
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +bf16 -ffreestanding -fsyntax-only -verify -mvscale-min=16 -mvscale-max=16 %s
1+
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +bf16 -target-feature +sme -ffreestanding -fsyntax-only -verify -mvscale-min=1 -mvscale-max=1 %s
2+
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +bf16 -target-feature +sme -ffreestanding -fsyntax-only -verify -mvscale-min=2 -mvscale-max=2 %s
3+
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +bf16 -target-feature +sme -ffreestanding -fsyntax-only -verify -mvscale-min=4 -mvscale-max=4 %s
4+
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +bf16 -target-feature +sme -ffreestanding -fsyntax-only -verify -mvscale-min=8 -mvscale-max=8 %s
5+
// RUN: %clang_cc1 -triple aarch64-none-linux-gnu -target-feature +sve -target-feature +bf16 -target-feature +sme -ffreestanding -fsyntax-only -verify -mvscale-min=16 -mvscale-max=16 %s
66

77
#include <stdint.h>
88

@@ -382,3 +382,24 @@ TEST_INT_OPS(fixed_uint64_t)
382382
TEST_OPS(fixed_float16_t)
383383
TEST_OPS(fixed_float32_t)
384384
TEST_OPS(fixed_float64_t)
385+
386+
// --------------------------------------------------------------------------//
387+
// Streaming
388+
__arm_locally_streaming void locally_streaming() {
389+
svint8_t t1 = extern_int8; // expected-error {{cannot be used in a streaming function}}
390+
svbool_t t2 = extern_bool; // expected-error {{cannot be used in a streaming function}}
391+
void* t3 = extern_int8_ptr;
392+
}
393+
void streaming(void) __arm_streaming {
394+
svint8_t t1 = extern_int8; // expected-error {{cannot be used in a streaming function}}
395+
svbool_t t2 = extern_bool; // expected-error {{cannot be used in a streaming function}}
396+
void* t3 = extern_int8_ptr;
397+
}
398+
void streaming_compatible(void) __arm_streaming_compatible {
399+
svint8_t t1 = extern_int8; // expected-error {{cannot be used in a streaming-compatible function}} \
400+
// expected-error {{initializing}}
401+
svbool_t t2 = extern_bool; // expected-error {{cannot be used in a streaming-compatible function}} \
402+
// expected-error {{initializing}}
403+
void* t3 = extern_int8_ptr;
404+
}
405+
__arm_locally_streaming void locally_streaming_arg(fixed_int8_t x) {} // expected-error {{cannot be used in a streaming function}}

0 commit comments

Comments
 (0)