| 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 #include "src/v8.h" | 5 #include "src/v8.h" |
| 6 | 6 |
| 7 #include "src/runtime/runtime.h" | 7 #include "src/runtime/runtime.h" |
| 8 #include "src/runtime/runtime-utils.h" | 8 #include "src/runtime/runtime-utils.h" |
| 9 | 9 |
| 10 namespace v8 { | 10 namespace v8 { |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 83 } | 83 } |
| 84 return NULL; | 84 return NULL; |
| 85 } | 85 } |
| 86 | 86 |
| 87 | 87 |
| 88 const Runtime::Function* Runtime::FunctionForId(Runtime::FunctionId id) { | 88 const Runtime::Function* Runtime::FunctionForId(Runtime::FunctionId id) { |
| 89 return &(kIntrinsicFunctions[static_cast<int>(id)]); | 89 return &(kIntrinsicFunctions[static_cast<int>(id)]); |
| 90 } | 90 } |
| 91 | 91 |
| 92 | 92 |
| 93 bool Runtime::SupportsTailCall(FunctionId id) { |
| 94 switch (id) { |
| 95 #define RUNTIME_FUNCTION_SWITCH(name, a, b) case k##name: |
| 96 FOR_EACH_INTRINSIC_IC(RUNTIME_FUNCTION_SWITCH) |
| 97 #undef RUNTIME_FUNCTION_SWITCH |
| 98 return true; |
| 99 default: |
| 100 return false; |
| 101 } |
| 102 } |
| 103 |
| 104 |
| 93 std::ostream& operator<<(std::ostream& os, Runtime::FunctionId id) { | 105 std::ostream& operator<<(std::ostream& os, Runtime::FunctionId id) { |
| 94 return os << Runtime::FunctionForId(id)->name; | 106 return os << Runtime::FunctionForId(id)->name; |
| 95 } | 107 } |
| 96 | 108 |
| 97 } // namespace internal | 109 } // namespace internal |
| 98 } // namespace v8 | 110 } // namespace v8 |
| OLD | NEW |