@@ -160,7 +160,7 @@ BackwardPass::DoTrackNegativeZero() const
160160bool
161161BackwardPass::DoTrackBitOpsOrNumber () const
162162{
163- #if _WIN64
163+ #if defined(_WIN32) && defined(TARGET_64)
164164 return
165165 !PHASE_OFF1 (Js::TypedArrayVirtualPhase) &&
166166 tag == Js::BackwardPhase &&
@@ -316,8 +316,8 @@ BackwardPass::ProcessBailOnStackArgsOutOfActualsRange()
316316{
317317 IR::Instr * instr = this ->currentInstr ;
318318
319- if (tag == Js::DeadStorePhase &&
320- (instr->m_opcode == Js::OpCode::LdElemI_A || instr->m_opcode == Js::OpCode::TypeofElem) &&
319+ if (tag == Js::DeadStorePhase &&
320+ (instr->m_opcode == Js::OpCode::LdElemI_A || instr->m_opcode == Js::OpCode::TypeofElem) &&
321321 instr->HasBailOutInfo () && !IsPrePass ())
322322 {
323323 if (instr->DoStackArgsOpt (this ->func ))
@@ -1735,7 +1735,7 @@ BackwardPass::ProcessBailOutCopyProps(BailOutInfo * bailOutInfo, BVSparse<JitAre
17351735 StackSym * float64StackSym = nullptr ;
17361736 StackSym * simd128StackSym = nullptr ;
17371737
1738- // If the sym is type specialized, we need to check for upward exposed uses of the specialized sym and not the equivalent var sym. If there are no
1738+ // If the sym is type specialized, we need to check for upward exposed uses of the specialized sym and not the equivalent var sym. If there are no
17391739 // uses and we use the copy prop sym to restore, we'll need to find the type specialize sym for that sym as well.
17401740 StackSym * typeSpecSym = nullptr ;
17411741 auto findTypeSpecSym = [&]()
@@ -2590,7 +2590,7 @@ BackwardPass::ProcessBlock(BasicBlock * block)
25902590
25912591 this ->currentInstr = instr;
25922592 this ->currentRegion = this ->currentBlock ->GetFirstInstr ()->AsLabelInstr ()->GetRegion ();
2593-
2593+
25942594 IR::Instr * insertedInstr = TryChangeInstrForStackArgOpt ();
25952595 if (insertedInstr != nullptr )
25962596 {
@@ -2600,7 +2600,7 @@ BackwardPass::ProcessBlock(BasicBlock * block)
26002600
26012601 MarkScopeObjSymUseForStackArgOpt ();
26022602 ProcessBailOnStackArgsOutOfActualsRange ();
2603-
2603+
26042604 if (ProcessNoImplicitCallUses (instr) || this ->ProcessBailOutInfo (instr))
26052605 {
26062606 continue ;
@@ -2943,7 +2943,7 @@ BackwardPass::ProcessBlock(BasicBlock * block)
29432943#endif
29442944}
29452945
2946- bool
2946+ bool
29472947BackwardPass::CanDeadStoreInstrForScopeObjRemoval (Sym *sym) const
29482948{
29492949 if (tag == Js::DeadStorePhase && this ->currentInstr ->m_func ->IsStackArgsEnabled ())
@@ -3099,7 +3099,7 @@ BackwardPass::DeadStoreOrChangeInstrForScopeObjRemoval(IR::Instr ** pInstrPrev)
30993099 case Js::OpCode::GetCachedFunc:
31003100 {
31013101 // <dst> = GetCachedFunc <scopeObject>, <functionNum>
3102- // is converted to
3102+ // is converted to
31033103 // <dst> = NewScFunc <functionNum>, <env: FrameDisplay>
31043104
31053105 if (instr->GetSrc1 ()->IsScopeObjOpnd (currFunc))
@@ -3161,8 +3161,8 @@ BackwardPass::TryChangeInstrForStackArgOpt()
31613161 * -This is to facilitate Bailout to record the live Scope object Sym, whenever required.
31623162 * -Reason for doing is this because - Scope object has to be implicitly live whenever Heap Arguments object is live.
31633163 * -When we restore HeapArguments object in the bail out path, it expects the scope object also to be restored - if one was created.
3164- * -We do not know detailed information about Heap arguments obj syms(aliasing etc.) until we complete Forward Pass.
3165- * -And we want to avoid dead sym clean up (in this case, scope object though not explicitly live, it is live implicitly) during Block merging in the forward pass.
3164+ * -We do not know detailed information about Heap arguments obj syms(aliasing etc.) until we complete Forward Pass.
3165+ * -And we want to avoid dead sym clean up (in this case, scope object though not explicitly live, it is live implicitly) during Block merging in the forward pass.
31663166 * -Hence this is the optimal spot to do this.
31673167 */
31683168
@@ -3196,10 +3196,10 @@ bool
31963196BackwardPass::IsFormalParamSym (Func * func, Sym * sym) const
31973197{
31983198 Assert (sym);
3199-
3199+
32003200 if (sym->IsPropertySym ())
32013201 {
3202- // If the sym is a propertySym, then see if the propertyId is within the range of the formals
3202+ // If the sym is a propertySym, then see if the propertyId is within the range of the formals
32033203 // We can have other properties stored in the scope object other than the formals (following the formals).
32043204 PropertySym * propSym = sym->AsPropertySym ();
32053205 IntConstType value = propSym->m_propertyId ;
@@ -4250,8 +4250,8 @@ bool
42504250BackwardPass::ProcessSymUse (Sym * sym, bool isRegOpndUse, BOOLEAN isNonByteCodeUse)
42514251{
42524252 BasicBlock * block = this ->currentBlock ;
4253-
4254- if (CanDeadStoreInstrForScopeObjRemoval (sym))
4253+
4254+ if (CanDeadStoreInstrForScopeObjRemoval (sym))
42554255 {
42564256 return false ;
42574257 }
@@ -4537,7 +4537,7 @@ BackwardPass::TrackObjTypeSpecProperties(IR::PropertySymOpnd *opnd, BasicBlock *
45374537 }
45384538 bucket->SetMonoGuardType (nullptr );
45394539 }
4540-
4540+
45414541 if (!opnd->IsTypeAvailable ())
45424542 {
45434543 // Stop tracking the guarded properties if there's not another type check upstream.
@@ -5651,7 +5651,7 @@ BackwardPass::TrackIntUsage(IR::Instr *const instr)
56515651 SetNegativeZeroDoesNotMatterIfLastUse (instr->GetSrc2 ());
56525652 break ;
56535653 }
5654-
5654+
56555655 // -0 + -0 == -0. As long as one src is guaranteed to not be -0, -0 does not matter for the other src. Pick a
56565656 // src for which to ignore negative zero, based on which sym is last-use. If both syms are last-use, src2 is
56575657 // picked arbitrarily.
@@ -6741,9 +6741,9 @@ BackwardPass::DeadStoreInstr(IR::Instr *instr)
67416741 tempBv.Copy (this ->currentBlock ->byteCodeUpwardExposedUsed );
67426742#endif
67436743 PropertySym *unusedPropertySym = nullptr ;
6744-
6744+
67456745 GlobOpt::TrackByteCodeSymUsed (instr, this ->currentBlock ->byteCodeUpwardExposedUsed , &unusedPropertySym);
6746-
6746+
67476747#if DBG
67486748 BVSparse<JitArenaAllocator> tempBv2 (this ->tempAlloc );
67496749 tempBv2.Copy (this ->currentBlock ->byteCodeUpwardExposedUsed );
@@ -6781,7 +6781,7 @@ BackwardPass::DeadStoreInstr(IR::Instr *instr)
67816781 }
67826782#endif
67836783
6784-
6784+
67856785 if (instr->m_opcode == Js::OpCode::ArgIn_A)
67866786 {
67876787 // Ignore tracking ArgIn for "this", as argInsCount only tracks other params - unless it is a asmjs function(which doesn't have a "this").
@@ -6793,7 +6793,7 @@ BackwardPass::DeadStoreInstr(IR::Instr *instr)
67936793 }
67946794
67956795 TraceDeadStoreOfInstrsForScopeObjectRemoval ();
6796-
6796+
67976797 block->RemoveInstr (instr);
67986798 return true ;
67996799}
0 commit comments