From: Simon Pilgrim Date: Thu, 14 Nov 2019 13:55:28 +0000 (+0000) Subject: GCOVProfiling - fix uninitialized variable warnings + make getFuncChecksum() const... X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=edfc94e296f1faa6414ac91b86856b107a0568ac;p=platform%2Fupstream%2Fllvm.git GCOVProfiling - fix uninitialized variable warnings + make getFuncChecksum() const. NFCI. --- diff --git a/llvm/lib/Transforms/Instrumentation/GCOVProfiling.cpp b/llvm/lib/Transforms/Instrumentation/GCOVProfiling.cpp index b2f299a..bda3287 100644 --- a/llvm/lib/Transforms/Instrumentation/GCOVProfiling.cpp +++ b/llvm/lib/Transforms/Instrumentation/GCOVProfiling.cpp @@ -129,9 +129,9 @@ private: // Checksum, produced by hash of EdgeDestinations SmallVector FileChecksums; - Module *M; + Module *M = nullptr; std::function GetTLI; - LLVMContext *Ctx; + LLVMContext *Ctx = nullptr; SmallVector, 16> Funcs; std::vector FilterRe; std::vector ExcludeRe; @@ -385,7 +385,7 @@ namespace { return EdgeDestinations; } - uint32_t getFuncChecksum() { + uint32_t getFuncChecksum() const { return FuncChecksum; }