Skip to content

memory leak on write? #245

@robtfm

Description

@robtfm

Description

while writing out a large number of images, i find my process memory inflating. writing ~1000 rg32uint textures of sizes with between 512x512 and 2048x2048, i appear to leak around 10gb of ram, eventually crashing with an allocation failure.

using non_parallel helps significantly (leaking around 2gb for the same) but still does leak.

i am using SMALL_FAST_LOSSLESS compression.

Reproducing

removing the Image::write call (and writing random data instead) stops this leak so i am reasonably confident that it is within exr. i tried to reproduce with a simpler example on a single thread but it was rock solid.

my writes are issued from a compute thread pool so i wonder if it is a thread-local issue.

(edit: i replaced with a png encoding and have no memory issues now so i am sure it's somewhere in the exr writing)

Environment

  • Operating System : windows
  • CPU Model (Big Endian or Little Endian?) : lil
  • EXRS Version used : 1.73

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions