SuperHouse / esp-open-rtos

Open source FreeRTOS-based ESP8266 software framework
BSD 3-Clause "New" or "Revised" License
1.54k stars 490 forks source link

newlib: add an option to combine some locks. #529

Closed ourairquality closed 6 years ago

ourairquality commented 6 years ago

The locks are using a bit of the limited ram. It's probably fine to combine some of these to use the same mutex, and this patch does so for the set initialized early. The file locks will still be separate, and dynamically created, so a thread blocking on them will not deadlock all uses of newlib that need a lock. See https://github.com/SuperHouse/esp-open-rtos/issues/510#issuecomment-354001234

UncleRus commented 6 years ago

Thank you!

Zaltora commented 6 years ago

Tested, 1k heap more with this patch :)