summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen/Hexagon/sdata-explicit-section.ll
diff options
context:
space:
mode:
authorKrzysztof Parzyszek <kparzysz@codeaurora.org>2018-11-09 17:31:22 +0000
committerKrzysztof Parzyszek <kparzysz@codeaurora.org>2018-11-09 17:31:22 +0000
commit8567de0871618ad4d6c30432f59bc232daa40100 (patch)
tree3837e81531188db727667140671e11b53d136369 /llvm/test/CodeGen/Hexagon/sdata-explicit-section.ll
parent86f8b70f1b7c3f92266197d580f6d86414650997 (diff)
downloadbcm5719-llvm-8567de0871618ad4d6c30432f59bc232daa40100.tar.gz
bcm5719-llvm-8567de0871618ad4d6c30432f59bc232daa40100.zip
[Hexagon] Place globals with explicit .sdata section in small data
Both -fPIC and -G0 disable placement of globals in small data section, but if a global has an explicit section assigmnent placing it in small data, it should go there anyway. llvm-svn: 346523
Diffstat (limited to 'llvm/test/CodeGen/Hexagon/sdata-explicit-section.ll')
-rw-r--r--llvm/test/CodeGen/Hexagon/sdata-explicit-section.ll6
1 files changed, 6 insertions, 0 deletions
diff --git a/llvm/test/CodeGen/Hexagon/sdata-explicit-section.ll b/llvm/test/CodeGen/Hexagon/sdata-explicit-section.ll
new file mode 100644
index 00000000000..807474f4382
--- /dev/null
+++ b/llvm/test/CodeGen/Hexagon/sdata-explicit-section.ll
@@ -0,0 +1,6 @@
+; RUN: llc -march=hexagon -hexagon-small-data-threshold=0 < %s | FileCheck %s
+; RUN: llc -march=hexagon -relocation-model=pic < %s | FileCheck %s
+
+; CHECK: .section .sdata.4,"aws",@progbits
+@g0 = global i32 zeroinitializer, section ".sdata"
+
OpenPOWER on IntegriCloud