v8_4_5/src/hydrogen-instructions.cc
/*
 * Check if a conditional branch to "current_branch" with token "token" is
 * the branch that keeps the induction loop running (and, conversely, will
 * terminate it if the "other_branch" is taken).
 *
 * Three conditions must be met:
 * - "current_branch" must be in the induction loop.
 * - "other_branch" must be out of the induction loop.
 * - "token" and the induction increment must be "compatible": the token should
 *   be a condition that keeps the execution inside the loop until the limit is
 *   reached.
 */


Three conditions must be met:
- "current_branch" must be in the induction loop.
- "other_branch" must be out of the induction loop.
- "token" and the induction increment must be "compatible": the token should
be a condition that keeps the execution inside the loop until the limit is
reached.
Three conditions must be met : - " current_branch " must be in the induction loop . - " other_branch " must be out of the induction loop . - " token " and the induction increment must be " compatible " : the token should be a condition that keeps the execution inside the loop until the limit is reached .
bool InductionVariableData::CheckIfBranchIsLoopGuard(
    Token::Value token,
    HBasicBlock* current_branch,
    HBasicBlock* other_branch) {
  if (!phi()->block()->current_loop()->IsNestedInThisLoop(
      current_branch->current_loop())) {
    return false;
  }
  if (phi()->block()->current_loop()->IsNestedInThisLoop(
      other_branch->current_loop())) {
    return false;
  }
  if (increment() > 0 && (token == Token::LT || token == Token::LTE)) {
    return true;
  }
  if (increment() < 0 && (token == Token::GT || token == Token::GTE)) {
    return true;
  }
  if (Token::IsInequalityOp(token) && (increment() == 1 || increment() == -1)) {
    return true;
  }
  return false;
}
bool InductionVariableData :: CheckIfBranchIsLoopGuard ( Token :: Value token , HBasicBlock * current_branch , HBasicBlock * other_branch ) { if ( ! phi ( ) -> block ( ) -> current_loop ( ) -> IsNestedInThisLoop ( current_branch -> current_loop ( ) ) ) { return false ; } if ( phi ( ) -> block ( ) -> current_loop ( ) -> IsNestedInThisLoop ( other_branch -> current_loop ( ) ) ) { return false ; } if ( increment ( ) > 0 && ( token == Token :: LT || token == Token :: LTE ) ) { return true ; } if ( increment ( ) < 0 && ( token == Token :: GT || token == Token :: GTE ) ) { return true ; } if ( Token :: IsInequalityOp ( token ) && ( increment ( ) == 1 || increment ( ) == -1 ) ) { return true ; } return false ; }
Check if a conditional branch to "current_branch" with token "token" is
 the branch that keeps the induction loop running (and, conversely, will
 terminate it if the "other_branch" is taken).
Check if a conditional branch to " current_branch " with token " token " is the branch that keeps the induction loop running ( and conversely will terminate it if the " other_branch " is taken ) .