Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(251)

Side by Side Diff: src/crankshaft/x64/lithium-codegen-x64.cc

Issue 1944323002: [compiler] Move inline function tracing to Crankshaft. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/crankshaft/s390/lithium-codegen-s390.cc ('k') | src/crankshaft/x87/lithium-codegen-x87.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 #if V8_TARGET_ARCH_X64 5 #if V8_TARGET_ARCH_X64
6 6
7 #include "src/crankshaft/x64/lithium-codegen-x64.h" 7 #include "src/crankshaft/x64/lithium-codegen-x64.h"
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 281 matching lines...) Expand 10 before | Expand all | Expand 10 after
292 DCHECK(!info()->saves_caller_doubles()); 292 DCHECK(!info()->saves_caller_doubles());
293 __ Move(kScratchRegister, ExternalReference::ForDeoptEntry(entry)); 293 __ Move(kScratchRegister, ExternalReference::ForDeoptEntry(entry));
294 __ call(&needs_frame); 294 __ call(&needs_frame);
295 } else { 295 } else {
296 if (info()->saves_caller_doubles()) { 296 if (info()->saves_caller_doubles()) {
297 DCHECK(info()->IsStub()); 297 DCHECK(info()->IsStub());
298 RestoreCallerDoubles(); 298 RestoreCallerDoubles();
299 } 299 }
300 __ call(entry, RelocInfo::RUNTIME_ENTRY); 300 __ call(entry, RelocInfo::RUNTIME_ENTRY);
301 } 301 }
302 info()->LogDeoptCallPosition(masm()->pc_offset(), 302 LogDeoptCallPosition(masm()->pc_offset(),
303 table_entry->deopt_info.inlining_id); 303 table_entry->deopt_info.inlining_id);
304 } 304 }
305 305
306 if (needs_frame.is_linked()) { 306 if (needs_frame.is_linked()) {
307 __ bind(&needs_frame); 307 __ bind(&needs_frame);
308 /* stack layout 308 /* stack layout
309 3: return address <-- rsp 309 3: return address <-- rsp
310 2: garbage 310 2: garbage
311 1: garbage 311 1: garbage
312 0: garbage 312 0: garbage
313 */ 313 */
(...skipping 436 matching lines...) Expand 10 before | Expand all | Expand 10 after
750 750
751 Deoptimizer::DeoptInfo deopt_info = MakeDeoptInfo(instr, deopt_reason); 751 Deoptimizer::DeoptInfo deopt_info = MakeDeoptInfo(instr, deopt_reason);
752 752
753 DCHECK(info()->IsStub() || frame_is_built_); 753 DCHECK(info()->IsStub() || frame_is_built_);
754 // Go through jump table if we need to handle condition, build frame, or 754 // Go through jump table if we need to handle condition, build frame, or
755 // restore caller doubles. 755 // restore caller doubles.
756 if (cc == no_condition && frame_is_built_ && 756 if (cc == no_condition && frame_is_built_ &&
757 !info()->saves_caller_doubles()) { 757 !info()->saves_caller_doubles()) {
758 DeoptComment(deopt_info); 758 DeoptComment(deopt_info);
759 __ call(entry, RelocInfo::RUNTIME_ENTRY); 759 __ call(entry, RelocInfo::RUNTIME_ENTRY);
760 info()->LogDeoptCallPosition(masm()->pc_offset(), deopt_info.inlining_id); 760 LogDeoptCallPosition(masm()->pc_offset(), deopt_info.inlining_id);
761 } else { 761 } else {
762 Deoptimizer::JumpTableEntry table_entry(entry, deopt_info, bailout_type, 762 Deoptimizer::JumpTableEntry table_entry(entry, deopt_info, bailout_type,
763 !frame_is_built_); 763 !frame_is_built_);
764 // We often have several deopts to the same entry, reuse the last 764 // We often have several deopts to the same entry, reuse the last
765 // jump entry if this is the case. 765 // jump entry if this is the case.
766 if (FLAG_trace_deopt || isolate()->cpu_profiler()->is_profiling() || 766 if (FLAG_trace_deopt || isolate()->cpu_profiler()->is_profiling() ||
767 jump_table_.is_empty() || 767 jump_table_.is_empty() ||
768 !table_entry.IsEquivalentTo(jump_table_.last())) { 768 !table_entry.IsEquivalentTo(jump_table_.last())) {
769 jump_table_.Add(table_entry, zone()); 769 jump_table_.Add(table_entry, zone());
770 } 770 }
(...skipping 4821 matching lines...) Expand 10 before | Expand all | Expand 10 after
5592 __ bind(deferred->exit()); 5592 __ bind(deferred->exit());
5593 __ bind(&done); 5593 __ bind(&done);
5594 } 5594 }
5595 5595
5596 #undef __ 5596 #undef __
5597 5597
5598 } // namespace internal 5598 } // namespace internal
5599 } // namespace v8 5599 } // namespace v8
5600 5600
5601 #endif // V8_TARGET_ARCH_X64 5601 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/crankshaft/s390/lithium-codegen-s390.cc ('k') | src/crankshaft/x87/lithium-codegen-x87.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698