Commit f6a85768 authored by Ross McIlroy's avatar Ross McIlroy Committed by Commit Bot

[Compile] Remove unecessary class_function_descriptors access.

BuildClassBoilerplate accessed the native context to get the
class_function_descriptors. Baseline compilation should be native context
independent, so we shouldn't access the native context at all. As it happens,
class_function_descriptors wasn't used so can just be removed.

BUG=chromium:898076, v8:8041

Change-Id: If9c0edf3dfde68c76ea87820f9d4b080aac6d60e
Reviewed-on: https://chromium-review.googlesource.com/c/1298033Reviewed-by: 's avatarLeszek Swirski <leszeks@chromium.org>
Commit-Queue: Ross McIlroy <rmcilroy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#56958}
parent ac3f98d5
...@@ -460,9 +460,6 @@ Handle<ClassBoilerplate> ClassBoilerplate::BuildClassBoilerplate( ...@@ -460,9 +460,6 @@ Handle<ClassBoilerplate> ClassBoilerplate::BuildClassBoilerplate(
// Initialize class object template. // Initialize class object template.
// //
static_desc.CreateTemplates(isolate, kMinimumClassPropertiesCount); static_desc.CreateTemplates(isolate, kMinimumClassPropertiesCount);
Handle<DescriptorArray> class_function_descriptors(
isolate->native_context()->class_function_map()->instance_descriptors(),
isolate);
STATIC_ASSERT(JSFunction::kLengthDescriptorIndex == 0); STATIC_ASSERT(JSFunction::kLengthDescriptorIndex == 0);
{ {
// Add length_accessor. // Add length_accessor.
......
...@@ -53,3 +53,8 @@ assertEquals(b, 43); ...@@ -53,3 +53,8 @@ assertEquals(b, 43);
assertEquals(c, 43); assertEquals(c, 43);
var c = (a, b = (function z(){ return a+1; })()) => { return b; }; var c = (a, b = (function z(){ return a+1; })()) => { return b; };
assertEquals(c(314), 315); assertEquals(c(314), 315);
// http://crbug.com/898076
(function() {
class foo {};
}); // Don't call IIFE so that it is compiled during idle time
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment