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

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

Issue 6894043: Crankshaft support for IN. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 8 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
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 4200 matching lines...) Expand 10 before | Expand all | Expand 10 after
4211 4211
4212 // If the environment were already registered, we would have no way of 4212 // If the environment were already registered, we would have no way of
4213 // backpatching it with the spill slot operands. 4213 // backpatching it with the spill slot operands.
4214 ASSERT(!environment->HasBeenRegistered()); 4214 ASSERT(!environment->HasBeenRegistered());
4215 RegisterEnvironmentForDeoptimization(environment); 4215 RegisterEnvironmentForDeoptimization(environment);
4216 ASSERT(osr_pc_offset_ == -1); 4216 ASSERT(osr_pc_offset_ == -1);
4217 osr_pc_offset_ = masm()->pc_offset(); 4217 osr_pc_offset_ = masm()->pc_offset();
4218 } 4218 }
4219 4219
4220 4220
4221 void LCodeGen::DoIn(LIn* instr) {
4222 LOperand* obj = instr->object();
4223 LOperand* key = instr->key();
4224 if (key->IsConstantOperand()) {
4225 __ push(ToImmediate(key));
4226 } else {
4227 __ push(ToOperand(key));
4228 }
4229 if (obj->IsConstantOperand()) {
4230 __ push(ToImmediate(obj));
4231 } else {
4232 __ push(ToOperand(obj));
4233 }
4234 ASSERT(instr->HasPointerMap() && instr->HasDeoptimizationEnvironment());
4235 LPointerMap* pointers = instr->pointer_map();
4236 LEnvironment* env = instr->deoptimization_environment();
4237 RecordPosition(pointers->position());
4238 RegisterEnvironmentForDeoptimization(env);
4239 // Create safepoint generator that will also ensure enough space in the
4240 // reloc info for patching in deoptimization (since this is invoking a
4241 // builtin)
4242 SafepointGenerator safepoint_generator(this,
4243 pointers,
4244 env->deoptimization_index());
4245 __ mov(esi, Operand(ebp, StandardFrameConstants::kContextOffset));
4246 __ InvokeBuiltin(Builtins::IN, CALL_FUNCTION, &safepoint_generator);
4247 }
4248
4249
4221 #undef __ 4250 #undef __
4222 4251
4223 } } // namespace v8::internal 4252 } } // namespace v8::internal
4224 4253
4225 #endif // V8_TARGET_ARCH_IA32 4254 #endif // V8_TARGET_ARCH_IA32
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698