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

Side by Side Diff: src/x64/assembler-x64.cc

Issue 6310018: X64 Crankshaft: Remove relative jump to deoptimization code. Fixes logical e... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 9 years, 11 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/x64/assembler-x64.h ('k') | src/x64/lithium-codegen-x64.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 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 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 1288 matching lines...) Expand 10 before | Expand all | Expand 10 after
1299 emit(0x70 | cc); 1299 emit(0x70 | cc);
1300 emit((offs - short_size) & 0xFF); 1300 emit((offs - short_size) & 0xFF);
1301 } else { 1301 } else {
1302 emit(0x70 | cc); 1302 emit(0x70 | cc);
1303 emit(0x00); // The displacement will be resolved later. 1303 emit(0x00); // The displacement will be resolved later.
1304 L->link_to(pc_offset()); 1304 L->link_to(pc_offset());
1305 } 1305 }
1306 } 1306 }
1307 1307
1308 1308
1309 void Assembler::j(Condition cc, byte* entry, RelocInfo::Mode rmode) {
1310 EnsureSpace ensure_space(this);
1311 RecordRelocInfo(rmode);
1312 last_pc_ = pc_;
1313 ASSERT((0 <= cc) && (cc < 16));
1314 // 0000 1111 1000 tttn #32-bit disp.
1315 emit(0x0F);
1316 emit(0x80 | cc);
1317 emit(entry - (pc_ + sizeof(intptr_t)));
1318 }
1319
1320
1321 void Assembler::jmp(Label* L) { 1309 void Assembler::jmp(Label* L) {
1322 EnsureSpace ensure_space(this); 1310 EnsureSpace ensure_space(this);
1323 last_pc_ = pc_; 1311 last_pc_ = pc_;
1324 const int short_size = sizeof(int8_t); 1312 const int short_size = sizeof(int8_t);
1325 const int long_size = sizeof(int32_t); 1313 const int long_size = sizeof(int32_t);
1326 if (L->is_bound()) { 1314 if (L->is_bound()) {
1327 int offs = L->pos() - pc_offset() - 1; 1315 int offs = L->pos() - pc_offset() - 1;
1328 ASSERT(offs <= 0); 1316 ASSERT(offs <= 0);
1329 if (is_int8(offs - short_size)) { 1317 if (is_int8(offs - short_size)) {
1330 // 1110 1011 #8-bit disp. 1318 // 1110 1011 #8-bit disp.
(...skipping 1770 matching lines...) Expand 10 before | Expand all | Expand 10 after
3101 // specially coded on x64 means that it is a relative 32 bit address, as used 3089 // specially coded on x64 means that it is a relative 32 bit address, as used
3102 // by branch instructions. 3090 // by branch instructions.
3103 return (1 << rmode_) & kApplyMask; 3091 return (1 << rmode_) & kApplyMask;
3104 } 3092 }
3105 3093
3106 3094
3107 3095
3108 } } // namespace v8::internal 3096 } } // namespace v8::internal
3109 3097
3110 #endif // V8_TARGET_ARCH_X64 3098 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/x64/assembler-x64.h ('k') | src/x64/lithium-codegen-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698