From 210bccc1c217ea7c9ca66e2d3a75f03656b6aab0 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Sun, 23 Nov 2003 18:06:37 +0000 Subject: Fix these assertions: stkrc -e -f -o testing.bc testing.st Global is external, but doesn't have external linkage! [1024 x int]* %_stack_ Global is external, but doesn't have external linkage! long* %_index_ Broken module found, compilation aborted! llvm-svn: 10185 --- llvm/projects/Stacker/lib/compiler/StackerCompiler.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'llvm/projects/Stacker/lib/compiler/StackerCompiler.cpp') diff --git a/llvm/projects/Stacker/lib/compiler/StackerCompiler.cpp b/llvm/projects/Stacker/lib/compiler/StackerCompiler.cpp index 6ebcae9b365..4cd06461030 100644 --- a/llvm/projects/Stacker/lib/compiler/StackerCompiler.cpp +++ b/llvm/projects/Stacker/lib/compiler/StackerCompiler.cpp @@ -132,7 +132,7 @@ StackerCompiler::compile( /*type=*/ stack_type, /*isConstant=*/ false, /*Linkage=*/ GlobalValue::AppendingLinkage, - /*initializer=*/0, + /*initializer=*/Constant::getNullValue(stack_type), /*name=*/ "_stack_", /*parent=*/ TheModule ); @@ -144,7 +144,7 @@ StackerCompiler::compile( /*type=*/Type::LongTy, /*isConstant=*/false, /*Linkage=*/GlobalValue::LinkOnceLinkage, - /*initializer=*/0, + /*initializer=*/Constant::getNullValue(Type::LongTy), /*name=*/"_index_", /*parent=*/TheModule ); -- cgit v1.2.3