From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21404 invoked by alias); 25 May 2005 15:03:19 -0000 Mailing-List: contact java-prs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: java-prs-owner@gcc.gnu.org Received: (qmail 21346 invoked by uid 48); 25 May 2005 15:03:17 -0000 Date: Wed, 25 May 2005 15:03:00 -0000 From: "mckinlay at redhat dot com" To: java-prs@gcc.gnu.org Message-ID: <20050525150311.21753.mckinlay@redhat.com> Reply-To: gcc-bugzilla@gcc.gnu.org Subject: [Bug libgcj/21753] New: String.substring sharing heuristic should be improved X-Bugzilla-Reason: CC X-SW-Source: 2005-q2/txt/msg00566.txt.bz2 List-Id: The heuristic for sharing String data in String.substring() can result in significant memory bloat in certain cases. Currently, it will always share String data unless the resulting substring is <= 8 characters in size. In many applications, it seems common for the initial string to be discarded once a substring has been taken - thus it probably makes sense to share only when the substring represents a significant proportion of the original string's size. See this thread for more information: http://gcc.gnu.org/ml/java-patches/2005-q2/msg00449.html -- Summary: String.substring sharing heuristic should be improved Product: gcc Version: 4.1.0 Status: UNCONFIRMED Severity: normal Priority: P2 Component: libgcj AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: mckinlay at redhat dot com CC: gcc-bugs at gcc dot gnu dot org,java-prs at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21753