summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen/NVPTX/global-ctor-empty.ll
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/test/CodeGen/NVPTX/global-ctor-empty.ll')
-rw-r--r--llvm/test/CodeGen/NVPTX/global-ctor-empty.ll5
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/test/CodeGen/NVPTX/global-ctor-empty.ll b/llvm/test/CodeGen/NVPTX/global-ctor-empty.ll
new file mode 100644
index 00000000000..10ca0168b30
--- /dev/null
+++ b/llvm/test/CodeGen/NVPTX/global-ctor-empty.ll
@@ -0,0 +1,5 @@
+; RUN: llc < %s -march=nvptx -mcpu=sm_20 2>&1
+
+; Check that llc doesn't die when given an empty global ctor / dtor.
+@llvm.global_ctors = appending global [0 x { i32, void ()*, i8* }] []
+@llvm.global_dtors = appending global [0 x { i32, void ()*, i8* }] []
OpenPOWER on IntegriCloud