OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 303 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
314 } | 314 } |
315 __ movq(rbx, profiling_counter_, RelocInfo::EMBEDDED_OBJECT); | 315 __ movq(rbx, profiling_counter_, RelocInfo::EMBEDDED_OBJECT); |
316 __ movq(kScratchRegister, | 316 __ movq(kScratchRegister, |
317 reinterpret_cast<uint64_t>(Smi::FromInt(reset_value)), | 317 reinterpret_cast<uint64_t>(Smi::FromInt(reset_value)), |
318 RelocInfo::NONE); | 318 RelocInfo::NONE); |
319 __ movq(FieldOperand(rbx, JSGlobalPropertyCell::kValueOffset), | 319 __ movq(FieldOperand(rbx, JSGlobalPropertyCell::kValueOffset), |
320 kScratchRegister); | 320 kScratchRegister); |
321 } | 321 } |
322 | 322 |
323 | 323 |
324 const int FullCodeGenerator::kMaxBackEdgeWeight = 127; | |
325 const int FullCodeGenerator::kBackEdgeDistanceUnit = 162; | |
326 | |
327 | |
328 void FullCodeGenerator::EmitStackCheck(IterationStatement* stmt, | 324 void FullCodeGenerator::EmitStackCheck(IterationStatement* stmt, |
329 Label* back_edge_target) { | 325 Label* back_edge_target) { |
330 Comment cmnt(masm_, "[ Stack check"); | 326 Comment cmnt(masm_, "[ Stack check"); |
331 Label ok; | 327 Label ok; |
332 | 328 |
333 if (FLAG_count_based_interrupts) { | 329 if (FLAG_count_based_interrupts) { |
334 int weight = 1; | 330 int weight = 1; |
335 if (FLAG_weighted_back_edges) { | 331 if (FLAG_weighted_back_edges) { |
336 ASSERT(back_edge_target->is_bound()); | 332 ASSERT(back_edge_target->is_bound()); |
337 int distance = masm_->SizeOfCodeGeneratedSince(back_edge_target); | 333 int distance = masm_->SizeOfCodeGeneratedSince(back_edge_target); |
(...skipping 4209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4547 *context_length = 0; | 4543 *context_length = 0; |
4548 return previous_; | 4544 return previous_; |
4549 } | 4545 } |
4550 | 4546 |
4551 | 4547 |
4552 #undef __ | 4548 #undef __ |
4553 | 4549 |
4554 } } // namespace v8::internal | 4550 } } // namespace v8::internal |
4555 | 4551 |
4556 #endif // V8_TARGET_ARCH_X64 | 4552 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |