Skip to content
  • NARUSE, Yui's avatar
    f79b1d1e
    merge revision(s)... · f79b1d1e
    NARUSE, Yui authored
    merge revision(s) e626da82,f3af5ae7: [Backport #20311] (#10312)
    
    Don't pin named structs defined in Ruby
    
    	[Bug #20311]
    
    	`rb_define_class_under` assumes it's called from C and that the
    	reference might be held in a C global variable, so it adds the
    	class to the VM root.
    
    	In the case of `Struct.new('Name')` it's wasteful and make
    	the struct immortal.
    
    	Make Struct memory leak test faster
    
    	[Bug #20311]
    
    	It times out on some platform, so we can reduce iterations.
    	On my machine it completes in 250ms and RSS grows 8X.
    f79b1d1e
    merge revision(s)...
    NARUSE, Yui authored
    merge revision(s) e626da82,f3af5ae7: [Backport #20311] (#10312)
    
    Don't pin named structs defined in Ruby
    
    	[Bug #20311]
    
    	`rb_define_class_under` assumes it's called from C and that the
    	reference might be held in a C global variable, so it adds the
    	class to the VM root.
    
    	In the case of `Struct.new('Name')` it's wasteful and make
    	the struct immortal.
    
    	Make Struct memory leak test faster
    
    	[Bug #20311]
    
    	It times out on some platform, so we can reduce iterations.
    	On my machine it completes in 250ms and RSS grows 8X.
Loading