OLD | NEW |
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 1795 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1806 Code* entry = Code::cast(builtins_[i]); | 1806 Code* entry = Code::cast(builtins_[i]); |
1807 if (entry->contains(pc)) { | 1807 if (entry->contains(pc)) { |
1808 return names_[i]; | 1808 return names_[i]; |
1809 } | 1809 } |
1810 } | 1810 } |
1811 } | 1811 } |
1812 return NULL; | 1812 return NULL; |
1813 } | 1813 } |
1814 | 1814 |
1815 | 1815 |
| 1816 void Builtins::Generate_InterruptCheck(MacroAssembler* masm) { |
| 1817 masm->TailCallRuntime(Runtime::kInterrupt, 0, 1); |
| 1818 } |
| 1819 |
| 1820 |
| 1821 void Builtins::Generate_StackCheck(MacroAssembler* masm) { |
| 1822 masm->TailCallRuntime(Runtime::kStackGuard, 0, 1); |
| 1823 } |
| 1824 |
| 1825 |
1816 #define DEFINE_BUILTIN_ACCESSOR_C(name, ignore) \ | 1826 #define DEFINE_BUILTIN_ACCESSOR_C(name, ignore) \ |
1817 Handle<Code> Builtins::name() { \ | 1827 Handle<Code> Builtins::name() { \ |
1818 Code** code_address = \ | 1828 Code** code_address = \ |
1819 reinterpret_cast<Code**>(builtin_address(k##name)); \ | 1829 reinterpret_cast<Code**>(builtin_address(k##name)); \ |
1820 return Handle<Code>(code_address); \ | 1830 return Handle<Code>(code_address); \ |
1821 } | 1831 } |
1822 #define DEFINE_BUILTIN_ACCESSOR_A(name, kind, state, extra) \ | 1832 #define DEFINE_BUILTIN_ACCESSOR_A(name, kind, state, extra) \ |
1823 Handle<Code> Builtins::name() { \ | 1833 Handle<Code> Builtins::name() { \ |
1824 Code** code_address = \ | 1834 Code** code_address = \ |
1825 reinterpret_cast<Code**>(builtin_address(k##name)); \ | 1835 reinterpret_cast<Code**>(builtin_address(k##name)); \ |
1826 return Handle<Code>(code_address); \ | 1836 return Handle<Code>(code_address); \ |
1827 } | 1837 } |
1828 BUILTIN_LIST_C(DEFINE_BUILTIN_ACCESSOR_C) | 1838 BUILTIN_LIST_C(DEFINE_BUILTIN_ACCESSOR_C) |
1829 BUILTIN_LIST_A(DEFINE_BUILTIN_ACCESSOR_A) | 1839 BUILTIN_LIST_A(DEFINE_BUILTIN_ACCESSOR_A) |
1830 BUILTIN_LIST_DEBUG_A(DEFINE_BUILTIN_ACCESSOR_A) | 1840 BUILTIN_LIST_DEBUG_A(DEFINE_BUILTIN_ACCESSOR_A) |
1831 #undef DEFINE_BUILTIN_ACCESSOR_C | 1841 #undef DEFINE_BUILTIN_ACCESSOR_C |
1832 #undef DEFINE_BUILTIN_ACCESSOR_A | 1842 #undef DEFINE_BUILTIN_ACCESSOR_A |
1833 | 1843 |
1834 | 1844 |
1835 } } // namespace v8::internal | 1845 } } // namespace v8::internal |
OLD | NEW |