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

Side by Side Diff: test/cctest/test-disasm-x87.cc

Issue 430423002: X87: Land the Fan (disabled) (Closed) Base URL: https://chromium.googlesource.com/external/v8.git@bleeding_edge
Patch Set: Created 6 years, 4 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
« no previous file with comments | « test/cctest/test-assembler-x87.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 150 matching lines...) Expand 10 before | Expand all | Expand 10 after
161 __ mov(Operand(ebx, ecx, times_4, 10000), edx); 161 __ mov(Operand(ebx, ecx, times_4, 10000), edx);
162 __ nop(); 162 __ nop();
163 __ dec_b(edx); 163 __ dec_b(edx);
164 __ dec_b(Operand(eax, 10)); 164 __ dec_b(Operand(eax, 10));
165 __ dec_b(Operand(ebx, ecx, times_4, 10000)); 165 __ dec_b(Operand(ebx, ecx, times_4, 10000));
166 __ dec(edx); 166 __ dec(edx);
167 __ cdq(); 167 __ cdq();
168 168
169 __ nop(); 169 __ nop();
170 __ idiv(edx); 170 __ idiv(edx);
171 __ idiv(Operand(edx, ecx, times_1, 1));
172 __ idiv(Operand(esp, 12));
173 __ div(edx);
174 __ div(Operand(edx, ecx, times_1, 1));
175 __ div(Operand(esp, 12));
171 __ mul(edx); 176 __ mul(edx);
172 __ neg(edx); 177 __ neg(edx);
173 __ not_(edx); 178 __ not_(edx);
174 __ test(Operand(ebx, ecx, times_4, 10000), Immediate(123456)); 179 __ test(Operand(ebx, ecx, times_4, 10000), Immediate(123456));
175 180
176 __ imul(edx, Operand(ebx, ecx, times_4, 10000)); 181 __ imul(edx, Operand(ebx, ecx, times_4, 10000));
177 __ imul(edx, ecx, 12); 182 __ imul(edx, ecx, 12);
183 __ imul(edx, Operand(edx, eax, times_2, 42), 8);
178 __ imul(edx, ecx, 1000); 184 __ imul(edx, ecx, 1000);
185 __ imul(edx, Operand(ebx, ecx, times_4, 1), 9000);
179 186
180 __ inc(edx); 187 __ inc(edx);
181 __ inc(Operand(ebx, ecx, times_4, 10000)); 188 __ inc(Operand(ebx, ecx, times_4, 10000));
182 __ push(Operand(ebx, ecx, times_4, 10000)); 189 __ push(Operand(ebx, ecx, times_4, 10000));
183 __ pop(Operand(ebx, ecx, times_4, 10000)); 190 __ pop(Operand(ebx, ecx, times_4, 10000));
184 __ call(Operand(ebx, ecx, times_4, 10000)); 191 __ call(Operand(ebx, ecx, times_4, 10000));
185 __ jmp(Operand(ebx, ecx, times_4, 10000)); 192 __ jmp(Operand(ebx, ecx, times_4, 10000));
186 193
187 __ lea(edx, Operand(ebx, ecx, times_4, 10000)); 194 __ lea(edx, Operand(ebx, ecx, times_4, 10000));
188 __ or_(edx, 12345); 195 __ or_(edx, 12345);
189 __ or_(edx, Operand(ebx, ecx, times_4, 10000)); 196 __ or_(edx, Operand(ebx, ecx, times_4, 10000));
190 197
191 __ nop(); 198 __ nop();
192 199
193 __ rcl(edx, 1); 200 __ rcl(edx, 1);
194 __ rcl(edx, 7); 201 __ rcl(edx, 7);
195 __ rcr(edx, 1); 202 __ rcr(edx, 1);
196 __ rcr(edx, 7); 203 __ rcr(edx, 7);
197 __ sar(edx, 1); 204 __ sar(edx, 1);
198 __ sar(edx, 6); 205 __ sar(edx, 6);
199 __ sar_cl(edx); 206 __ sar_cl(edx);
207 __ sar(Operand(ebx, ecx, times_4, 10000), 1);
208 __ sar(Operand(ebx, ecx, times_4, 10000), 6);
209 __ sar_cl(Operand(ebx, ecx, times_4, 10000));
200 __ sbb(edx, Operand(ebx, ecx, times_4, 10000)); 210 __ sbb(edx, Operand(ebx, ecx, times_4, 10000));
201 __ shld(edx, Operand(ebx, ecx, times_4, 10000)); 211 __ shld(edx, Operand(ebx, ecx, times_4, 10000));
202 __ shl(edx, 1); 212 __ shl(edx, 1);
203 __ shl(edx, 6); 213 __ shl(edx, 6);
204 __ shl_cl(edx); 214 __ shl_cl(edx);
215 __ shl(Operand(ebx, ecx, times_4, 10000), 1);
216 __ shl(Operand(ebx, ecx, times_4, 10000), 6);
217 __ shl_cl(Operand(ebx, ecx, times_4, 10000));
205 __ shrd(edx, Operand(ebx, ecx, times_4, 10000)); 218 __ shrd(edx, Operand(ebx, ecx, times_4, 10000));
206 __ shr(edx, 1); 219 __ shr(edx, 1);
207 __ shr(edx, 7); 220 __ shr(edx, 7);
208 __ shr_cl(edx); 221 __ shr_cl(edx);
222 __ shr(Operand(ebx, ecx, times_4, 10000), 1);
223 __ shr(Operand(ebx, ecx, times_4, 10000), 6);
224 __ shr_cl(Operand(ebx, ecx, times_4, 10000));
209 225
210 226
211 // Immediates 227 // Immediates
212 228
213 __ adc(edx, 12345); 229 __ adc(edx, 12345);
214 230
215 __ add(ebx, Immediate(12)); 231 __ add(ebx, Immediate(12));
216 __ add(Operand(edx, ecx, times_4, 10000), Immediate(12)); 232 __ add(Operand(edx, ecx, times_4, 10000), Immediate(12));
217 233
218 __ and_(ebx, 12345); 234 __ and_(ebx, 12345);
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
355 __ faddp(3); 371 __ faddp(3);
356 __ fsubp(3); 372 __ fsubp(3);
357 __ fmulp(3); 373 __ fmulp(3);
358 __ fdivp(3); 374 __ fdivp(3);
359 __ fcompp(); 375 __ fcompp();
360 __ fwait(); 376 __ fwait();
361 __ frndint(); 377 __ frndint();
362 __ fninit(); 378 __ fninit();
363 __ nop(); 379 __ nop();
364 380
381 // xchg.
382 {
383 __ xchg(eax, eax);
384 __ xchg(eax, ebx);
385 __ xchg(ebx, ebx);
386 __ xchg(ebx, Operand(esp, 12));
387 }
388
365 // Nop instructions 389 // Nop instructions
366 for (int i = 0; i < 16; i++) { 390 for (int i = 0; i < 16; i++) {
367 __ Nop(i); 391 __ Nop(i);
368 } 392 }
369 393
370 __ ret(0); 394 __ ret(0);
371 395
372 CodeDesc desc; 396 CodeDesc desc;
373 assm.GetCode(&desc); 397 assm.GetCode(&desc);
374 Handle<Code> code = isolate->factory()->NewCode( 398 Handle<Code> code = isolate->factory()->NewCode(
375 desc, Code::ComputeFlags(Code::STUB), Handle<Code>()); 399 desc, Code::ComputeFlags(Code::STUB), Handle<Code>());
376 USE(code); 400 USE(code);
377 #ifdef OBJECT_PRINT 401 #ifdef OBJECT_PRINT
378 OFStream os(stdout); 402 OFStream os(stdout);
379 code->Print(os); 403 code->Print(os);
380 byte* begin = code->instruction_start(); 404 byte* begin = code->instruction_start();
381 byte* end = begin + code->instruction_size(); 405 byte* end = begin + code->instruction_size();
382 disasm::Disassembler::Disassemble(stdout, begin, end); 406 disasm::Disassembler::Disassemble(stdout, begin, end);
383 #endif 407 #endif
384 } 408 }
385 409
386 #undef __ 410 #undef __
OLDNEW
« no previous file with comments | « test/cctest/test-assembler-x87.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698