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

Side by Side Diff: src/ia32/full-codegen-ia32.cc

Issue 195373004: Revert "Pass a Code object to Assembler::(set_)target_address_at for use by ool constant pool." (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 9 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
« no previous file with comments | « src/ia32/frames-ia32.h ('k') | src/ic.h » ('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. 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 4845 matching lines...) Expand 10 before | Expand all | Expand 10 after
4856 // nop 4856 // nop
4857 // nop 4857 // nop
4858 // call <on-stack replacment> 4858 // call <on-stack replacment>
4859 // ok: 4859 // ok:
4860 *jns_instr_address = kNopByteOne; 4860 *jns_instr_address = kNopByteOne;
4861 *jns_offset_address = kNopByteTwo; 4861 *jns_offset_address = kNopByteTwo;
4862 break; 4862 break;
4863 } 4863 }
4864 4864
4865 Assembler::set_target_address_at(call_target_address, 4865 Assembler::set_target_address_at(call_target_address,
4866 unoptimized_code,
4867 replacement_code->entry()); 4866 replacement_code->entry());
4868 unoptimized_code->GetHeap()->incremental_marking()->RecordCodeTargetPatch( 4867 unoptimized_code->GetHeap()->incremental_marking()->RecordCodeTargetPatch(
4869 unoptimized_code, call_target_address, replacement_code); 4868 unoptimized_code, call_target_address, replacement_code);
4870 } 4869 }
4871 4870
4872 4871
4873 BackEdgeTable::BackEdgeState BackEdgeTable::GetBackEdgeState( 4872 BackEdgeTable::BackEdgeState BackEdgeTable::GetBackEdgeState(
4874 Isolate* isolate, 4873 Isolate* isolate,
4875 Code* unoptimized_code, 4874 Code* unoptimized_code,
4876 Address pc) { 4875 Address pc) {
4877 Address call_target_address = pc - kIntSize; 4876 Address call_target_address = pc - kIntSize;
4878 Address jns_instr_address = call_target_address - 3; 4877 Address jns_instr_address = call_target_address - 3;
4879 ASSERT_EQ(kCallInstruction, *(call_target_address - 1)); 4878 ASSERT_EQ(kCallInstruction, *(call_target_address - 1));
4880 4879
4881 if (*jns_instr_address == kJnsInstruction) { 4880 if (*jns_instr_address == kJnsInstruction) {
4882 ASSERT_EQ(kJnsOffset, *(call_target_address - 2)); 4881 ASSERT_EQ(kJnsOffset, *(call_target_address - 2));
4883 ASSERT_EQ(isolate->builtins()->InterruptCheck()->entry(), 4882 ASSERT_EQ(isolate->builtins()->InterruptCheck()->entry(),
4884 Assembler::target_address_at(call_target_address, 4883 Assembler::target_address_at(call_target_address));
4885 unoptimized_code));
4886 return INTERRUPT; 4884 return INTERRUPT;
4887 } 4885 }
4888 4886
4889 ASSERT_EQ(kNopByteOne, *jns_instr_address); 4887 ASSERT_EQ(kNopByteOne, *jns_instr_address);
4890 ASSERT_EQ(kNopByteTwo, *(call_target_address - 2)); 4888 ASSERT_EQ(kNopByteTwo, *(call_target_address - 2));
4891 4889
4892 if (Assembler::target_address_at(call_target_address, unoptimized_code) == 4890 if (Assembler::target_address_at(call_target_address) ==
4893 isolate->builtins()->OnStackReplacement()->entry()) { 4891 isolate->builtins()->OnStackReplacement()->entry()) {
4894 return ON_STACK_REPLACEMENT; 4892 return ON_STACK_REPLACEMENT;
4895 } 4893 }
4896 4894
4897 ASSERT_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), 4895 ASSERT_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(),
4898 Assembler::target_address_at(call_target_address, 4896 Assembler::target_address_at(call_target_address));
4899 unoptimized_code));
4900 return OSR_AFTER_STACK_CHECK; 4897 return OSR_AFTER_STACK_CHECK;
4901 } 4898 }
4902 4899
4903 4900
4904 } } // namespace v8::internal 4901 } } // namespace v8::internal
4905 4902
4906 #endif // V8_TARGET_ARCH_IA32 4903 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/ia32/frames-ia32.h ('k') | src/ic.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698