Page MenuHome

Windows mmap: expose thread-safe MAM_mmap API (using same lock as MEM_mallocN & co).
AbandonedPublic

Authored by Bastien Montagne (mont29) on Sep 29 2015, 3:30 PM.

Details

Summary

This is needed, since our our-grown mmap for windows is not threadsafe...

Fix T46299: File Browser Crash while listing big font or image folders in preview mode.

Crash happened due to non-thread-safety of mmap under windows (used in IMBuf reading code,
called from threads during filebroser preview generations).

Diff Detail

Repository
rB Blender
Branch
T46299-fix-temp

Event Timeline

Bastien Montagne (mont29) retitled this revision from to Windows mmap: expose thread-safe MAM_mmap API (using same lock as MEM_mallocN & co)..
Bastien Montagne (mont29) updated this object.

Talked with @Sergey Sharybin (sergey) over IRC, we drop the generic solution for now and are just going to protect mmap for windows behind a spinlock in imbuf code…