| OLD | NEW | 
|---|
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. | 
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be | 
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. | 
| 4 | 4 | 
| 5 #include "src/v8.h" | 5 #include "src/v8.h" | 
| 6 | 6 | 
| 7 #if V8_TARGET_ARCH_IA32 | 7 #if V8_TARGET_ARCH_IA32 | 
| 8 | 8 | 
| 9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" | 
| 10 #include "src/code-factory.h" | 10 #include "src/code-factory.h" | 
| (...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 250 | 250 | 
| 251     if (info()->saves_caller_doubles()) SaveCallerDoubles(); | 251     if (info()->saves_caller_doubles()) SaveCallerDoubles(); | 
| 252   } | 252   } | 
| 253 | 253 | 
| 254   // Possibly allocate a local context. | 254   // Possibly allocate a local context. | 
| 255   int heap_slots = info_->num_heap_slots() - Context::MIN_CONTEXT_SLOTS; | 255   int heap_slots = info_->num_heap_slots() - Context::MIN_CONTEXT_SLOTS; | 
| 256   if (heap_slots > 0) { | 256   if (heap_slots > 0) { | 
| 257     Comment(";;; Allocate local context"); | 257     Comment(";;; Allocate local context"); | 
| 258     bool need_write_barrier = true; | 258     bool need_write_barrier = true; | 
| 259     // Argument to NewContext is the function, which is still in edi. | 259     // Argument to NewContext is the function, which is still in edi. | 
|  | 260     DCHECK(!info()->scope()->is_script_scope()); | 
| 260     if (heap_slots <= FastNewContextStub::kMaximumSlots) { | 261     if (heap_slots <= FastNewContextStub::kMaximumSlots) { | 
| 261       FastNewContextStub stub(isolate(), heap_slots); | 262       FastNewContextStub stub(isolate(), heap_slots); | 
| 262       __ CallStub(&stub); | 263       __ CallStub(&stub); | 
| 263       // Result of FastNewContextStub is always in new space. | 264       // Result of FastNewContextStub is always in new space. | 
| 264       need_write_barrier = false; | 265       need_write_barrier = false; | 
| 265     } else { | 266     } else { | 
| 266       __ push(edi); | 267       __ push(edi); | 
| 267       __ CallRuntime(Runtime::kNewFunctionContext, 1); | 268       __ CallRuntime(Runtime::kNewFunctionContext, 1); | 
| 268     } | 269     } | 
| 269     RecordSafepoint(Safepoint::kNoLazyDeopt); | 270     RecordSafepoint(Safepoint::kNoLazyDeopt); | 
| (...skipping 5499 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 5769   CallRuntime(Runtime::kPushBlockContext, 2, instr); | 5770   CallRuntime(Runtime::kPushBlockContext, 2, instr); | 
| 5770   RecordSafepoint(Safepoint::kNoLazyDeopt); | 5771   RecordSafepoint(Safepoint::kNoLazyDeopt); | 
| 5771 } | 5772 } | 
| 5772 | 5773 | 
| 5773 | 5774 | 
| 5774 #undef __ | 5775 #undef __ | 
| 5775 | 5776 | 
| 5776 } }  // namespace v8::internal | 5777 } }  // namespace v8::internal | 
| 5777 | 5778 | 
| 5778 #endif  // V8_TARGET_ARCH_IA32 | 5779 #endif  // V8_TARGET_ARCH_IA32 | 
| OLD | NEW | 
|---|