Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: bdfb371da1064fa61e0d125e18522d88667b8aef
Ticket: 231523ffffffffffffffffffffffffffffffffff
[split $longString ""] uses far too much memory
User & Date: dkf on 2001-02-08 11:56:00
Changes

  1. assignee changed to: "nobody"
  2. cmimetype changed to: "text/plain"
  3. comment changed to:
    When you feed a 5MB string into [split ... ""], it creates a completely new Tcl_Obj for each character (that's a cost of at least 120MB on a 32-bit architecture!)  Surely it should be possible and even imperative that some kind of sharing between character strings should happen in this case?  Even just doing this for the ASCII subset or the first UNICODE page (i.e. to better handle binary data) would be an immense benefit in the normal case.
    
  4. foundin changed to: "obsolete: 8.4a2"
  5. priority changed to: "5 Medium"
  6. resolution changed to: "None"
  7. status changed to: "Open"
  8. submitter changed to: "dkf"
  9. subsystem changed to: "18. Commands M-Z"
  10. title changed to: "[split $longString ""] uses far too much memory"
  11. type changed to: "Bug"