OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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 #include "src/compiler/code-generator.h" | 5 #include "src/compiler/code-generator.h" |
6 | 6 |
7 #include "src/compiler/code-generator-impl.h" | 7 #include "src/compiler/code-generator-impl.h" |
8 #include "src/compiler/gap-resolver.h" | 8 #include "src/compiler/gap-resolver.h" |
9 #include "src/compiler/node-matchers.h" | 9 #include "src/compiler/node-matchers.h" |
10 #include "src/compiler/node-properties-inl.h" | 10 #include "src/compiler/node-properties-inl.h" |
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
207 case kArchCallCodeObject: { | 207 case kArchCallCodeObject: { |
208 if (HasImmediateInput(instr, 0)) { | 208 if (HasImmediateInput(instr, 0)) { |
209 Handle<Code> code = Handle<Code>::cast(i.InputHeapObject(0)); | 209 Handle<Code> code = Handle<Code>::cast(i.InputHeapObject(0)); |
210 __ Call(code, RelocInfo::CODE_TARGET); | 210 __ Call(code, RelocInfo::CODE_TARGET); |
211 } else { | 211 } else { |
212 Register reg = i.InputRegister(0); | 212 Register reg = i.InputRegister(0); |
213 int entry = Code::kHeaderSize - kHeapObjectTag; | 213 int entry = Code::kHeaderSize - kHeapObjectTag; |
214 __ Call(Operand(reg, entry)); | 214 __ Call(Operand(reg, entry)); |
215 } | 215 } |
216 AddSafepointAndDeopt(instr); | 216 AddSafepointAndDeopt(instr); |
217 AddNopForSmiCodeInlining(); | |
218 break; | 217 break; |
219 } | 218 } |
220 case kArchCallAddress: | 219 case kArchCallAddress: |
221 if (HasImmediateInput(instr, 0)) { | 220 if (HasImmediateInput(instr, 0)) { |
222 Immediate64 imm = i.InputImmediate64(0); | 221 Immediate64 imm = i.InputImmediate64(0); |
223 DCHECK_EQ(kImm64Value, imm.type); | 222 DCHECK_EQ(kImm64Value, imm.type); |
224 __ Call(reinterpret_cast<byte*>(imm.value), RelocInfo::NONE64); | 223 __ Call(reinterpret_cast<byte*>(imm.value), RelocInfo::NONE64); |
225 } else { | 224 } else { |
226 __ call(i.InputRegister(0)); | 225 __ call(i.InputRegister(0)); |
227 } | 226 } |
(...skipping 769 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
997 } | 996 } |
998 | 997 |
999 | 998 |
1000 void CodeGenerator::AddNopForSmiCodeInlining() { __ nop(); } | 999 void CodeGenerator::AddNopForSmiCodeInlining() { __ nop(); } |
1001 | 1000 |
1002 #undef __ | 1001 #undef __ |
1003 | 1002 |
1004 } // namespace internal | 1003 } // namespace internal |
1005 } // namespace compiler | 1004 } // namespace compiler |
1006 } // namespace v8 | 1005 } // namespace v8 |
OLD | NEW |