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

Side by Side Diff: src/objects.cc

Issue 11574027: Use direct jump and call instruction for X64 when the deoptimization entries are in the code range (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 8 years 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 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 8837 matching lines...) Expand 10 before | Expand all | Expand 10 after
8848 } else if (mode == RelocInfo::GLOBAL_PROPERTY_CELL) { 8848 } else if (mode == RelocInfo::GLOBAL_PROPERTY_CELL) {
8849 Handle<JSGlobalPropertyCell> cell = it.rinfo()->target_cell_handle(); 8849 Handle<JSGlobalPropertyCell> cell = it.rinfo()->target_cell_handle();
8850 it.rinfo()->set_target_cell(*cell, SKIP_WRITE_BARRIER); 8850 it.rinfo()->set_target_cell(*cell, SKIP_WRITE_BARRIER);
8851 } else if (RelocInfo::IsCodeTarget(mode)) { 8851 } else if (RelocInfo::IsCodeTarget(mode)) {
8852 // rewrite code handles in inline cache targets to direct 8852 // rewrite code handles in inline cache targets to direct
8853 // pointers to the first instruction in the code object 8853 // pointers to the first instruction in the code object
8854 Handle<Object> p = it.rinfo()->target_object_handle(origin); 8854 Handle<Object> p = it.rinfo()->target_object_handle(origin);
8855 Code* code = Code::cast(*p); 8855 Code* code = Code::cast(*p);
8856 it.rinfo()->set_target_address(code->instruction_start(), 8856 it.rinfo()->set_target_address(code->instruction_start(),
8857 SKIP_WRITE_BARRIER); 8857 SKIP_WRITE_BARRIER);
8858 #if defined(V8_TARGET_ARCH_X64)
8859 } else if (RelocInfo::IsDeoptEntry(mode)) {
8860 // rewrite deopt entries in optimized codes to direct
8861 // pointers to the entry
8862 Address p = it.rinfo()->target_deopt_entry(origin);
8863 it.rinfo()->set_target_address(p, SKIP_WRITE_BARRIER);
8864 #endif
8858 } else { 8865 } else {
8859 it.rinfo()->apply(delta); 8866 it.rinfo()->apply(delta);
8860 } 8867 }
8861 } 8868 }
8862 CPU::FlushICache(instruction_start(), instruction_size()); 8869 CPU::FlushICache(instruction_start(), instruction_size());
8863 } 8870 }
8864 8871
8865 8872
8866 // Locate the source position which is closest to the address in the code. This 8873 // Locate the source position which is closest to the address in the code. This
8867 // is using the source position information embedded in the relocation info. 8874 // is using the source position information embedded in the relocation info.
(...skipping 5159 matching lines...) Expand 10 before | Expand all | Expand 10 after
14027 set_year(Smi::FromInt(year), SKIP_WRITE_BARRIER); 14034 set_year(Smi::FromInt(year), SKIP_WRITE_BARRIER);
14028 set_month(Smi::FromInt(month), SKIP_WRITE_BARRIER); 14035 set_month(Smi::FromInt(month), SKIP_WRITE_BARRIER);
14029 set_day(Smi::FromInt(day), SKIP_WRITE_BARRIER); 14036 set_day(Smi::FromInt(day), SKIP_WRITE_BARRIER);
14030 set_weekday(Smi::FromInt(weekday), SKIP_WRITE_BARRIER); 14037 set_weekday(Smi::FromInt(weekday), SKIP_WRITE_BARRIER);
14031 set_hour(Smi::FromInt(hour), SKIP_WRITE_BARRIER); 14038 set_hour(Smi::FromInt(hour), SKIP_WRITE_BARRIER);
14032 set_min(Smi::FromInt(min), SKIP_WRITE_BARRIER); 14039 set_min(Smi::FromInt(min), SKIP_WRITE_BARRIER);
14033 set_sec(Smi::FromInt(sec), SKIP_WRITE_BARRIER); 14040 set_sec(Smi::FromInt(sec), SKIP_WRITE_BARRIER);
14034 } 14041 }
14035 14042
14036 } } // namespace v8::internal 14043 } } // namespace v8::internal
OLDNEW
« src/flag-definitions.h ('K') | « src/flag-definitions.h ('k') | src/objects-visiting-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698