Skip to content

Commit 600665a

Browse files
committed
Merge branch 'bugfix/esp32s2_o2_op' into 'master'
freertos: fix build error at -O2 optimization level Closes IDFGH-3581 See merge request espressif/esp-idf!9444
2 parents 48b659b + 39bdbd7 commit 600665a

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

components/freertos/tasks.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -645,10 +645,11 @@ static void prvAddNewTaskToReadyList( TCB_t *pxNewTCB, TaskFunction_t pxTaskCode
645645
*/
646646
void taskYIELD_OTHER_CORE( BaseType_t xCoreID, UBaseType_t uxPriority )
647647
{
648-
TCB_t *curTCB = pxCurrentTCB[xCoreID];
648+
TCB_t *curTCB;
649649
BaseType_t i;
650650

651651
if (xCoreID != tskNO_AFFINITY) {
652+
curTCB = pxCurrentTCB[xCoreID];
652653
if ( curTCB->uxPriority < uxPriority ) { // NOLINT(clang-analyzer-core.NullDereference) IDF-685
653654
vPortYieldOtherCore( xCoreID );
654655
}
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
CONFIG_COMPILER_OPTIMIZATION_PERF=y

0 commit comments

Comments
 (0)