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

Side by Side Diff: src/ia32/lithium-codegen-ia32.cc

Issue 9616014: Improve polymorphic loads on single slots. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Renamed CheckMap to CheckMaps. Created 8 years, 9 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/hydrogen-instructions.cc ('k') | src/ia32/lithium-ia32.h » ('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 // 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 4101 matching lines...) Expand 10 before | Expand all | Expand 10 after
4112 Handle<Map> map, 4112 Handle<Map> map,
4113 CompareMapMode mode, 4113 CompareMapMode mode,
4114 LEnvironment* env) { 4114 LEnvironment* env) {
4115 Label success; 4115 Label success;
4116 __ CompareMap(reg, map, &success, mode); 4116 __ CompareMap(reg, map, &success, mode);
4117 DeoptimizeIf(not_equal, env); 4117 DeoptimizeIf(not_equal, env);
4118 __ bind(&success); 4118 __ bind(&success);
4119 } 4119 }
4120 4120
4121 4121
4122 void LCodeGen::DoCheckMap(LCheckMap* instr) { 4122 void LCodeGen::DoCheckMaps(LCheckMaps* instr) {
4123 LOperand* input = instr->InputAt(0); 4123 LOperand* input = instr->InputAt(0);
4124 ASSERT(input->IsRegister()); 4124 ASSERT(input->IsRegister());
4125 Register reg = ToRegister(input); 4125 Register reg = ToRegister(input);
4126 Handle<Map> map = instr->hydrogen()->map(); 4126
4127 DoCheckMapCommon(reg, map, instr->hydrogen()->mode(), instr->environment()); 4127 Label success;
4128 SmallMapList* map_set = instr->hydrogen()->map_set();
4129 for (int i = 0; i < map_set->length() - 1; i++) {
4130 Handle<Map> map = map_set->at(i);
4131 __ CompareMap(reg, map, &success, REQUIRE_EXACT_MAP);
4132 __ j(equal, &success);
4133 }
4134 Handle<Map> map = map_set->last();
4135 DoCheckMapCommon(reg, map, REQUIRE_EXACT_MAP, instr->environment());
4136 __ bind(&success);
4128 } 4137 }
4129 4138
4130 4139
4131 void LCodeGen::DoClampDToUint8(LClampDToUint8* instr) { 4140 void LCodeGen::DoClampDToUint8(LClampDToUint8* instr) {
4132 XMMRegister value_reg = ToDoubleRegister(instr->unclamped()); 4141 XMMRegister value_reg = ToDoubleRegister(instr->unclamped());
4133 Register result_reg = ToRegister(instr->result()); 4142 Register result_reg = ToRegister(instr->result());
4134 __ ClampDoubleToUint8(value_reg, xmm0, result_reg); 4143 __ ClampDoubleToUint8(value_reg, xmm0, result_reg);
4135 } 4144 }
4136 4145
4137 4146
(...skipping 763 matching lines...) Expand 10 before | Expand all | Expand 10 after
4901 FixedArray::kHeaderSize - kPointerSize)); 4910 FixedArray::kHeaderSize - kPointerSize));
4902 __ bind(&done); 4911 __ bind(&done);
4903 } 4912 }
4904 4913
4905 4914
4906 #undef __ 4915 #undef __
4907 4916
4908 } } // namespace v8::internal 4917 } } // namespace v8::internal
4909 4918
4910 #endif // V8_TARGET_ARCH_IA32 4919 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/hydrogen-instructions.cc ('k') | src/ia32/lithium-ia32.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698