OLD | NEW |
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 #include "vm/globals.h" | 5 #include "vm/globals.h" |
6 #if defined(TARGET_ARCH_IA32) | 6 #if defined(TARGET_ARCH_IA32) |
7 | 7 |
8 #include "vm/assembler.h" | 8 #include "vm/assembler.h" |
9 #include "vm/code_generator.h" | 9 #include "vm/code_generator.h" |
10 #include "vm/heap.h" | 10 #include "vm/heap.h" |
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
158 EmitUint8(0x60); | 158 EmitUint8(0x60); |
159 } | 159 } |
160 | 160 |
161 | 161 |
162 void Assembler::popal() { | 162 void Assembler::popal() { |
163 AssemblerBuffer::EnsureCapacity ensured(&buffer_); | 163 AssemblerBuffer::EnsureCapacity ensured(&buffer_); |
164 EmitUint8(0x61); | 164 EmitUint8(0x61); |
165 } | 165 } |
166 | 166 |
167 | 167 |
| 168 void Assembler::setcc(Condition condition, ByteRegister dst) { |
| 169 AssemblerBuffer::EnsureCapacity ensured(&buffer_); |
| 170 EmitUint8(0x0F); |
| 171 EmitUint8(0x90 + condition); |
| 172 EmitUint8(0xC0 + dst); |
| 173 } |
| 174 |
| 175 |
168 void Assembler::movl(Register dst, const Immediate& imm) { | 176 void Assembler::movl(Register dst, const Immediate& imm) { |
169 AssemblerBuffer::EnsureCapacity ensured(&buffer_); | 177 AssemblerBuffer::EnsureCapacity ensured(&buffer_); |
170 EmitUint8(0xB8 + dst); | 178 EmitUint8(0xB8 + dst); |
171 EmitImmediate(imm); | 179 EmitImmediate(imm); |
172 } | 180 } |
173 | 181 |
174 | 182 |
175 void Assembler::movl(Register dst, Register src) { | 183 void Assembler::movl(Register dst, Register src) { |
176 AssemblerBuffer::EnsureCapacity ensured(&buffer_); | 184 AssemblerBuffer::EnsureCapacity ensured(&buffer_); |
177 EmitUint8(0x89); | 185 EmitUint8(0x89); |
(...skipping 2184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2362 | 2370 |
2363 const char* Assembler::FpuRegisterName(FpuRegister reg) { | 2371 const char* Assembler::FpuRegisterName(FpuRegister reg) { |
2364 ASSERT((0 <= reg) && (reg < kNumberOfXmmRegisters)); | 2372 ASSERT((0 <= reg) && (reg < kNumberOfXmmRegisters)); |
2365 return xmm_reg_names[reg]; | 2373 return xmm_reg_names[reg]; |
2366 } | 2374 } |
2367 | 2375 |
2368 | 2376 |
2369 } // namespace dart | 2377 } // namespace dart |
2370 | 2378 |
2371 #endif // defined TARGET_ARCH_IA32 | 2379 #endif // defined TARGET_ARCH_IA32 |
OLD | NEW |