summaryrefslogtreecommitdiffstats
path: root/llvm/test
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2014-05-09 21:49:17 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2014-05-09 21:49:17 +0000
commitaa2738291b1ccee80aecdb1f77961dcb0c91d1db (patch)
tree00c5d0f0caad60a755b994a3ab59b39d4114ced3 /llvm/test
parent457aa3bbdda2f29597494476eb3576fb777eba84 (diff)
downloadbcm5719-llvm-aa2738291b1ccee80aecdb1f77961dcb0c91d1db.tar.gz
bcm5719-llvm-aa2738291b1ccee80aecdb1f77961dcb0c91d1db.zip
Don't crash on redefinitions.
One error we were not deleting the alias or putting it in the Module. The end result is that there was an use left of the aliasee when the module was deleted. llvm-svn: 208447
Diffstat (limited to 'llvm/test')
-rw-r--r--llvm/test/Assembler/alias-redefinition.ll7
1 files changed, 7 insertions, 0 deletions
diff --git a/llvm/test/Assembler/alias-redefinition.ll b/llvm/test/Assembler/alias-redefinition.ll
new file mode 100644
index 00000000000..19ad85bf5f5
--- /dev/null
+++ b/llvm/test/Assembler/alias-redefinition.ll
@@ -0,0 +1,7 @@
+; RUN: not llvm-as %s 2>&1 | FileCheck %s
+
+; CHECK: error: redefinition of global named '@bar'
+
+@foo = global i32 0
+@bar = alias i32* @foo
+@bar = alias i32* @foo
OpenPOWER on IntegriCloud