From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS4713 221.184.0.0/13 X-Spam-Status: No, score=-4.1 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from neon.ruby-lang.org (neon.ruby-lang.org [221.186.184.75]) by dcvr.yhbt.net (Postfix) with ESMTP id B9CFF1F461 for ; Tue, 14 May 2019 05:41:33 +0000 (UTC) Received: from neon.ruby-lang.org (localhost [IPv6:::1]) by neon.ruby-lang.org (Postfix) with ESMTP id 3A8D51209FB; Tue, 14 May 2019 14:41:29 +0900 (JST) Received: from o1678948x4.outbound-mail.sendgrid.net (o1678948x4.outbound-mail.sendgrid.net [167.89.48.4]) by neon.ruby-lang.org (Postfix) with ESMTPS id 119361209D0 for ; Tue, 14 May 2019 14:41:26 +0900 (JST) Received: by filter0080p3mdw1.sendgrid.net with SMTP id filter0080p3mdw1-25118-5CDA5507-26 2019-05-14 05:41:27.735429718 +0000 UTC m=+41937.119698973 Received: from herokuapp.com (unknown [52.72.240.185]) by ismtpd0024p1iad2.sendgrid.net (SG) with ESMTP id wsToLeikTC6D_GIrgRFAGA for ; Tue, 14 May 2019 05:41:27.830 +0000 (UTC) Date: Tue, 14 May 2019 05:41:27 +0000 (UTC) From: duerst@it.aoyama.ac.jp Message-ID: References: Mime-Version: 1.0 X-Redmine-MailingListIntegration-Message-Ids: 68124 X-Redmine-Project: ruby-trunk X-Redmine-Issue-Id: 15844 X-Redmine-Issue-Author: alangano X-Redmine-Sender: duerst X-Mailer: Redmine X-Redmine-Host: bugs.ruby-lang.org X-Redmine-Site: Ruby Issue Tracking System X-Auto-Response-Suppress: All Auto-Submitted: auto-generated X-SG-EID: =?us-ascii?Q?uQY=2F2xNrNfHHTWbKn6MBvvzfU5Pqk9I4lnOVb0CFDus9ZVjD7B26219pM9SaiA?= =?us-ascii?Q?ri2hfnGG8a5=2FQEgMTKeb5yaprx11fv9p0dsT7ho?= =?us-ascii?Q?6bz4toLJkMKrZb0E5i416HFybta5wvgShvUu7xY?= =?us-ascii?Q?30uv8bLf6zPU9m508ycy6=2F0VtiNDj0M00nEaYjp?= =?us-ascii?Q?qsFBI0U39LwL4bunyPaJWyrX6yIngDWwFbw=3D=3D?= To: ruby-core@ruby-lang.org X-ML-Name: ruby-core X-Mail-Count: 92641 Subject: [ruby-core:92641] [Ruby trunk Bug#15844] VM has trouble releasing memory (?) on NoMethodError X-BeenThere: ruby-core@ruby-lang.org X-Mailman-Version: 2.1.15 Precedence: list Reply-To: Ruby developers List-Id: Ruby developers List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Errors-To: ruby-core-bounces@ruby-lang.org Sender: "ruby-core" Issue #15844 has been updated by duerst (Martin D=FCrst). nobu (Nobuyoshi Nakada) wrote: > On exiting by an exception, ruby tries to print the exception and `NoMeth= odError` shows its receiver. > Your `Node` is a recursive construction, so it increases exponentially by= the size. Recursion should not be a problem. Cycles definitely will be a problem. > Define your own `inspect` method not to include `@left` and `@right` memb= ers. This is definitely the right way to go. But would it make sense to wrap the= error output in a timeout, to make it easier to debug such problems in the= field? I can create a feature for this. ---------------------------------------- Bug #15844: VM has trouble releasing memory (?) on NoMethodError https://bugs.ruby-lang.org/issues/15844#change-78004 * Author: alangano (Alan Gano) * Status: Rejected * Priority: Normal * Assignee: = * Target version: = * ruby -v: ruby 2.6.3p62 (2019-04-16 revision 67580) [x86_64-linux] * Backport: 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN ---------------------------------------- When the test case is run, the process goes haywire. I observe RSS bouncin= g around, and trending upwards. CPU on the process is at 100%. The test case is a partial implementation of a binary tree which is also a = doubly linked list. I chopped it down as far as I could. The issue is triggered by a calling a non-existent method on the Tree objec= t. The test case only has 100 nodes -- it should be instantaneous. I kill= it after some 6+ minutes with RSS hitting upwards of 5GB. I am working in 2.6.3. Duplicated in 2.5.3 and 2.4.3 (with some code modif= ications) ---Files-------------------------------- issue.rb (2.67 KB) -- = https://bugs.ruby-lang.org/ Unsubscribe: