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

Side by Side Diff: src/crankshaft/mips/lithium-codegen-mips.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/lithium-codegen.cc ('k') | src/crankshaft/mips64/lithium-codegen-mips64.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 2012 the V8 project authors. All rights reserved.7 1 // Copyright 2012 the V8 project authors. All rights reserved.7
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 312 matching lines...) Expand 10 before | Expand all | Expand 10 after
323 __ li(entry_offset, Operand(entry - base)); 323 __ li(entry_offset, Operand(entry - base));
324 324
325 if (table_entry->needs_frame) { 325 if (table_entry->needs_frame) {
326 DCHECK(!info()->saves_caller_doubles()); 326 DCHECK(!info()->saves_caller_doubles());
327 Comment(";;; call deopt with frame"); 327 Comment(";;; call deopt with frame");
328 __ PushCommonFrame(); 328 __ PushCommonFrame();
329 __ Call(&needs_frame); 329 __ Call(&needs_frame);
330 } else { 330 } else {
331 __ Call(&call_deopt_entry); 331 __ Call(&call_deopt_entry);
332 } 332 }
333 info()->LogDeoptCallPosition(masm()->pc_offset(), 333 LogDeoptCallPosition(masm()->pc_offset(),
334 table_entry->deopt_info.inlining_id); 334 table_entry->deopt_info.inlining_id);
335 } 335 }
336 336
337 if (needs_frame.is_linked()) { 337 if (needs_frame.is_linked()) {
338 __ bind(&needs_frame); 338 __ bind(&needs_frame);
339 // This variant of deopt can only be used with stubs. Since we don't 339 // This variant of deopt can only be used with stubs. Since we don't
340 // have a function pointer to install in the stack frame that we're 340 // have a function pointer to install in the stack frame that we're
341 // building, install a special marker there instead. 341 // building, install a special marker there instead.
342 __ li(at, Operand(Smi::FromInt(StackFrame::STUB))); 342 __ li(at, Operand(Smi::FromInt(StackFrame::STUB)));
343 __ push(at); 343 __ push(at);
344 DCHECK(info()->IsStub()); 344 DCHECK(info()->IsStub());
(...skipping 446 matching lines...) Expand 10 before | Expand all | Expand 10 after
791 791
792 Deoptimizer::DeoptInfo deopt_info = MakeDeoptInfo(instr, deopt_reason); 792 Deoptimizer::DeoptInfo deopt_info = MakeDeoptInfo(instr, deopt_reason);
793 793
794 DCHECK(info()->IsStub() || frame_is_built_); 794 DCHECK(info()->IsStub() || frame_is_built_);
795 // Go through jump table if we need to handle condition, build frame, or 795 // Go through jump table if we need to handle condition, build frame, or
796 // restore caller doubles. 796 // restore caller doubles.
797 if (condition == al && frame_is_built_ && 797 if (condition == al && frame_is_built_ &&
798 !info()->saves_caller_doubles()) { 798 !info()->saves_caller_doubles()) {
799 DeoptComment(deopt_info); 799 DeoptComment(deopt_info);
800 __ Call(entry, RelocInfo::RUNTIME_ENTRY, condition, src1, src2); 800 __ Call(entry, RelocInfo::RUNTIME_ENTRY, condition, src1, src2);
801 info()->LogDeoptCallPosition(masm()->pc_offset(), deopt_info.inlining_id); 801 LogDeoptCallPosition(masm()->pc_offset(), deopt_info.inlining_id);
802 } else { 802 } else {
803 Deoptimizer::JumpTableEntry table_entry(entry, deopt_info, bailout_type, 803 Deoptimizer::JumpTableEntry table_entry(entry, deopt_info, bailout_type,
804 !frame_is_built_); 804 !frame_is_built_);
805 // We often have several deopts to the same entry, reuse the last 805 // We often have several deopts to the same entry, reuse the last
806 // jump entry if this is the case. 806 // jump entry if this is the case.
807 if (FLAG_trace_deopt || isolate()->cpu_profiler()->is_profiling() || 807 if (FLAG_trace_deopt || isolate()->cpu_profiler()->is_profiling() ||
808 jump_table_.is_empty() || 808 jump_table_.is_empty() ||
809 !table_entry.IsEquivalentTo(jump_table_.last())) { 809 !table_entry.IsEquivalentTo(jump_table_.last())) {
810 jump_table_.Add(table_entry, zone()); 810 jump_table_.Add(table_entry, zone());
811 } 811 }
(...skipping 4719 matching lines...) Expand 10 before | Expand all | Expand 10 after
5531 __ lw(result, FieldMemOperand(scratch, 5531 __ lw(result, FieldMemOperand(scratch,
5532 FixedArray::kHeaderSize - kPointerSize)); 5532 FixedArray::kHeaderSize - kPointerSize));
5533 __ bind(deferred->exit()); 5533 __ bind(deferred->exit());
5534 __ bind(&done); 5534 __ bind(&done);
5535 } 5535 }
5536 5536
5537 #undef __ 5537 #undef __
5538 5538
5539 } // namespace internal 5539 } // namespace internal
5540 } // namespace v8 5540 } // namespace v8
OLDNEW
« no previous file with comments | « src/crankshaft/lithium-codegen.cc ('k') | src/crankshaft/mips64/lithium-codegen-mips64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698