[Hexagon] Expand handling of the small-data/bss section
llvm-svn: 267034
diff --git a/llvm/test/CodeGen/Hexagon/sdata-array.ll b/llvm/test/CodeGen/Hexagon/sdata-array.ll
new file mode 100644
index 0000000..89ef460
--- /dev/null
+++ b/llvm/test/CodeGen/Hexagon/sdata-array.ll
@@ -0,0 +1,13 @@
+; RUN: llc -march=hexagon < %s | FileCheck %s
+
+; No arrays in sdata.
+; CHECK: memb(##foo)
+
+@foo = common global [4 x i8] zeroinitializer, align 1
+
+define void @set() nounwind {
+entry:
+ store i8 0, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @foo, i32 0, i32 0), align 1
+ ret void
+}
+