Revision: 18153
Author:   [email protected]
Date:     Fri Nov 29 10:02:32 2013 UTC
Log:      A few small refactorings and typo fixes

[email protected]

Review URL: https://codereview.chromium.org/95333002
http://code.google.com/p/v8/source/detail?r=18153

Modified:
 /branches/bleeding_edge/src/compiler.cc
 /branches/bleeding_edge/src/hydrogen-environment-liveness.cc
 /branches/bleeding_edge/src/hydrogen-mark-unreachable.h
 /branches/bleeding_edge/src/hydrogen.cc

=======================================
--- /branches/bleeding_edge/src/compiler.cc     Fri Nov 15 10:52:05 2013 UTC
+++ /branches/bleeding_edge/src/compiler.cc     Fri Nov 29 10:02:32 2013 UTC
@@ -324,9 +324,9 @@
 }


-class HOptimizedGraphBuilderWithPotisions: public HOptimizedGraphBuilder {
+class HOptimizedGraphBuilderWithPositions: public HOptimizedGraphBuilder {
  public:
-  explicit HOptimizedGraphBuilderWithPotisions(CompilationInfo* info)
+  explicit HOptimizedGraphBuilderWithPositions(CompilationInfo* info)
       : HOptimizedGraphBuilder(info) {
   }

@@ -468,7 +468,7 @@
   AstTyper::Run(info());

   graph_builder_ = FLAG_emit_opt_code_positions
-      ? new(info()->zone()) HOptimizedGraphBuilderWithPotisions(info())
+      ? new(info()->zone()) HOptimizedGraphBuilderWithPositions(info())
       : new(info()->zone()) HOptimizedGraphBuilder(info());

   Timer t(this, &time_taken_to_create_graph_);
@@ -513,7 +513,7 @@
   ASSERT(graph_ != NULL);
   BailoutReason bailout_reason = kNoReason;
   if (!graph_->Optimize(&bailout_reason)) {
- if (bailout_reason == kNoReason) graph_builder_->Bailout(bailout_reason); + if (bailout_reason != kNoReason) graph_builder_->Bailout(bailout_reason);
     return SetLastStatus(BAILED_OUT);
   } else {
     chunk_ = LChunk::NewChunk(graph_);
=======================================
--- /branches/bleeding_edge/src/hydrogen-environment-liveness.cc Wed Aug 28 15:00:30 2013 UTC +++ /branches/bleeding_edge/src/hydrogen-environment-liveness.cc Fri Nov 29 10:02:32 2013 UTC
@@ -201,7 +201,7 @@
       HBasicBlock* block = graph()->blocks()->at(block_id);
       UpdateLivenessAtBlockEnd(block, &live);

-      for (HInstruction* instr = block->last(); instr != NULL;
+      for (HInstruction* instr = block->end(); instr != NULL;
            instr = instr->previous()) {
         UpdateLivenessAtInstruction(instr, &live);
       }
=======================================
--- /branches/bleeding_edge/src/hydrogen-mark-unreachable.h Wed Oct 2 11:43:41 2013 UTC +++ /branches/bleeding_edge/src/hydrogen-mark-unreachable.h Fri Nov 29 10:02:32 2013 UTC
@@ -37,7 +37,7 @@
 class HMarkUnreachableBlocksPhase : public HPhase {
  public:
   explicit HMarkUnreachableBlocksPhase(HGraph* graph)
-      : HPhase("H_Mark unrechable blocks", graph) { }
+      : HPhase("H_Mark unreachable blocks", graph) { }

   void Run();

=======================================
--- /branches/bleeding_edge/src/hydrogen.cc     Fri Nov 29 09:59:35 2013 UTC
+++ /branches/bleeding_edge/src/hydrogen.cc     Fri Nov 29 10:02:32 2013 UTC
@@ -1602,7 +1602,7 @@
   if_objectissmi.Else();
   {
     if (type->Is(Type::Smi())) {
-      if_objectissmi.Deopt("Excepted smi");
+      if_objectissmi.Deopt("Expected smi");
     } else {
       // Check if the object is a heap number.
       IfBuilder if_objectisnumber(this);
@@ -3570,15 +3570,8 @@
   if (value != NULL && value->CheckFlag(HValue::kIsArguments)) {
     builder->Bailout(kArgumentsObjectValueInATestContext);
   }
-  HBasicBlock* empty_true = builder->graph()->CreateBasicBlock();
-  HBasicBlock* empty_false = builder->graph()->CreateBasicBlock();
   ToBooleanStub::Types expected(condition()->to_boolean_types());
-  builder->FinishCurrentBlock(builder->New<HBranch>(
-          value, expected, empty_true, empty_false));
-
-  owner()->Goto(empty_true, if_true(), builder->function_state());
-  owner()->Goto(empty_false , if_false(), builder->function_state());
-  builder->set_current_block(NULL);
+  ReturnControl(owner()->New<HBranch>(value, expected), BailoutId::None());
 }


--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to