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

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

Issue 9838059: Rollback of r11118, r11109 in trunk branch. (Closed) Base URL: https://v8.googlecode.com/svn/trunk
Patch Set: 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 2525 matching lines...) Expand 10 before | Expand all | Expand 10 after
2536 ASSERT(ToRegister(instr->key()).is(eax)); 2536 ASSERT(ToRegister(instr->key()).is(eax));
2537 2537
2538 Handle<Code> ic = isolate()->builtins()->KeyedLoadIC_Initialize(); 2538 Handle<Code> ic = isolate()->builtins()->KeyedLoadIC_Initialize();
2539 CallCode(ic, RelocInfo::CODE_TARGET, instr); 2539 CallCode(ic, RelocInfo::CODE_TARGET, instr);
2540 } 2540 }
2541 2541
2542 2542
2543 void LCodeGen::DoArgumentsElements(LArgumentsElements* instr) { 2543 void LCodeGen::DoArgumentsElements(LArgumentsElements* instr) {
2544 Register result = ToRegister(instr->result()); 2544 Register result = ToRegister(instr->result());
2545 2545
2546 if (instr->from_inlined()) { 2546 // Check for arguments adapter frame.
2547 __ lea(result, Operand(esp, -2 * kPointerSize)); 2547 Label done, adapted;
2548 } else { 2548 __ mov(result, Operand(ebp, StandardFrameConstants::kCallerFPOffset));
2549 // Check for arguments adapter frame. 2549 __ mov(result, Operand(result, StandardFrameConstants::kContextOffset));
2550 Label done, adapted; 2550 __ cmp(Operand(result),
2551 __ mov(result, Operand(ebp, StandardFrameConstants::kCallerFPOffset)); 2551 Immediate(Smi::FromInt(StackFrame::ARGUMENTS_ADAPTOR)));
2552 __ mov(result, Operand(result, StandardFrameConstants::kContextOffset)); 2552 __ j(equal, &adapted, Label::kNear);
2553 __ cmp(Operand(result),
2554 Immediate(Smi::FromInt(StackFrame::ARGUMENTS_ADAPTOR)));
2555 __ j(equal, &adapted, Label::kNear);
2556 2553
2557 // No arguments adaptor frame. 2554 // No arguments adaptor frame.
2558 __ mov(result, Operand(ebp)); 2555 __ mov(result, Operand(ebp));
2559 __ jmp(&done, Label::kNear); 2556 __ jmp(&done, Label::kNear);
2560 2557
2561 // Arguments adaptor frame present. 2558 // Arguments adaptor frame present.
2562 __ bind(&adapted); 2559 __ bind(&adapted);
2563 __ mov(result, Operand(ebp, StandardFrameConstants::kCallerFPOffset)); 2560 __ mov(result, Operand(ebp, StandardFrameConstants::kCallerFPOffset));
2564 2561
2565 // Result is the frame pointer for the frame if not adapted and for the real 2562 // Result is the frame pointer for the frame if not adapted and for the real
2566 // frame below the adaptor frame if adapted. 2563 // frame below the adaptor frame if adapted.
2567 __ bind(&done); 2564 __ bind(&done);
2568 }
2569 } 2565 }
2570 2566
2571 2567
2572 void LCodeGen::DoArgumentsLength(LArgumentsLength* instr) { 2568 void LCodeGen::DoArgumentsLength(LArgumentsLength* instr) {
2573 Operand elem = ToOperand(instr->InputAt(0)); 2569 Operand elem = ToOperand(instr->InputAt(0));
2574 Register result = ToRegister(instr->result()); 2570 Register result = ToRegister(instr->result());
2575 2571
2576 Label done; 2572 Label done;
2577 2573
2578 // If no arguments adaptor frame the number of arguments is fixed. 2574 // If no arguments adaptor frame the number of arguments is fixed.
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
2680 safepoint_generator, CALL_AS_METHOD); 2676 safepoint_generator, CALL_AS_METHOD);
2681 } 2677 }
2682 2678
2683 2679
2684 void LCodeGen::DoPushArgument(LPushArgument* instr) { 2680 void LCodeGen::DoPushArgument(LPushArgument* instr) {
2685 LOperand* argument = instr->InputAt(0); 2681 LOperand* argument = instr->InputAt(0);
2686 EmitPushTaggedOperand(argument); 2682 EmitPushTaggedOperand(argument);
2687 } 2683 }
2688 2684
2689 2685
2690 void LCodeGen::DoPop(LPop* instr) {
2691 __ Drop(instr->count());
2692 }
2693
2694
2695 void LCodeGen::DoThisFunction(LThisFunction* instr) { 2686 void LCodeGen::DoThisFunction(LThisFunction* instr) {
2696 Register result = ToRegister(instr->result()); 2687 Register result = ToRegister(instr->result());
2697 __ LoadHeapObject(result, instr->hydrogen()->closure()); 2688 __ LoadHeapObject(result, instr->hydrogen()->closure());
2698 } 2689 }
2699 2690
2700 2691
2701 void LCodeGen::DoContext(LContext* instr) { 2692 void LCodeGen::DoContext(LContext* instr) {
2702 Register result = ToRegister(instr->result()); 2693 Register result = ToRegister(instr->result());
2703 __ mov(result, Operand(ebp, StandardFrameConstants::kContextOffset)); 2694 __ mov(result, Operand(ebp, StandardFrameConstants::kContextOffset));
2704 } 2695 }
(...skipping 2281 matching lines...) Expand 10 before | Expand all | Expand 10 after
4986 FixedArray::kHeaderSize - kPointerSize)); 4977 FixedArray::kHeaderSize - kPointerSize));
4987 __ bind(&done); 4978 __ bind(&done);
4988 } 4979 }
4989 4980
4990 4981
4991 #undef __ 4982 #undef __
4992 4983
4993 } } // namespace v8::internal 4984 } } // namespace v8::internal
4994 4985
4995 #endif // V8_TARGET_ARCH_IA32 4986 #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