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

Unified Diff: src/x64/assembler-x64.cc

Issue 6991010: Remove NearLabel, replacing remaining occurrences with Label (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/x64/assembler-x64.h ('k') | src/x64/code-stubs-x64.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/x64/assembler-x64.cc
diff --git a/src/x64/assembler-x64.cc b/src/x64/assembler-x64.cc
index b65bf4bb83490d96a39cee32aee3eecafb3479fb..60657aaa23d4214272fbf00e693fec297e40dcb9 100644
--- a/src/x64/assembler-x64.cc
+++ b/src/x64/assembler-x64.cc
@@ -481,19 +481,6 @@ void Assembler::bind(Label* L) {
}
-void Assembler::bind(NearLabel* L) {
- ASSERT(!L->is_bound());
- while (L->unresolved_branches_ > 0) {
- int branch_pos = L->unresolved_positions_[L->unresolved_branches_ - 1];
- int disp = pc_offset() - branch_pos;
- ASSERT(is_int8(disp));
- set_byte_at(branch_pos - sizeof(int8_t), disp);
- L->unresolved_branches_--;
- }
- L->bind_to(pc_offset());
-}
-
-
void Assembler::GrowBuffer() {
ASSERT(buffer_overflow());
if (!own_buffer_) FATAL("external code buffer is too small");
@@ -1293,26 +1280,6 @@ void Assembler::j(Condition cc,
}
-void Assembler::j(Condition cc, NearLabel* L, Hint hint) {
- EnsureSpace ensure_space(this);
- ASSERT(0 <= cc && cc < 16);
- if (FLAG_emit_branch_hints && hint != no_hint) emit(hint);
- if (L->is_bound()) {
- const int short_size = 2;
- int offs = L->pos() - pc_offset();
- ASSERT(offs <= 0);
- ASSERT(is_int8(offs - short_size));
- // 0111 tttn #8-bit disp
- emit(0x70 | cc);
- emit((offs - short_size) & 0xFF);
- } else {
- emit(0x70 | cc);
- emit(0x00); // The displacement will be resolved later.
- L->link_to(pc_offset());
- }
-}
-
-
void Assembler::jmp(Label* L, Label::Distance distance) {
EnsureSpace ensure_space(this);
const int short_size = sizeof(int8_t);
@@ -1363,24 +1330,6 @@ void Assembler::jmp(Handle<Code> target, RelocInfo::Mode rmode) {
}
-void Assembler::jmp(NearLabel* L) {
- EnsureSpace ensure_space(this);
- if (L->is_bound()) {
- const int short_size = sizeof(int8_t);
- int offs = L->pos() - pc_offset();
- ASSERT(offs <= 0);
- ASSERT(is_int8(offs - short_size));
- // 1110 1011 #8-bit disp.
- emit(0xEB);
- emit((offs - short_size) & 0xFF);
- } else {
- emit(0xEB);
- emit(0x00); // The displacement will be resolved later.
- L->link_to(pc_offset());
- }
-}
-
-
void Assembler::jmp(Register target) {
EnsureSpace ensure_space(this);
// Opcode FF/4 r64.
« no previous file with comments | « src/x64/assembler-x64.h ('k') | src/x64/code-stubs-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698