aboutsummaryrefslogtreecommitdiff
path: root/test/Transforms
diff options
context:
space:
mode:
authorDuncan Sands <baldrick@free.fr>2009-01-05 20:37:33 +0000
committerDuncan Sands <baldrick@free.fr>2009-01-05 20:37:33 +0000
commit1da5f2dd2ec1b1eea67a25928668f7ea2bd67b96 (patch)
tree0f09595bd5b28e582afa7db3777c20be44e42e3b /test/Transforms
parentf42153366176779c79b4351c467712041a8af5f9 (diff)
Delete unused global aliases with internal linkage.
In fact this also deletes those with linkonce linkage, however this is currently dead because for the moment aliases aren't allowed to have this linkage type. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61742 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Transforms')
-rw-r--r--test/Transforms/GlobalDCE/2009-01-05-DeadAliases.ll8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/Transforms/GlobalDCE/2009-01-05-DeadAliases.ll b/test/Transforms/GlobalDCE/2009-01-05-DeadAliases.ll
new file mode 100644
index 0000000000..264b81dca0
--- /dev/null
+++ b/test/Transforms/GlobalDCE/2009-01-05-DeadAliases.ll
@@ -0,0 +1,8 @@
+; RUN: llvm-as < %s | opt -globaldce | llvm-dis | not grep @D
+; RUN: llvm-as < %s | opt -globaldce | llvm-dis | grep @L | count 3
+
+@A = global i32 0
+@D = alias internal i32* @A
+@L1 = alias i32* @A
+@L2 = alias internal i32* @L1
+@L3 = alias i32* @L2