| OLD | NEW |
| 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 2061 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2072 __ mov(cell_operand, value); | 2072 __ mov(cell_operand, value); |
| 2073 } | 2073 } |
| 2074 | 2074 |
| 2075 | 2075 |
| 2076 void LCodeGen::DoStoreGlobalGeneric(LStoreGlobalGeneric* instr) { | 2076 void LCodeGen::DoStoreGlobalGeneric(LStoreGlobalGeneric* instr) { |
| 2077 ASSERT(ToRegister(instr->context()).is(esi)); | 2077 ASSERT(ToRegister(instr->context()).is(esi)); |
| 2078 ASSERT(ToRegister(instr->global_object()).is(edx)); | 2078 ASSERT(ToRegister(instr->global_object()).is(edx)); |
| 2079 ASSERT(ToRegister(instr->value()).is(eax)); | 2079 ASSERT(ToRegister(instr->value()).is(eax)); |
| 2080 | 2080 |
| 2081 __ mov(ecx, instr->name()); | 2081 __ mov(ecx, instr->name()); |
| 2082 Handle<Code> ic = isolate()->builtins()->StoreIC_Initialize(); | 2082 Handle<Code> ic = instr->strict_mode() |
| 2083 ? isolate()->builtins()->StoreIC_Initialize_Strict() |
| 2084 : isolate()->builtins()->StoreIC_Initialize(); |
| 2083 CallCode(ic, RelocInfo::CODE_TARGET_CONTEXT, instr); | 2085 CallCode(ic, RelocInfo::CODE_TARGET_CONTEXT, instr); |
| 2084 } | 2086 } |
| 2085 | 2087 |
| 2086 | 2088 |
| 2087 void LCodeGen::DoLoadContextSlot(LLoadContextSlot* instr) { | 2089 void LCodeGen::DoLoadContextSlot(LLoadContextSlot* instr) { |
| 2088 Register context = ToRegister(instr->context()); | 2090 Register context = ToRegister(instr->context()); |
| 2089 Register result = ToRegister(instr->result()); | 2091 Register result = ToRegister(instr->result()); |
| 2090 __ mov(result, ContextOperand(context, instr->slot_index())); | 2092 __ mov(result, ContextOperand(context, instr->slot_index())); |
| 2091 } | 2093 } |
| 2092 | 2094 |
| (...skipping 871 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2964 } | 2966 } |
| 2965 } | 2967 } |
| 2966 | 2968 |
| 2967 | 2969 |
| 2968 void LCodeGen::DoStoreNamedGeneric(LStoreNamedGeneric* instr) { | 2970 void LCodeGen::DoStoreNamedGeneric(LStoreNamedGeneric* instr) { |
| 2969 ASSERT(ToRegister(instr->context()).is(esi)); | 2971 ASSERT(ToRegister(instr->context()).is(esi)); |
| 2970 ASSERT(ToRegister(instr->object()).is(edx)); | 2972 ASSERT(ToRegister(instr->object()).is(edx)); |
| 2971 ASSERT(ToRegister(instr->value()).is(eax)); | 2973 ASSERT(ToRegister(instr->value()).is(eax)); |
| 2972 | 2974 |
| 2973 __ mov(ecx, instr->name()); | 2975 __ mov(ecx, instr->name()); |
| 2974 Handle<Code> ic = info_->is_strict_mode() | 2976 Handle<Code> ic = instr->strict_mode() |
| 2975 ? isolate()->builtins()->StoreIC_Initialize_Strict() | 2977 ? isolate()->builtins()->StoreIC_Initialize_Strict() |
| 2976 : isolate()->builtins()->StoreIC_Initialize(); | 2978 : isolate()->builtins()->StoreIC_Initialize(); |
| 2977 CallCode(ic, RelocInfo::CODE_TARGET, instr); | 2979 CallCode(ic, RelocInfo::CODE_TARGET, instr); |
| 2978 } | 2980 } |
| 2979 | 2981 |
| 2980 | 2982 |
| 2981 void LCodeGen::DoBoundsCheck(LBoundsCheck* instr) { | 2983 void LCodeGen::DoBoundsCheck(LBoundsCheck* instr) { |
| 2982 __ cmp(ToRegister(instr->index()), ToOperand(instr->length())); | 2984 __ cmp(ToRegister(instr->index()), ToOperand(instr->length())); |
| 2983 DeoptimizeIf(above_equal, instr->environment()); | 2985 DeoptimizeIf(above_equal, instr->environment()); |
| 2984 } | 2986 } |
| (...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3064 } | 3066 } |
| 3065 } | 3067 } |
| 3066 | 3068 |
| 3067 | 3069 |
| 3068 void LCodeGen::DoStoreKeyedGeneric(LStoreKeyedGeneric* instr) { | 3070 void LCodeGen::DoStoreKeyedGeneric(LStoreKeyedGeneric* instr) { |
| 3069 ASSERT(ToRegister(instr->context()).is(esi)); | 3071 ASSERT(ToRegister(instr->context()).is(esi)); |
| 3070 ASSERT(ToRegister(instr->object()).is(edx)); | 3072 ASSERT(ToRegister(instr->object()).is(edx)); |
| 3071 ASSERT(ToRegister(instr->key()).is(ecx)); | 3073 ASSERT(ToRegister(instr->key()).is(ecx)); |
| 3072 ASSERT(ToRegister(instr->value()).is(eax)); | 3074 ASSERT(ToRegister(instr->value()).is(eax)); |
| 3073 | 3075 |
| 3074 Handle<Code> ic = info_->is_strict_mode() | 3076 Handle<Code> ic = instr->strict_mode() |
| 3075 ? isolate()->builtins()->KeyedStoreIC_Initialize_Strict() | 3077 ? isolate()->builtins()->KeyedStoreIC_Initialize_Strict() |
| 3076 : isolate()->builtins()->KeyedStoreIC_Initialize(); | 3078 : isolate()->builtins()->KeyedStoreIC_Initialize(); |
| 3077 CallCode(ic, RelocInfo::CODE_TARGET, instr); | 3079 CallCode(ic, RelocInfo::CODE_TARGET, instr); |
| 3078 } | 3080 } |
| 3079 | 3081 |
| 3080 | 3082 |
| 3081 void LCodeGen::DoStringCharCodeAt(LStringCharCodeAt* instr) { | 3083 void LCodeGen::DoStringCharCodeAt(LStringCharCodeAt* instr) { |
| 3082 class DeferredStringCharCodeAt: public LDeferredCode { | 3084 class DeferredStringCharCodeAt: public LDeferredCode { |
| 3083 public: | 3085 public: |
| 3084 DeferredStringCharCodeAt(LCodeGen* codegen, LStringCharCodeAt* instr) | 3086 DeferredStringCharCodeAt(LCodeGen* codegen, LStringCharCodeAt* instr) |
| (...skipping 1064 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4149 ASSERT(osr_pc_offset_ == -1); | 4151 ASSERT(osr_pc_offset_ == -1); |
| 4150 osr_pc_offset_ = masm()->pc_offset(); | 4152 osr_pc_offset_ = masm()->pc_offset(); |
| 4151 } | 4153 } |
| 4152 | 4154 |
| 4153 | 4155 |
| 4154 #undef __ | 4156 #undef __ |
| 4155 | 4157 |
| 4156 } } // namespace v8::internal | 4158 } } // namespace v8::internal |
| 4157 | 4159 |
| 4158 #endif // V8_TARGET_ARCH_IA32 | 4160 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |