OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #if V8_TARGET_ARCH_IA32 | 5 #if V8_TARGET_ARCH_IA32 |
6 | 6 |
7 #include "src/base/bits.h" | 7 #include "src/base/bits.h" |
8 #include "src/base/division-by-constant.h" | 8 #include "src/base/division-by-constant.h" |
9 #include "src/bootstrapper.h" | 9 #include "src/bootstrapper.h" |
10 #include "src/codegen.h" | 10 #include "src/codegen.h" |
(...skipping 2049 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2060 call_wrapper.AfterCall(); | 2060 call_wrapper.AfterCall(); |
2061 } else { | 2061 } else { |
2062 DCHECK(flag == JUMP_FUNCTION); | 2062 DCHECK(flag == JUMP_FUNCTION); |
2063 jmp(code); | 2063 jmp(code); |
2064 } | 2064 } |
2065 bind(&done); | 2065 bind(&done); |
2066 } | 2066 } |
2067 } | 2067 } |
2068 | 2068 |
2069 | 2069 |
2070 void MacroAssembler::InvokeFunction(Register fun, | 2070 void MacroAssembler::InvokeFunction(Register fun, Register new_target, |
2071 Register new_target, | |
2072 const ParameterCount& actual, | 2071 const ParameterCount& actual, |
2073 InvokeFlag flag, | 2072 InvokeFlag flag, |
2074 const CallWrapper& call_wrapper) { | 2073 const CallWrapper& call_wrapper) { |
2075 // You can't call a function without a valid frame. | 2074 // You can't call a function without a valid frame. |
2076 DCHECK(flag == JUMP_FUNCTION || has_frame()); | 2075 DCHECK(flag == JUMP_FUNCTION || has_frame()); |
2077 | 2076 |
2078 DCHECK(fun.is(edi)); | 2077 DCHECK(fun.is(edi)); |
2079 mov(ebx, FieldOperand(edi, JSFunction::kSharedFunctionInfoOffset)); | 2078 mov(ebx, FieldOperand(edi, JSFunction::kSharedFunctionInfoOffset)); |
2080 mov(esi, FieldOperand(edi, JSFunction::kContextOffset)); | 2079 mov(esi, FieldOperand(edi, JSFunction::kContextOffset)); |
2081 mov(ebx, FieldOperand(ebx, SharedFunctionInfo::kFormalParameterCountOffset)); | 2080 mov(ebx, FieldOperand(ebx, SharedFunctionInfo::kFormalParameterCountOffset)); |
(...skipping 1093 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3175 mov(eax, dividend); | 3174 mov(eax, dividend); |
3176 shr(eax, 31); | 3175 shr(eax, 31); |
3177 add(edx, eax); | 3176 add(edx, eax); |
3178 } | 3177 } |
3179 | 3178 |
3180 | 3179 |
3181 } // namespace internal | 3180 } // namespace internal |
3182 } // namespace v8 | 3181 } // namespace v8 |
3183 | 3182 |
3184 #endif // V8_TARGET_ARCH_IA32 | 3183 #endif // V8_TARGET_ARCH_IA32 |
OLD | NEW |