]> granicus.if.org Git - clang/commitdiff
Fixed "ArgSize may be used uninitialised" error when compiling with gcc.
authorAndy Gibbs <andyg1001@hotmail.co.uk>
Mon, 14 Oct 2013 07:02:04 +0000 (07:02 +0000)
committerAndy Gibbs <andyg1001@hotmail.co.uk>
Mon, 14 Oct 2013 07:02:04 +0000 (07:02 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@192570 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/TargetInfo.cpp

index 8b8c90b3efc51ab1d5915b418898b7596e1bace2..ae44396895d2042ac595ba5527cf03265766b795 100644 (file)
@@ -5444,7 +5444,7 @@ llvm::Value *XCoreABIInfo::EmitVAArg(llvm::Value *VAListAddr, QualType Ty,
     AI.setCoerceToType(ArgTy);
   llvm::Type *ArgPtrTy = llvm::PointerType::getUnqual(ArgTy);
   llvm::Value *Val;
-  uint64_t ArgSize;
+  uint64_t ArgSize = 0;
   switch (AI.getKind()) {
   case ABIArgInfo::Expand:
     llvm_unreachable("Unsupported ABI kind for va_arg");