| OLD | NEW | 
|---|
| 1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 the V8 project authors. All rights reserved. | 
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without | 
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are | 
| 4 // met: | 4 // met: | 
| 5 // | 5 // | 
| 6 //     * Redistributions of source code must retain the above copyright | 6 //     * Redistributions of source code must retain the above copyright | 
| 7 //       notice, this list of conditions and the following disclaimer. | 7 //       notice, this list of conditions and the following disclaimer. | 
| 8 //     * Redistributions in binary form must reproduce the above | 8 //     * Redistributions in binary form must reproduce the above | 
| 9 //       copyright notice, this list of conditions and the following | 9 //       copyright notice, this list of conditions and the following | 
| 10 //       disclaimer in the documentation and/or other materials provided | 10 //       disclaimer in the documentation and/or other materials provided | 
| (...skipping 17 matching lines...) Expand all  Loading... | 
| 28 #include "v8.h" | 28 #include "v8.h" | 
| 29 | 29 | 
| 30 #include "codegen-inl.h" | 30 #include "codegen-inl.h" | 
| 31 #include "jump-target-inl.h" | 31 #include "jump-target-inl.h" | 
| 32 | 32 | 
| 33 namespace v8 { | 33 namespace v8 { | 
| 34 namespace internal { | 34 namespace internal { | 
| 35 | 35 | 
| 36 | 36 | 
| 37 DeferredCode::DeferredCode() | 37 DeferredCode::DeferredCode() | 
| 38     : masm_(CodeGeneratorScope::Current()->masm()), | 38     : masm_(CodeGeneratorScope::Current(Isolate::Current())->masm()), | 
| 39       statement_position_(masm_->positions_recorder()-> | 39       statement_position_(masm_->positions_recorder()-> | 
| 40                           current_statement_position()), | 40                           current_statement_position()), | 
| 41       position_(masm_->positions_recorder()->current_position()), | 41       position_(masm_->positions_recorder()->current_position()), | 
| 42       frame_state_(*CodeGeneratorScope::Current()->frame()) { | 42       frame_state_(*CodeGeneratorScope::Current(Isolate::Current())->frame()) { | 
| 43   ASSERT(statement_position_ != RelocInfo::kNoPosition); | 43   ASSERT(statement_position_ != RelocInfo::kNoPosition); | 
| 44   ASSERT(position_ != RelocInfo::kNoPosition); | 44   ASSERT(position_ != RelocInfo::kNoPosition); | 
| 45 | 45 | 
| 46   CodeGeneratorScope::Current()->AddDeferred(this); | 46   CodeGeneratorScope::Current(Isolate::Current())->AddDeferred(this); | 
| 47 | 47 | 
| 48 #ifdef DEBUG | 48 #ifdef DEBUG | 
| 49   comment_ = ""; | 49   comment_ = ""; | 
| 50 #endif | 50 #endif | 
| 51 } | 51 } | 
| 52 | 52 | 
| 53 | 53 | 
| 54 // ------------------------------------------------------------------------- | 54 // ------------------------------------------------------------------------- | 
| 55 // BreakTarget implementation. | 55 // BreakTarget implementation. | 
| 56 | 56 | 
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 102   if (cgen()->has_valid_frame()) { | 102   if (cgen()->has_valid_frame()) { | 
| 103     int count = cgen()->frame()->height() - expected_height_; | 103     int count = cgen()->frame()->height() - expected_height_; | 
| 104     if (count > 0) { | 104     if (count > 0) { | 
| 105       cgen()->frame()->Drop(count); | 105       cgen()->frame()->Drop(count); | 
| 106     } | 106     } | 
| 107   } | 107   } | 
| 108   DoBind(); | 108   DoBind(); | 
| 109 } | 109 } | 
| 110 | 110 | 
| 111 } }  // namespace v8::internal | 111 } }  // namespace v8::internal | 
| OLD | NEW | 
|---|