diff --git a/lib/Backend/GlobOpt.cpp b/lib/Backend/GlobOpt.cpp index 459e97cbe00..eaaf260e695 100644 --- a/lib/Backend/GlobOpt.cpp +++ b/lib/Backend/GlobOpt.cpp @@ -7507,7 +7507,11 @@ GlobOpt::TypeSpecializeInlineBuiltInBinary(IR::Instr **pInstr, Value *src1Val, V if(src1Val->GetValueInfo()->IsLikelyInt() && src2Val->GetValueInfo()->IsLikelyInt()) { // Compute resulting range info - int32 min1, max1, min2, max2, newMin, newMax; + int32 min1 = INT32_MIN; + int32 max1 = INT32_MAX; + int32 min2 = INT32_MIN; + int32 max2 = INT32_MAX; + int32 newMin, newMax; Assert(this->DoAggressiveIntTypeSpec()); src1Val->GetValueInfo()->GetIntValMinMax(&min1, &max1, this->DoAggressiveIntTypeSpec()); diff --git a/lib/Backend/IntBounds.cpp b/lib/Backend/IntBounds.cpp index 5906a65dfae..845757b270b 100644 --- a/lib/Backend/IntBounds.cpp +++ b/lib/Backend/IntBounds.cpp @@ -178,7 +178,7 @@ void IntBounds::SetBound( // Aggressively merge the constant lower or upper bound of the base value, adjusted by the offset ValueInfo const * const baseValueInfo = baseValue->GetValueInfo(); - int constantBoundBase; + int constantBoundBase = 0xCCCCCCCC; const bool success = Lower ? baseValueInfo->TryGetIntConstantLowerBound(&constantBoundBase, true) @@ -342,7 +342,7 @@ bool IntBounds::IsGreaterThanOrEqualTo(const Value *const value, const int offse Assert(value); ValueInfo const * const valueInfo = value->GetValueInfo(); - int constantBoundBase; + int constantBoundBase = INT32_MAX; const bool success = valueInfo->TryGetIntConstantUpperBound(&constantBoundBase, true); Assert(success); if(IsGreaterThanOrEqualTo(constantBoundBase, offset)) @@ -360,7 +360,7 @@ bool IntBounds::IsLessThanOrEqualTo(const Value *const value, const int offset) Assert(value); ValueInfo const * const valueInfo = value->GetValueInfo(); - int constantBoundBase; + int constantBoundBase = INT32_MIN; const bool success = valueInfo->TryGetIntConstantLowerBound(&constantBoundBase, true); Assert(success); if(IsLessThanOrEqualTo(constantBoundBase, offset)) diff --git a/lib/Backend/Sym.cpp b/lib/Backend/Sym.cpp index 99c3316a60d..e3759125b27 100644 --- a/lib/Backend/Sym.cpp +++ b/lib/Backend/Sym.cpp @@ -572,7 +572,7 @@ StackSym::GetIntConstValue() const { return Js::TaggedInt::ToInt32(var); } - int32 value; + int32 value = 0xCCCCCCCC; const bool isInt32 = Js::JavascriptNumber::TryGetInt32Value(Js::JavascriptNumber::GetValue(var), &value); Assert(isInt32); return value; diff --git a/lib/Backend/ValueInfo.cpp b/lib/Backend/ValueInfo.cpp index 1fbeb4afaae..a06e949e501 100644 --- a/lib/Backend/ValueInfo.cpp +++ b/lib/Backend/ValueInfo.cpp @@ -787,7 +787,10 @@ ValueInfo::MergeLikelyIntValueInfo(JitArenaAllocator* alloc, Value *toDataVal, V if(newValueType.IsInt()) { - int32 min1, max1, min2, max2; + int32 min1 = INT32_MIN; + int32 max1 = INT32_MAX; + int32 min2 = INT32_MIN; + int32 max2 = INT32_MAX; toDataValueInfo->GetIntValMinMax(&min1, &max1, false); fromDataValueInfo->GetIntValMinMax(&min2, &max2, false); return ValueInfo::NewIntRangeValueInfo(alloc, min(min1, min2), max(max1, max2), wasNegativeZeroPreventedByBailout);