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

Side by Side Diff: runtime/vm/flow_graph_compiler_ia32.cc

Issue 10882055: Put live register bits in stackmaps. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 3 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_IA32. 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_IA32.
6 #if defined(TARGET_ARCH_IA32) 6 #if defined(TARGET_ARCH_IA32)
7 7
8 #include "vm/flow_graph_compiler.h" 8 #include "vm/flow_graph_compiler.h"
9 9
10 #include "lib/error.h" 10 #include "lib/error.h"
(...skipping 778 matching lines...) Expand 10 before | Expand all | Expand 10 after
789 // EBP : points to previous frame pointer. 789 // EBP : points to previous frame pointer.
790 // EBP + 4 : points to return address. 790 // EBP + 4 : points to return address.
791 // EBP + 8 : address of last argument (arg n-1). 791 // EBP + 8 : address of last argument (arg n-1).
792 // ESP + 8 + 4*(n-1) : address of first argument (arg 0). 792 // ESP + 8 + 4*(n-1) : address of first argument (arg 0).
793 // ECX : ic-data. 793 // ECX : ic-data.
794 // EDX : arguments descriptor array. 794 // EDX : arguments descriptor array.
795 __ call(&StubCode::CallNoSuchMethodFunctionLabel()); 795 __ call(&StubCode::CallNoSuchMethodFunctionLabel());
796 } 796 }
797 if (is_optimizing()) { 797 if (is_optimizing()) {
798 stackmap_table_builder_->AddEntry(assembler()->CodeSize(), 798 stackmap_table_builder_->AddEntry(assembler()->CodeSize(),
799 empty_stack_bitmap); 799 empty_stack_bitmap,
800 0); // No registers.
800 } 801 }
801 802
802 803
803 if (FLAG_trace_functions) { 804 if (FLAG_trace_functions) {
804 __ pushl(EAX); // Preserve result. 805 __ pushl(EAX); // Preserve result.
805 __ PushObject(Function::ZoneHandle(function.raw())); 806 __ PushObject(Function::ZoneHandle(function.raw()));
806 // We do not use GenerateCallRuntime because of the non-standard (empty) 807 // We do not use GenerateCallRuntime because of the non-standard (empty)
807 // stackmap used here. 808 // stackmap used here.
808 __ CallRuntime(kTraceFunctionExitRuntimeEntry); 809 __ CallRuntime(kTraceFunctionExitRuntimeEntry);
809 AddCurrentDescriptor(PcDescriptors::kOther, 810 AddCurrentDescriptor(PcDescriptors::kOther,
810 Isolate::kNoDeoptId, 811 Isolate::kNoDeoptId,
811 0, // No token position. 812 0, // No token position.
812 CatchClauseNode::kInvalidTryIndex); 813 CatchClauseNode::kInvalidTryIndex);
813 if (is_optimizing()) { 814 if (is_optimizing()) {
814 stackmap_table_builder_->AddEntry(assembler()->CodeSize(), 815 stackmap_table_builder_->AddEntry(assembler()->CodeSize(),
815 empty_stack_bitmap); 816 empty_stack_bitmap,
817 0); // No registers.
816 } 818 }
817 __ popl(EAX); // Remove argument. 819 __ popl(EAX); // Remove argument.
818 __ popl(EAX); // Restore result. 820 __ popl(EAX); // Restore result.
819 } 821 }
820 __ LeaveFrame(); 822 __ LeaveFrame();
821 __ ret(); 823 __ ret();
822 824
823 __ Bind(&all_arguments_processed); 825 __ Bind(&all_arguments_processed);
824 // Nullify originally passed arguments only after they have been copied and 826 // Nullify originally passed arguments only after they have been copied and
825 // checked, otherwise noSuchMethod would not see their original values. 827 // checked, otherwise noSuchMethod would not see their original values.
(...skipping 484 matching lines...) Expand 10 before | Expand all | Expand 10 after
1310 __ popl(ECX); 1312 __ popl(ECX);
1311 __ popl(EAX); 1313 __ popl(EAX);
1312 } 1314 }
1313 1315
1314 1316
1315 #undef __ 1317 #undef __
1316 1318
1317 } // namespace dart 1319 } // namespace dart
1318 1320
1319 #endif // defined TARGET_ARCH_IA32 1321 #endif // defined TARGET_ARCH_IA32
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698