| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent e5cce7a commit 2870061
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1835,6 +1835,11 @@ void InstanceOfStub::Generate(MacroAssembler* masm) { | |||
| 1835 | 1835 | __ CmpObjectType(function, JS_FUNCTION_TYPE, function_map); | |
| 1836 | 1836 | __ j(not_equal, &slow_case); | |
| 1837 | 1837 | ||
| 1838 | + // Go to the runtime if the function is not a constructor. | ||
| 1839 | + __ test_b(FieldOperand(function_map, Map::kBitFieldOffset), | ||
| 1840 | + static_cast<uint8_t>(1 << Map::kIsConstructor)); | ||
| 1841 | + __ j(zero, &slow_case); | ||
| 1842 | + | ||
| 1838 | 1843 | // Ensure that {function} has an instance prototype. | |
| 1839 | 1844 | __ test_b(FieldOperand(function_map, Map::kBitFieldOffset), | |
| 1840 | 1845 | static_cast<uint8_t>(1 << Map::kHasNonInstancePrototype)); | |
| Back | FazBrowse Home | New Git URL |
0 commit comments