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

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

Issue 546087: Implement inline string compare on ARM. (Closed)
Patch Set: Further optimization of ARM version Created 10 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
« no previous file with comments | « src/ia32/assembler-ia32.h ('k') | src/ia32/codegen-ia32.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 (c) 1994-2006 Sun Microsystems Inc. 1 // Copyright (c) 1994-2006 Sun Microsystems Inc.
2 // All Rights Reserved. 2 // All Rights Reserved.
3 // 3 //
4 // Redistribution and use in source and binary forms, with or without 4 // Redistribution and use in source and binary forms, with or without
5 // modification, are permitted provided that the following conditions 5 // modification, are permitted provided that the following conditions
6 // are met: 6 // are met:
7 // 7 //
8 // - Redistributions of source code must retain the above copyright notice, 8 // - Redistributions of source code must retain the above copyright notice,
9 // this list of conditions and the following disclaimer. 9 // this list of conditions and the following disclaimer.
10 // 10 //
(...skipping 842 matching lines...) Expand 10 before | Expand all | Expand 10 after
853 853
854 void Assembler::cmpb(const Operand& op, int8_t imm8) { 854 void Assembler::cmpb(const Operand& op, int8_t imm8) {
855 EnsureSpace ensure_space(this); 855 EnsureSpace ensure_space(this);
856 last_pc_ = pc_; 856 last_pc_ = pc_;
857 EMIT(0x80); 857 EMIT(0x80);
858 emit_operand(edi, op); // edi == 7 858 emit_operand(edi, op); // edi == 7
859 EMIT(imm8); 859 EMIT(imm8);
860 } 860 }
861 861
862 862
863 void Assembler::cmpb(const Operand& dst, Register src) {
864 ASSERT(src.is_byte_register());
865 EnsureSpace ensure_space(this);
866 last_pc_ = pc_;
867 EMIT(0x38);
868 emit_operand(src, dst);
869 }
870
871
872 void Assembler::cmpb(Register dst, const Operand& src) {
873 ASSERT(dst.is_byte_register());
874 EnsureSpace ensure_space(this);
875 last_pc_ = pc_;
876 EMIT(0x3A);
877 emit_operand(dst, src);
878 }
879
880
863 void Assembler::cmpw(const Operand& op, Immediate imm16) { 881 void Assembler::cmpw(const Operand& op, Immediate imm16) {
864 ASSERT(imm16.is_int16()); 882 ASSERT(imm16.is_int16());
865 EnsureSpace ensure_space(this); 883 EnsureSpace ensure_space(this);
866 last_pc_ = pc_; 884 last_pc_ = pc_;
867 EMIT(0x66); 885 EMIT(0x66);
868 EMIT(0x81); 886 EMIT(0x81);
869 emit_operand(edi, op); 887 emit_operand(edi, op);
870 emit_w(imm16); 888 emit_w(imm16);
871 } 889 }
872 890
(...skipping 1501 matching lines...) Expand 10 before | Expand all | Expand 10 after
2374 push_insn[1] = 13; // Skip over coverage insns. 2392 push_insn[1] = 13; // Skip over coverage insns.
2375 if (coverage_log != NULL) { 2393 if (coverage_log != NULL) {
2376 fprintf(coverage_log, "%s\n", file_line); 2394 fprintf(coverage_log, "%s\n", file_line);
2377 fflush(coverage_log); 2395 fflush(coverage_log);
2378 } 2396 }
2379 } 2397 }
2380 2398
2381 #endif 2399 #endif
2382 2400
2383 } } // namespace v8::internal 2401 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/ia32/assembler-ia32.h ('k') | src/ia32/codegen-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698