patchGNU Octave - Patches: patch #7923, Reducing memory usage in perms:...

 
 

patch #7923: Reducing memory usage in perms: patch attached

Submitter:  Arun Giridhar <arungiridhar>
Submitted:  Mon 14 Jan 2013 09:59:40 PM UTC
   
 
Category:  None Priority:  5 - Normal
Status:  Done Privacy:  Public
Assigned to:  None Open/Closed:  Closed
* Mandatory Fields

Add a New Comment Rich Markup
   

Sat 10 Aug 2013 04:54:43 AM UTC, comment #1: 

Thanks for this.  I just got around to applying the patch here (http://hg.savannah.gnu.org/hgweb/octave/rev/9336d0e1d1ec).  I also added your name to the list of contributors.  Thanks again.

Rik <rik5>
Group administrator
Mon 14 Jan 2013 09:59:40 PM UTC, original submission:  

I noticed that calling perms(uint8(1:11)) on a system with 4GB memory thrashed the virtual memory even though the input was only type 8-bit integer. I found that perms was using the default type double in a couple of places internally. I have attached a context diff showing two small changes I made to octave/scripts/specfun/perms.m, which reduce memory usage substantially. In particular, perms(uint8(1:11)) now returns without thrashing virtual memory. Hope this helps.

Arun Giridhar <arungiridhar>
Group Member

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #27264:  perm.diff added by arungiridhar (778B - text/x-patch - Context diff for octave/scripts/specfun/perms.m to reduce internal memory usage)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by arungiridhar (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2013-08-10 rik5 StatusNone Done
        Open/ClosedOpen Closed
    2013-01-14 arungiridhar Attached File- Added perm.diff, #27264

    Back to the top

    Powered by Savane 3.13-758e.
    Corresponding source code