Skip to content

Commit 6ff45e7

Browse files
committed
slightly faster to keep IRAM_ATTR for sPC and color_add
1 parent 6aefb65 commit 6ff45e7

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

wled00/FX_fcn.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -938,7 +938,7 @@ static void xyFromBlock(uint16_t &x,uint16_t &y, uint16_t i, uint16_t vW, uint16
938938

939939
}
940940

941-
void WLED_O2_ATTR __attribute__((hot)) Segment::setPixelColor(int i, uint32_t col) //WLEDMM: IRAM_ATTR conditionally
941+
void IRAM_ATTR_YN WLED_O2_ATTR __attribute__((hot)) Segment::setPixelColor(int i, uint32_t col) //WLEDMM: IRAM_ATTR conditionally
942942
{
943943
if (!isActive()) return; // not active
944944
#ifndef WLED_DISABLE_2D

wled00/colors.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ uint32_t WLED_O3_ATTR IRAM_ATTR_YN __attribute__((hot)) color_blend(uint32_t col
4747
* color add function that preserves ratio
4848
* idea: https://github.com/Aircoookie/WLED/pull/2465 by https://github.com/Proto-molecule
4949
*/
50-
uint32_t WLED_O2_ATTR color_add(uint32_t c1, uint32_t c2, bool fast) // WLEDMM added IRAM_ATTR_YN
50+
uint32_t WLED_O2_ATTR IRAM_ATTR_YN color_add(uint32_t c1, uint32_t c2, bool fast) // WLEDMM added IRAM_ATTR_YN
5151
{
5252
if (c2 == 0) return c1; // WLEDMM shortcut
5353
if (c1 == 0) return c2; // WLEDMM shortcut

0 commit comments

Comments
 (0)