SuperHouse / esp-open-rtos

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

Shrink gpio<>iomux maps #671

Closed quietboil closed 5 years ago

quietboil commented 5 years ago

Both maps are in RAM, so there is really no need to allocate extra memory for each entry - no aligned reads.

The assembler for gpio_to_iomux and iomux_to_gpio differs only in how array entry address (offset) is calculated:

ourairquality commented 5 years ago

This might be a problem as an 8 bit access to iram generates a load exception, very slow, and perhaps some code will expected gpio access to be fast. So it might be best to either revert this, or change it to place these in data RAM?

quietboil commented 5 years ago

an 8 bit access to iram generates a load exception

Agree. My fault. I managed to miss the section attribute on those arrays :disappointed:

UncleRus commented 5 years ago

Reverted