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

Side by Side Diff: src/x64/assembler-x64-inl.h

Issue 658813003: [x64] simply tweak materialization of float/double constants (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 2 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.cc ('k') | src/x64/disasm-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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_X64_ASSEMBLER_X64_INL_H_ 5 #ifndef V8_X64_ASSEMBLER_X64_INL_H_
6 #define V8_X64_ASSEMBLER_X64_INL_H_ 6 #define V8_X64_ASSEMBLER_X64_INL_H_
7 7
8 #include "src/x64/assembler-x64.h" 8 #include "src/x64/assembler-x64.h"
9 9
10 #include "src/base/cpu.h" 10 #include "src/base/cpu.h"
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 byte rex_bits = (reg.code() & 0x8) >> 1 | (base.code() & 0x8) >> 3; 172 byte rex_bits = (reg.code() & 0x8) >> 1 | (base.code() & 0x8) >> 3;
173 if (rex_bits != 0) emit(0x40 | rex_bits); 173 if (rex_bits != 0) emit(0x40 | rex_bits);
174 } 174 }
175 175
176 176
177 void Assembler::emit_optional_rex_32(Register rm_reg) { 177 void Assembler::emit_optional_rex_32(Register rm_reg) {
178 if (rm_reg.high_bit()) emit(0x41); 178 if (rm_reg.high_bit()) emit(0x41);
179 } 179 }
180 180
181 181
182 void Assembler::emit_optional_rex_32(XMMRegister rm_reg) {
183 if (rm_reg.high_bit()) emit(0x41);
184 }
185
186
182 void Assembler::emit_optional_rex_32(const Operand& op) { 187 void Assembler::emit_optional_rex_32(const Operand& op) {
183 if (op.rex_ != 0) emit(0x40 | op.rex_); 188 if (op.rex_ != 0) emit(0x40 | op.rex_);
184 } 189 }
185 190
186 191
187 Address Assembler::target_address_at(Address pc, 192 Address Assembler::target_address_at(Address pc,
188 ConstantPoolArray* constant_pool) { 193 ConstantPoolArray* constant_pool) {
189 return Memory::int32_at(pc) + pc + 4; 194 return Memory::int32_at(pc) + pc + 4;
190 } 195 }
191 196
(...skipping 362 matching lines...) Expand 10 before | Expand all | Expand 10 after
554 DCHECK(len_ == 1 || len_ == 2); 559 DCHECK(len_ == 1 || len_ == 2);
555 int32_t* p = reinterpret_cast<int32_t*>(&buf_[len_]); 560 int32_t* p = reinterpret_cast<int32_t*>(&buf_[len_]);
556 *p = disp; 561 *p = disp;
557 len_ += sizeof(int32_t); 562 len_ += sizeof(int32_t);
558 } 563 }
559 564
560 565
561 } } // namespace v8::internal 566 } } // namespace v8::internal
562 567
563 #endif // V8_X64_ASSEMBLER_X64_INL_H_ 568 #endif // V8_X64_ASSEMBLER_X64_INL_H_
OLDNEW
« no previous file with comments | « src/x64/assembler-x64.cc ('k') | src/x64/disasm-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698