Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix timer cancellation to be reliable in LayerImplSelect. #22375

Merged

Conversation

bzbarsky-apple
Copy link
Contributor

To minimize risk, the changes here keep the "grab all the timers we
should fire, then fire them" setup instead of switching to the "fire
the timers one at a time" approach LayerImplFreeRTOS uses.

The fix consists of the following parts:

  1. Store the list of timers to fire in a member, so we can cancel things from
    that list as needed.
  2. To avoid canceling things scheduled by ScheduleWork, remove the CancelTimer
    call in ScheduleWork. This does mean we now allow multiple timers for the
    same callback+appState in the timer list, if they were created by
    ScheduleWork, but that should be OK, since the only reason that pair needs to
    be unique is to allow cancellation and we never want to cancel the things
    ScheduleWork schedules. As a followup we should stop using the timer list
    for ScheduleWork altogether and use ScheduleLambda like LayerImplFreeRTOS
    does, but that involves fixing the unit tests that call ScheduleWork without
    actually running the platfor manager event loop and expect it to work
    somehow.

TestRead was failing the sanity assert for not losing track of timers
to fire, because it was spinning a nested event loop. The changes to
that test stop it from doing that.

Fixes #19387
Fixes #22160

Problem

Timer cancellation sometimes fails, leading to crashes.

Change overview

Fix timer cancellation to be reliable.

Testing

New unit tests added for canceling timers and ScheduleWork not canceling a previous ScheduleWork.

@bzbarsky-apple
Copy link
Contributor Author

It looks like something is going wrong with testSystemLayer on ESP32. Looking into that.

@github-actions
Copy link

github-actions bot commented Sep 3, 2022

PR #22375: Size comparison from ba8a495 to 9dd99b1

Increases (34 builds for bl602, cc13x2_26x2, cyw30739, efr32, esp32, k32w, linux, mbed, nrfconnect, psoc6, qpg, telink)
platform target config section ba8a495 9dd99b1 change % change
bl602 lighting-app bl602 (read/write) 1386174 1386214 40 0.0
.text 1052568 1052608 40 0.0
bl602+rpc (read/write) 1431830 1431870 40 0.0
.text 1084328 1084368 40 0.0
cc13x2_26x2 all-clusters-app LP_CC2652R7 (read only) 675335 675359 24 0.0
.text 585808 585832 24 0.0
all-clusters-minimal-app LP_CC2652R7 (read only) 640047 640071 24 0.0
.text 561360 561384 24 0.0
lock-ftd LP_CC2652R7 (read only) 676403 676419 16 0.0
.text 598856 598872 16 0.0
lock-mtd LP_CC2652R7 (read only) 659355 659379 24 0.0
.text 556552 556576 24 0.0
pump-app LP_CC2652R7 (read only) 685223 685247 24 0.0
.text 594660 594684 24 0.0
pump-controller-app LP_CC2652R7 (read only) 669715 669731 16 0.0
.text 583608 583624 16 0.0
shell LP_CC2652R7 (read only) 665986 666010 24 0.0
.text 579900 579924 24 0.0
cyw30739 light cyw930739m2evb_01 (read/write) 586866 586882 16 0.0
.app_xip_area 463524 463540 16 0.0
lock cyw930739m2evb_01 (read/write) 592610 592634 24 0.0
.app_xip_area 464484 464508 24 0.0
ota-requestor-no-progress-logging cyw930739m2evb_01 (read/write) 599794 599810 16 0.0
.app_xip_area 477172 477188 16 0.0
efr32 lighting-app BRD4161A (read/write) 1108512 1108544 32 0.0
.text 970088 970120 32 0.0
BRD4161A+rpc (read/write) 972156 972188 32 0.0
.text 819040 819072 32 0.0
BRD4161A+rs911x (read/write) 1002228 1002260 32 0.0
.text 830976 831008 32 0.0
lock-app BRD4161A+wf200 (read/write) 1150288 1150304 16 0.0
.text 995948 995964 16 0.0
window-app BRD4161A (read/write) 1099752 1099784 32 0.0
.text 959864 959896 32 0.0
esp32 all-clusters-app c3devkit (read only) 1033886 1033912 26 0.0
.flash.text 1033886 1033912 26 0.0
m5stack (read only) 1086503 1086519 16 0.0
.flash.text 1081119 1081135 16 0.0
k32w light k32w0+release (read/write) 648188 648204 16 0.0
.text 572680 572696 16 0.0
lock k32w0+release (read/write) 705184 705216 32 0.0
.text 629220 629252 32 0.0
linux chip-tool-ipv6only arm64 (read only) 1031920 10319380 176 0.0
(read/write) 705169 705185 16 0.0
.bss 33297 33313 16 0.0
.rodata 499300 499348 48 0.0
.text 8167492 8167620 128 0.0
thermostat-no-ble arm64 (read only) 2362964 2363156 192 0.0
.rodata 141404 141452 48 0.0
.text 1983520 1983664 144 0.0
mbed lock-app CY8CPROTO_062_4343W+release (read/write) 2455184 2455232 48 0.0
.text 1417828 1417876 48 0.0
nrfconnect all-clusters-app nrf52840dk_nrf52840 (read/write) 1181071 1181151 80 0.0
rodata 143504 143552 48 0.0
text 814980 815016 36 0.0
all-clusters-minimal-app nrf52840dk_nrf52840 (read/write) 1160251 1160347 96 0.0
rodata 135092 135140 48 0.0
text 803372 803412 40 0.0
psoc6 all-clusters cy8ckit_062s2_43012 (read/write) 1742732 1742764 32 0.0
.debug_abbrev 1221450 1221471 21 0.0
.debug_info 26715280 26715581 301 0.0
.debug_line 3657380 3657467 87 0.0
.debug_loc 3573063 3573342 279 0.0
.text 1542960 1542992 32 0.0
all-clusters-minimal cy8ckit_062s2_43012 (read/write) 1685932 1685964 32 0.0
.debug_abbrev 1213289 1213310 21 0.0
.debug_info 26451903 26452204 301 0.0
.debug_line 3677896 3677983 87 0.0
.debug_loc 3560700 3560979 279 0.0
.text 1486896 1486928 32 0.0
light cy8ckit_062s2_43012 (read/write) 1603180 1603228 48 0.0
.debug_abbrev 1048108 1048129 21 0.0
.debug_info 21914187 21914487 300 0.0
.debug_line 3248361 3248448 87 0.0
.debug_loc 3259042 3259321 279 0.0
.text 1412376 1412424 48 0.0
lock cy8ckit_062s2_43012 (read/write) 1640876 1640924 48 0.0
.debug_abbrev 1055543 1055564 21 0.0
.debug_info 22293932 22294234 302 0.0
.debug_line 3257182 3257269 87 0.0
.debug_loc 3298895 3299174 279 0.0
.text 1445040 1445088 48 0.0
qpg lighting-app qpg6105+debug (read/write) 1129148 1129164 16 0.0
.text 576244 576260 16 0.0
lock-app qpg6105+debug (read/write) 1100152 1100176 24 0.0
.text 547252 547276 24 0.0
telink light-switch-app tlsr9518adk80d (read/write) 808972 809088 116 0.0
text 571450 571514 64 0.0
lighting-app tlsr9518adk80d (read/write) 830888 831004 116 0.0
text 589574 589638 64 0.0
Decreases (6 builds for cc13x2_26x2)
platform target config section ba8a495 9dd99b1 change % change
cc13x2_26x2 all-clusters-app LP_CC2652R7 (read/write) 176072 176048 -24 -0.0
lock-ftd LP_CC2652R7 (read/write) 165316 165300 -16 -0.0
lock-mtd LP_CC2652R7 (read/write) 178052 178028 -24 -0.0
pump-app LP_CC2652R7 (read/write) 157200 157176 -24 -0.0
pump-controller-app LP_CC2652R7 (read/write) 172820 172804 -16 -0.0
shell LP_CC2652R7 (read/write) 180940 180916 -24 -0.0
Full report (34 builds for bl602, cc13x2_26x2, cyw30739, efr32, esp32, k32w, linux, mbed, nrfconnect, psoc6, qpg, telink)
platform target config section ba8a495 9dd99b1 change % change
bl602 lighting-app bl602 (read/write) 1386174 1386214 40 0.0
.bss 120298 120298 0 0.0
.data 4488 4488 0 0.0
.text 1052568 1052608 40 0.0
bl602+rpc (read/write) 1431830 1431870 40 0.0
.bss 127730 127730 0 0.0
.data 4600 4600 0 0.0
.text 1084328 1084368 40 0.0
cc13x2_26x2 all-clusters-app LP_CC2652R7 (read only) 675335 675359 24 0.0
(read/write) 176072 176048 -24 -0.0
.bss 74300 74300 0 0.0
.data 3380 3380 0 0.0
.rodata 89215 89215 0 0.0
.text 585808 585832 24 0.0
all-clusters-minimal-app LP_CC2652R7 (read only) 640047 640071 24 0.0
(read/write) 157868 157868 0 0.0
.bss 73572 73572 0 0.0
.data 3380 3380 0 0.0
.rodata 78367 78367 0 0.0
.text 561360 561384 24 0.0
lock-ftd LP_CC2652R7 (read only) 676403 676419 16 0.0
(read/write) 165316 165300 -16 -0.0
.bss 71500 71500 0 0.0
.data 3304 3304 0 0.0
.rodata 77067 77067 0 0.0
.text 598856 598872 16 0.0
lock-mtd LP_CC2652R7 (read only) 659355 659379 24 0.0
(read/write) 178052 178028 -24 -0.0
.bss 67188 67188 0 0.0
.data 3304 3304 0 0.0
.rodata 102323 102323 0 0.0
.text 556552 556576 24 0.0
pump-app LP_CC2652R7 (read only) 685223 685247 24 0.0
(read/write) 157200 157176 -24 -0.0
.bss 71436 71436 0 0.0
.data 3296 3296 0 0.0
.rodata 90079 90079 0 0.0
.text 594660 594684 24 0.0
pump-controller-app LP_CC2652R7 (read only) 669715 669731 16 0.0
(read/write) 172820 172804 -16 -0.0
.bss 71548 71548 0 0.0
.data 3292 3292 0 0.0
.rodata 85627 85627 0 0.0
.text 583608 583624 16 0.0
shell LP_CC2652R7 (read only) 665986 666010 24 0.0
(read/write) 180940 180916 -24 -0.0
.bss 76620 76620 0 0.0
.data 3376 3376 0 0.0
.rodata 85770 85770 0 0.0
.text 579900 579924 24 0.0
cyw30739 light cyw930739m2evb_01 (read/write) 586866 586882 16 0.0
.app_xip_area 463524 463540 16 0.0
.bss 65776 65776 0 0.0
.data 744 744 0 0.0
.rodata 0 0 0 0.0
.text 112 112 0 0.0
lock cyw930739m2evb_01 (read/write) 592610 592634 24 0.0
.app_xip_area 464484 464508 24 0.0
.bss 70560 70560 0 0.0
.data 748 748 0 0.0
.rodata 0 0 0 0.0
.text 112 112 0 0.0
ota-requestor-no-progress-logging cyw930739m2evb_01 (read/write) 599794 599810 16 0.0
.app_xip_area 477172 477188 16 0.0
.bss 65088 65088 0 0.0
.data 716 716 0 0.0
.rodata 0 0 0 0.0
.text 112 112 0 0.0
efr32 lighting-app BRD4161A (read/write) 1108512 1108544 32 0.0
.bss 136332 136332 0 0.0
.data 2072 2072 0 0.0
.text 970088 970120 32 0.0
BRD4161A+rpc (read/write) 972156 972188 32 0.0
.bss 150844 150844 0 0.0
.data 2252 2252 0 0.0
.text 819040 819072 32 0.0
BRD4161A+rs911x (read/write) 1002228 1002260 32 0.0
.bss 169168 169168 0 0.0
.data 2064 2064 0 0.0
.text 830976 831008 32 0.0
lock-app BRD4161A+wf200 (read/write) 1150288 1150304 16 0.0
.bss 152248 152248 0 0.0
.data 2072 2072 0 0.0
.text 995948 995964 16 0.0
window-app BRD4161A (read/write) 1099752 1099784 32 0.0
.bss 137772 137772 0 0.0
.data 2096 2096 0 0.0
.text 959864 959896 32 0.0
esp32 all-clusters-app c3devkit (read only) 1033886 1033912 26 0.0
(read/write) 1493646 1493646 0 0.0
.dram0.bss 71120 71120 0 0.0
.dram0.data 13696 13696 0 0.0
.flash.rodata 218160 218160 0 0.0
.flash.text 1033886 1033912 26 0.0
.iram0.text 65204 65204 0 0.0
m5stack (read only) 1086503 1086519 16 0.0
(read/write) 490916 490916 0 0.0
.dram0.bss 76640 76640 0 0.0
.dram0.data 34152 34152 0 0.0
.flash.rodata 247456 247456 0 0.0
.flash.text 1081119 1081135 16 0.0
.iram0.text 123939 123939 0 0.0
k32w light k32w0+release (read/write) 648188 648204 16 0.0
.bss 70712 70712 0 0.0
.data 2068 2068 0 0.0
.text 572680 572696 16 0.0
lock k32w0+release (read/write) 705184 705216 32 0.0
.bss 71160 71160 0 0.0
.data 2076 2076 0 0.0
.text 629220 629252 32 0.0
linux chip-tool-ipv6only arm64 (read only) 1031920 10319380 176 0.0
(read/write) 705169 705185 16 0.0
.bss 33297 33313 16 0.0
.data 3280 3280 0 0.0
.data.rel.ro 649784 649784 0 0.0
.dynamic 560 560 0 0.0
.got 13840 13840 0 0.0
.init 24 24 0 0.0
.init_array 200 200 0 0.0
.rodata 499300 499348 48 0.0
.text 8167492 8167620 128 0.0
thermostat-no-ble arm64 (read only) 2362964 2363156 192 0.0
(read/write) 141857 141857 0 0.0
.bss 55233 55233 0 0.0
.data 1680 1680 0 0.0
.data.rel.ro 76112 76112 0 0.0
.dynamic 560 560 0 0.0
.got 5056 5056 0 0.0
.init 24 24 0 0.0
.init_array 416 416 0 0.0
.rodata 141404 141452 48 0.0
.text 1983520 1983664 144 0.0
mbed lock-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2455184 2455232 48 0.0
.bss 215044 215044 0 0.0
.data 5872 5872 0 0.0
.text 1417828 1417876 48 0.0
nrfconnect all-clusters-app nrf52840dk_nrf52840 (read/write) 1181071 1181151 80 0.0
bss 143641 143641 0 0.0
rodata 143504 143552 48 0.0
text 814980 815016 36 0.0
all-clusters-minimal-app nrf52840dk_nrf52840 (read/write) 1160251 1160347 96 0.0
bss 142868 142868 0 0.0
rodata 135092 135140 48 0.0
text 803372 803412 40 0.0
psoc6 all-clusters cy8ckit_062s2_43012 (read only) 841960 841960 0 0.0
(read/write) 1742732 1742764 32 0.0
.ARM.attributes 46 46 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 188720 188720 0 0.0
.comment 204 204 0 0.0
.copy.table 24 24 0 0.0
.cy_m0p_image 6216 6216 0 0.0
.cy_sharedmem 8 8 0 0.0
.data 2664 2664 0 0.0
.debug_abbrev 1221450 1221471 21 0.0
.debug_aranges 111728 111728 0 0.0
.debug_frame 372964 372964 0 0.0
.debug_info 26715280 26715581 301 0.0
.debug_line 3657380 3657467 87 0.0
.debug_loc 3573063 3573342 279 0.0
.debug_ranges 338424 338424 0 0.0
.debug_str 3427396 3427396 0 0.0
.heap 841960 841960 0 0.0
.noinit 148 148 0 0.0
.ramVectors 736 736 0 0.0
.shstrtab 288 288 0 0.0
.stab 156 156 0 0.0
.stabstr 335 335 0 0.0
.stack_dummy 4096 4096 0 0.0
.strtab 570587 570587 0 0.0
.symtab 421488 421488 0 0.0
.text 1542960 1542992 32 0.0
.zero.table 8 8 0 0.0
text 0 0 0 0.0
all-clusters-minimal cy8ckit_062s2_43012 (read only) 842696 842696 0 0.0
(read/write) 1685932 1685964 32 0.0
.ARM.attributes 46 46 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 187984 187984 0 0.0
.comment 204 204 0 0.0
.copy.table 24 24 0 0.0
.cy_m0p_image 6216 6216 0 0.0
.cy_sharedmem 8 8 0 0.0
.data 2664 2664 0 0.0
.debug_abbrev 1213289 1213310 21 0.0
.debug_aranges 111200 111200 0 0.0
.debug_frame 376044 376044 0 0.0
.debug_info 26451903 26452204 301 0.0
.debug_line 3677896 3677983 87 0.0
.debug_loc 3560700 3560979 279 0.0
.debug_ranges 337040 337040 0 0.0
.debug_str 3416401 3416401 0 0.0
.heap 842696 842696 0 0.0
.noinit 148 148 0 0.0
.ramVectors 736 736 0 0.0
.shstrtab 288 288 0 0.0
.stab 156 156 0 0.0
.stabstr 335 335 0 0.0
.stack_dummy 4096 4096 0 0.0
.strtab 535061 535061 0 0.0
.symtab 408080 408080 0 0.0
.text 1486896 1486928 32 0.0
.zero.table 0 0 0 0.0
8 8 0 0.0
light cy8ckit_062s2_43012 (read only) 850928 850928 0 0.0
(read/write) 1603180 1603228 48 0.0
.ARM.attributes 46 46 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 179960 179960 0 0.0
.comment 204 204 0 0.0
.copy.table 24 24 0 0.0
.cy_m0p_image 6216 6216 0 0.0
.cy_sharedmem 8 8 0 0.0
.data 2456 2456 0 0.0
.debug_abbrev 1048108 1048129 21 0.0
.debug_aranges 103376 103376 0 0.0
.debug_frame 346312 346312 0 0.0
.debug_info 21914187 21914487 300 0.0
.debug_line 3248361 3248448 87 0.0
.debug_loc 3259042 3259321 279 0.0
.debug_ranges 302512 302512 0 0.0
.debug_str 3221667 3221667 0 0.0
.heap 850928 850928 0 0.0
.noinit 148 148 0 0.0
.ramVectors 736 736 0 0.0
.shstrtab 288 288 0 0.0
.stab 156 156 0 0.0
.stabstr 335 335 0 0.0
.stack_dummy 4096 4096 0 0.0
.strtab 468360 468360 0 0.0
.symtab 375168 375168 0 0.0
.text 1412376 1412424 48 0.0
.zero.table 0 0 0 0.0
8 8 0 0.0
lock cy8ckit_062s2_43012 (read only) 845896 845896 0 0.0
(read/write) 1640876 1640924 48 0.0
.ARM.attributes 46 46 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 184976 184976 0 0.0
.comment 204 204 0 0.0
.copy.table 24 24 0 0.0
.cy_m0p_image 6216 6216 0 0.0
.cy_sharedmem 8 8 0 0.0
.data 2472 2472 0 0.0
.debug_abbrev 1055543 1055564 21 0.0
.debug_aranges 104048 104048 0 0.0
.debug_frame 349140 349140 0 0.0
.debug_info 22293932 22294234 302 0.0
.debug_line 3257182 3257269 87 0.0
.debug_loc 3298895 3299174 279 0.0
.debug_ranges 305856 305856 0 0.0
.debug_str 3249088 3249088 0 0.0
.heap 845896 845896 0 0.0
.noinit 148 148 0 0.0
.ramVectors 736 736 0 0.0
.shstrtab 288 288 0 0.0
.stab 156 156 0 0.0
.stabstr 335 335 0 0.0
.stack_dummy 4096 4096 0 0.0
.strtab 474563 474563 0 0.0
.symtab 378352 378352 0 0.0
.text 1445040 1445088 48 0.0
.zero.table 0 0 0 0.0
8 8 0 0.0
qpg lighting-app qpg6105+debug (read/write) 1129148 1129164 16 0.0
.bss 106112 106112 0 0.0
.data 1028 1028 0 0.0
.text 576244 576260 16 0.0
lock-app qpg6105+debug (read/write) 1100152 1100176 24 0.0
.bss 102344 102344 0 0.0
.data 1032 1032 0 0.0
.text 547252 547276 24 0.0
telink light-switch-app tlsr9518adk80d (read/write) 808972 809088 116 0.0
bss 71344 71344 0 0.0
noinit 43488 43488 0 0.0
text 571450 571514 64 0.0
lighting-app tlsr9518adk80d (read/write) 830888 831004 116 0.0
bss 72200 72200 0 0.0
noinit 43488 43488 0 0.0
text 589574 589638 64 0.0

bzbarsky-apple and others added 6 commits September 3, 2022 15:54
…c/system/tests/TestSystemScheduleWork.cpp history.
To minimize risk, the changes here keep the "grab all the timers we
should fire, then fire them" setup instead of switching to the "fire
the timers one at a time" approach LayerImplFreeRTOS uses.

The fix consists of the following parts:

1) Store the list of timers to fire in a member, so we can cancel things from
   that list as needed.
2) To avoid canceling things scheduled by ScheduleWork, remove the CancelTimer
   call in ScheduleWork.  This does mean we now allow multiple timers for the
   same callback+appState in the timer list, if they were created by
   ScheduleWork, but that should be OK, since the only reason that pair needs to
   be unique is to allow cancellation and we never want to cancel the things
   ScheduleWork schedules.  As a followup we should stop using the timer list
   for ScheduleWork altogether and use ScheduleLambda like LayerImplFreeRTOS
   does, but that involves fixing the unit tests that call ScheduleWork without
   actually running the platfor manager event loop and expect it to work
   somehow.

TestRead was failing the sanity assert for not losing track of timers
to fire, because it was spinning a nested event loop.  The changes to
that test stop it from doing that.

Fixes project-chip#19387
Fixes project-chip#22160
@github-actions
Copy link

github-actions bot commented Sep 3, 2022

PR #22375: Size comparison from 05172d2 to 214afe6

Increases (44 builds for bl602, cc13x2_26x2, cyw30739, efr32, esp32, k32w, linux, nrfconnect, psoc6, qpg, telink)
platform target config section 05172d2 214afe6 change % change
bl602 lighting-app bl602 (read/write) 1386174 1386214 40 0.0
.text 1052572 1052608 36 0.0
bl602+rpc (read/write) 1431830 1431870 40 0.0
.text 1084328 1084368 40 0.0
cc13x2_26x2 all-clusters-app LP_CC2652R7 (read only) 675335 675359 24 0.0
.text 585808 585832 24 0.0
all-clusters-minimal-app LP_CC2652R7 (read only) 640047 640071 24 0.0
.text 561360 561384 24 0.0
lock-ftd LP_CC2652R7 (read only) 676403 676419 16 0.0
.text 598856 598872 16 0.0
lock-mtd LP_CC2652R7 (read only) 659355 659379 24 0.0
.text 556552 556576 24 0.0
pump-app LP_CC2652R7 (read only) 685223 685247 24 0.0
.text 594660 594684 24 0.0
pump-controller-app LP_CC2652R7 (read only) 669707 669731 24 0.0
.text 583600 583624 24 0.0
shell LP_CC2652R7 (read only) 665986 666010 24 0.0
.text 579900 579924 24 0.0
cyw30739 light cyw930739m2evb_01 (read/write) 586866 586882 16 0.0
.app_xip_area 463524 463540 16 0.0
lock cyw930739m2evb_01 (read/write) 592610 592634 24 0.0
.app_xip_area 464484 464508 24 0.0
ota-requestor-no-progress-logging cyw930739m2evb_01 (read/write) 599794 599810 16 0.0
.app_xip_area 477172 477188 16 0.0
efr32 lighting-app BRD4161A (read/write) 1108512 1108544 32 0.0
.text 970088 970120 32 0.0
BRD4161A+rpc (read/write) 972156 972188 32 0.0
.text 819040 819072 32 0.0
BRD4161A+rs911x (read/write) 1002228 1002260 32 0.0
.text 830976 831008 32 0.0
lock-app BRD4161A+wf200 (read/write) 1150288 1150304 16 0.0
.text 995948 995964 16 0.0
window-app BRD4161A (read/write) 1099752 1099784 32 0.0
.text 959864 959896 32 0.0
esp32 all-clusters-app c3devkit (read only) 1033882 1033914 32 0.0
.flash.text 1033882 1033914 32 0.0
m5stack (read only) 1086503 1086519 16 0.0
.flash.text 1081119 1081135 16 0.0
k32w light k32w0+release (read/write) 648188 648204 16 0.0
.text 572680 572696 16 0.0
lock k32w0+release (read/write) 705184 705216 32 0.0
.text 629220 629252 32 0.0
linux all-clusters-app debug (read only) 3045065 3045257 192 0.0
(read/write) 156032 156064 32 0.0
.bss 61792 61824 32 0.1
.rodata 275435 275499 64 0.0
.text 2590194 2590322 128 0.0
all-clusters-minimal-app debug (read only) 2880865 2881041 176 0.0
(read/write) 147632 147664 32 0.0
.bss 61024 61056 32 0.1
.rodata 275595 275659 64 0.0
.text 2428610 2428722 112 0.0
bridge-app debug+rpc (read only) 2378665 2378841 176 0.0
.rodata 204296 204360 64 0.0
.text 2011458 2011570 112 0.0
chip-tool debug (read only) 10944361 10944537 176 0.0
(read/write) 657320 657352 32 0.0
.bss 25240 25272 32 0.1
.rodata 569045 569109 64 0.0
.text 8854500 8854612 112 0.0
chip-tool-ipv6only arm64 (read only) 1031920 10319380 176 0.0
(read/write) 705169 705185 16 0.0
.bss 33297 33313 16 0.0
.rodata 499300 499348 48 0.0
.text 8167492 8167620 128 0.0
lighting-app debug+rpc (read only) 2604057 2604249 192 0.0
.rodata 221104 221168 64 0.0
.text 2211762 2211890 128 0.0
lock-app debug (read only) 2587073 2587249 176 0.0
.rodata 238128 238192 64 0.0
.text 2182002 2182114 112 0.0
ota-provider-app debug (read only) 2364313 2364505 192 0.0
.rodata 210104 210168 64 0.0
.text 1990450 1990578 128 0.0
ota-requestor-app debug (read only) 2529561 2529753 192 0.0
.rodata 216832 216896 64 0.0
.text 2139826 2139954 128 0.0
shell debug (read only) 2613369 2613545 176 0.0
.rodata 235538 235602 64 0.0
.text 2219122 2219234 112 0.0
thermostat-no-ble arm64 (read only) 2362964 2363156 192 0.0
.rodata 141404 141452 48 0.0
.text 1983520 1983664 144 0.0
tv-app debug (read only) 3191545 3191721 176 0.0
.rodata 260104 260168 64 0.0
.text 2741410 2741522 112 0.0
tv-casting-app debug (read only) 5509873 5510017 144 0.0
.rodata 345073 345105 32 0.0
.text 4892898 4893010 112 0.0
nrfconnect all-clusters-app nrf52840dk_nrf52840 (read/write) 1181071 1181151 80 0.0
rodata 143504 143552 48 0.0
text 814980 815020 40 0.0
all-clusters-minimal-app nrf52840dk_nrf52840 (read/write) 1160251 1160347 96 0.0
rodata 135092 135140 48 0.0
text 803372 803412 40 0.0
psoc6 all-clusters cy8ckit_062s2_43012 (read/write) 1742732 1742764 32 0.0
.debug_abbrev 1221450 1221471 21 0.0
.debug_info 26715281 26715581 300 0.0
.debug_line 3657380 3657467 87 0.0
.debug_loc 3573063 3573342 279 0.0
.text 1542960 1542992 32 0.0
all-clusters-minimal cy8ckit_062s2_43012 (read/write) 1685932 1685964 32 0.0
.debug_abbrev 1213289 1213310 21 0.0
.debug_info 26451903 26452205 302 0.0
.debug_line 3677896 3677983 87 0.0
.debug_loc 3560700 3560979 279 0.0
.text 1486896 1486928 32 0.0
light cy8ckit_062s2_43012 (read/write) 1603180 1603228 48 0.0
.debug_abbrev 1048108 1048129 21 0.0
.debug_info 21914186 21914488 302 0.0
.debug_line 3248361 3248448 87 0.0
.debug_loc 3259042 3259321 279 0.0
.text 1412376 1412424 48 0.0
lock cy8ckit_062s2_43012 (read/write) 1640876 1640924 48 0.0
.debug_abbrev 1055543 1055564 21 0.0
.debug_info 22293934 22294233 299 0.0
.debug_line 3257182 3257269 87 0.0
.debug_loc 3298895 3299174 279 0.0
.text 1445040 1445088 48 0.0
qpg lighting-app qpg6105+debug (read/write) 1129148 1129164 16 0.0
.text 576244 576260 16 0.0
lock-app qpg6105+debug (read/write) 1100160 1100168 8 0.0
.text 547260 547268 8 0.0
telink light-switch-app tlsr9518adk80d (read/write) 808972 809088 116 0.0
text 571452 571516 64 0.0
lighting-app tlsr9518adk80d (read/write) 830888 831004 116 0.0
text 589576 589638 62 0.0
Decreases (6 builds for cc13x2_26x2)
platform target config section 05172d2 214afe6 change % change
cc13x2_26x2 all-clusters-app LP_CC2652R7 (read/write) 176072 176048 -24 -0.0
lock-ftd LP_CC2652R7 (read/write) 165316 165300 -16 -0.0
lock-mtd LP_CC2652R7 (read/write) 178052 178028 -24 -0.0
pump-app LP_CC2652R7 (read/write) 157200 157176 -24 -0.0
pump-controller-app LP_CC2652R7 (read/write) 172828 172804 -24 -0.0
shell LP_CC2652R7 (read/write) 180940 180916 -24 -0.0
Full report (44 builds for bl602, cc13x2_26x2, cyw30739, efr32, esp32, k32w, linux, nrfconnect, psoc6, qpg, telink)
platform target config section 05172d2 214afe6 change % change
bl602 lighting-app bl602 (read/write) 1386174 1386214 40 0.0
.bss 120298 120298 0 0.0
.data 4488 4488 0 0.0
.text 1052572 1052608 36 0.0
bl602+rpc (read/write) 1431830 1431870 40 0.0
.bss 127730 127730 0 0.0
.data 4600 4600 0 0.0
.text 1084328 1084368 40 0.0
cc13x2_26x2 all-clusters-app LP_CC2652R7 (read only) 675335 675359 24 0.0
(read/write) 176072 176048 -24 -0.0
.bss 74300 74300 0 0.0
.data 3380 3380 0 0.0
.rodata 89215 89215 0 0.0
.text 585808 585832 24 0.0
all-clusters-minimal-app LP_CC2652R7 (read only) 640047 640071 24 0.0
(read/write) 157868 157868 0 0.0
.bss 73572 73572 0 0.0
.data 3380 3380 0 0.0
.rodata 78367 78367 0 0.0
.text 561360 561384 24 0.0
lock-ftd LP_CC2652R7 (read only) 676403 676419 16 0.0
(read/write) 165316 165300 -16 -0.0
.bss 71500 71500 0 0.0
.data 3304 3304 0 0.0
.rodata 77067 77067 0 0.0
.text 598856 598872 16 0.0
lock-mtd LP_CC2652R7 (read only) 659355 659379 24 0.0
(read/write) 178052 178028 -24 -0.0
.bss 67188 67188 0 0.0
.data 3304 3304 0 0.0
.rodata 102323 102323 0 0.0
.text 556552 556576 24 0.0
pump-app LP_CC2652R7 (read only) 685223 685247 24 0.0
(read/write) 157200 157176 -24 -0.0
.bss 71436 71436 0 0.0
.data 3296 3296 0 0.0
.rodata 90079 90079 0 0.0
.text 594660 594684 24 0.0
pump-controller-app LP_CC2652R7 (read only) 669707 669731 24 0.0
(read/write) 172828 172804 -24 -0.0
.bss 71548 71548 0 0.0
.data 3292 3292 0 0.0
.rodata 85627 85627 0 0.0
.text 583600 583624 24 0.0
shell LP_CC2652R7 (read only) 665986 666010 24 0.0
(read/write) 180940 180916 -24 -0.0
.bss 76620 76620 0 0.0
.data 3376 3376 0 0.0
.rodata 85770 85770 0 0.0
.text 579900 579924 24 0.0
cyw30739 light cyw930739m2evb_01 (read/write) 586866 586882 16 0.0
.app_xip_area 463524 463540 16 0.0
.bss 65776 65776 0 0.0
.data 744 744 0 0.0
.rodata 0 0 0 0.0
.text 112 112 0 0.0
lock cyw930739m2evb_01 (read/write) 592610 592634 24 0.0
.app_xip_area 464484 464508 24 0.0
.bss 70560 70560 0 0.0
.data 748 748 0 0.0
.rodata 0 0 0 0.0
.text 112 112 0 0.0
ota-requestor-no-progress-logging cyw930739m2evb_01 (read/write) 599794 599810 16 0.0
.app_xip_area 477172 477188 16 0.0
.bss 65088 65088 0 0.0
.data 716 716 0 0.0
.rodata 0 0 0 0.0
.text 112 112 0 0.0
efr32 lighting-app BRD4161A (read/write) 1108512 1108544 32 0.0
.bss 136332 136332 0 0.0
.data 2072 2072 0 0.0
.text 970088 970120 32 0.0
BRD4161A+rpc (read/write) 972156 972188 32 0.0
.bss 150844 150844 0 0.0
.data 2252 2252 0 0.0
.text 819040 819072 32 0.0
BRD4161A+rs911x (read/write) 1002228 1002260 32 0.0
.bss 169168 169168 0 0.0
.data 2064 2064 0 0.0
.text 830976 831008 32 0.0
lock-app BRD4161A+wf200 (read/write) 1150288 1150304 16 0.0
.bss 152248 152248 0 0.0
.data 2072 2072 0 0.0
.text 995948 995964 16 0.0
window-app BRD4161A (read/write) 1099752 1099784 32 0.0
.bss 137772 137772 0 0.0
.data 2096 2096 0 0.0
.text 959864 959896 32 0.0
esp32 all-clusters-app c3devkit (read only) 1033882 1033914 32 0.0
(read/write) 1493646 1493646 0 0.0
.dram0.bss 71120 71120 0 0.0
.dram0.data 13696 13696 0 0.0
.flash.rodata 218160 218160 0 0.0
.flash.text 1033882 1033914 32 0.0
.iram0.text 65204 65204 0 0.0
m5stack (read only) 1086503 1086519 16 0.0
(read/write) 490924 490924 0 0.0
.dram0.bss 76640 76640 0 0.0
.dram0.data 34152 34152 0 0.0
.flash.rodata 247464 247464 0 0.0
.flash.text 1081119 1081135 16 0.0
.iram0.text 123939 123939 0 0.0
k32w light k32w0+release (read/write) 648188 648204 16 0.0
.bss 70712 70712 0 0.0
.data 2068 2068 0 0.0
.text 572680 572696 16 0.0
lock k32w0+release (read/write) 705184 705216 32 0.0
.bss 71160 71160 0 0.0
.data 2076 2076 0 0.0
.text 629220 629252 32 0.0
linux all-clusters-app debug (read only) 3045065 3045257 192 0.0
(read/write) 156032 156064 32 0.0
.bss 61792 61824 32 0.1
.data 2096 2096 0 0.0
.data.rel.ro 85768 85768 0 0.0
.dynamic 608 608 0 0.0
.got 4568 4568 0 0.0
.init 27 27 0 0.0
.init_array 1176 1176 0 0.0
.rodata 275435 275499 64 0.0
.text 2590194 2590322 128 0.0
all-clusters-minimal-app debug (read only) 2880865 2881041 176 0.0
(read/write) 147632 147664 32 0.0
.bss 61024 61056 32 0.1
.data 2064 2064 0 0.0
.data.rel.ro 78264 78264 0 0.0
.dynamic 608 608 0 0.0
.got 4488 4488 0 0.0
.init 27 27 0 0.0
.init_array 1160 1160 0 0.0
.rodata 275595 275659 64 0.0
.text 2428610 2428722 112 0.0
bridge-app debug+rpc (read only) 2378665 2378841 176 0.0
(read/write) 127752 127752 0 0.0
.bss 50656 50656 0 0.0
.data 3600 3600 0 0.0
.data.rel.ro 67640 67640 0 0.0
.dynamic 608 608 0 0.0
.got 4392 4392 0 0.0
.init 27 27 0 0.0
.init_array 832 832 0 0.0
.rodata 204296 204360 64 0.0
.text 2011458 2011570 112 0.0
chip-tool debug (read only) 10944361 10944537 176 0.0
(read/write) 657320 657352 32 0.0
.bss 25240 25272 32 0.1
.data 3266 3266 0 0.0
.data.rel.ro 622288 622288 0 0.0
.dynamic 608 608 0 0.0
.got 5096 5096 0 0.0
.init 27 27 0 0.0
.init_array 776 776 0 0.0
.rodata 569045 569109 64 0.0
.text 8854500 8854612 112 0.0
chip-tool-ipv6only arm64 (read only) 1031920 10319380 176 0.0
(read/write) 705169 705185 16 0.0
.bss 33297 33313 16 0.0
.data 3280 3280 0 0.0
.data.rel.ro 649784 649784 0 0.0
.dynamic 560 560 0 0.0
.got 13840 13840 0 0.0
.init 24 24 0 0.0
.init_array 200 200 0 0.0
.rodata 499300 499348 48 0.0
.text 8167492 8167620 128 0.0
lighting-app debug+rpc (read only) 2604057 2604249 192 0.0
(read/write) 130536 130536 0 0.0
.bss 49792 49792 0 0.0
.data 2096 2096 0 0.0
.data.rel.ro 72680 72680 0 0.0
.dynamic 608 608 0 0.0
.got 4392 4392 0 0.0
.init 27 27 0 0.0
.init_array 928 928 0 0.0
.rodata 221104 221168 64 0.0
.text 2211762 2211890 128 0.0
lock-app debug (read only) 2587073 2587249 176 0.0
(read/write) 125712 125712 0 0.0
.bss 48288 48288 0 0.0
.data 1712 1712 0 0.0
.data.rel.ro 69688 69688 0 0.0
.dynamic 608 608 0 0.0
.got 4464 4464 0 0.0
.init 27 27 0 0.0
.init_array 904 904 0 0.0
.rodata 238128 238192 64 0.0
.text 2182002 2182114 112 0.0
ota-provider-app debug (read only) 2364313 2364505 192 0.0
(read/write) 119144 119144 0 0.0
.bss 47808 47808 0 0.0
.data 1936 1936 0 0.0
.data.rel.ro 63512 63512 0 0.0
.dynamic 608 608 0 0.0
.got 4488 4488 0 0.0
.init 27 27 0 0.0
.init_array 768 768 0 0.0
.rodata 210104 210168 64 0.0
.text 1990450 1990578 128 0.0
ota-requestor-app debug (read only) 2529561 2529753 192 0.0
(read/write) 127552 127552 0 0.0
.bss 50368 50368 0 0.0
.data 2304 2304 0 0.0
.data.rel.ro 68920 68920 0 0.0
.dynamic 608 608 0 0.0
.got 4480 4480 0 0.0
.init 27 27 0 0.0
.init_array 856 856 0 0.0
.rodata 216832 216896 64 0.0
.text 2139826 2139954 128 0.0
shell debug (read only) 2613369 2613545 176 0.0
(read/write) 142184 142184 0 0.0
.bss 57704 57704 0 0.0
.data 1264 1264 0 0.0
.data.rel.ro 77376 77376 0 0.0
.dynamic 608 608 0 0.0
.got 4136 4136 0 0.0
.init 27 27 0 0.0
.init_array 1048 1048 0 0.0
.rodata 235538 235602 64 0.0
.text 2219122 2219234 112 0.0
thermostat-no-ble arm64 (read only) 2362964 2363156 192 0.0
(read/write) 141857 141857 0 0.0
.bss 55233 55233 0 0.0
.data 1680 1680 0 0.0
.data.rel.ro 76112 76112 0 0.0
.dynamic 560 560 0 0.0
.got 5056 5056 0 0.0
.init 24 24 0 0.0
.init_array 416 416 0 0.0
.rodata 141404 141452 48 0.0
.text 1983520 1983664 144 0.0
tv-app debug (read only) 3191545 3191721 176 0.0
(read/write) 258040 258040 0 0.0
.bss 167352 167352 0 0.0
.data 4752 4752 0 0.0
.data.rel.ro 79368 79368 0 0.0
.dynamic 608 608 0 0.0
.got 4856 4856 0 0.0
.init 27 27 0 0.0
.init_array 1080 1080 0 0.0
.rodata 260104 260168 64 0.0
.text 2741410 2741522 112 0.0
tv-casting-app debug (read only) 5509873 5510017 144 0.0
(read/write) 160536 160536 0 0.0
.bss 51352 51352 0 0.0
.data 2432 2432 0 0.0
.data.rel.ro 100304 100304 0 0.0
.dynamic 608 608 0 0.0
.got 4776 4776 0 0.0
.init 27 27 0 0.0
.init_array 1048 1048 0 0.0
.rodata 345073 345105 32 0.0
.text 4892898 4893010 112 0.0
nrfconnect all-clusters-app nrf52840dk_nrf52840 (read/write) 1181071 1181151 80 0.0
bss 143641 143641 0 0.0
rodata 143504 143552 48 0.0
text 814980 815020 40 0.0
all-clusters-minimal-app nrf52840dk_nrf52840 (read/write) 1160251 1160347 96 0.0
bss 142868 142868 0 0.0
rodata 135092 135140 48 0.0
text 803372 803412 40 0.0
psoc6 all-clusters cy8ckit_062s2_43012 (read only) 841960 841960 0 0.0
(read/write) 1742732 1742764 32 0.0
.ARM.attributes 46 46 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 188720 188720 0 0.0
.comment 204 204 0 0.0
.copy.table 24 24 0 0.0
.cy_m0p_image 6216 6216 0 0.0
.cy_sharedmem 8 8 0 0.0
.data 2664 2664 0 0.0
.debug_abbrev 1221450 1221471 21 0.0
.debug_aranges 111728 111728 0 0.0
.debug_frame 372964 372964 0 0.0
.debug_info 26715281 26715581 300 0.0
.debug_line 3657380 3657467 87 0.0
.debug_loc 3573063 3573342 279 0.0
.debug_ranges 338424 338424 0 0.0
.debug_str 3427396 3427396 0 0.0
.heap 841960 841960 0 0.0
.noinit 148 148 0 0.0
.ramVectors 736 736 0 0.0
.shstrtab 288 288 0 0.0
.stab 156 156 0 0.0
.stabstr 335 335 0 0.0
.stack_dummy 4096 4096 0 0.0
.strtab 570587 570587 0 0.0
.symtab 421488 421488 0 0.0
.text 1542960 1542992 32 0.0
.zero.table 8 8 0 0.0
text 0 0 0 0.0
all-clusters-minimal cy8ckit_062s2_43012 (read only) 842696 842696 0 0.0
(read/write) 1685932 1685964 32 0.0
.ARM.attributes 46 46 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 187984 187984 0 0.0
.comment 204 204 0 0.0
.copy.table 24 24 0 0.0
.cy_m0p_image 6216 6216 0 0.0
.cy_sharedmem 8 8 0 0.0
.data 2664 2664 0 0.0
.debug_abbrev 1213289 1213310 21 0.0
.debug_aranges 111200 111200 0 0.0
.debug_frame 376044 376044 0 0.0
.debug_info 26451903 26452205 302 0.0
.debug_line 3677896 3677983 87 0.0
.debug_loc 3560700 3560979 279 0.0
.debug_ranges 337040 337040 0 0.0
.debug_str 3416401 3416401 0 0.0
.heap 842696 842696 0 0.0
.noinit 148 148 0 0.0
.ramVectors 736 736 0 0.0
.shstrtab 288 288 0 0.0
.stab 156 156 0 0.0
.stabstr 335 335 0 0.0
.stack_dummy 4096 4096 0 0.0
.strtab 535061 535061 0 0.0
.symtab 408080 408080 0 0.0
.text 1486896 1486928 32 0.0
.zero.table 0 0 0 0.0
8 8 0 0.0
light cy8ckit_062s2_43012 (read only) 850928 850928 0 0.0
(read/write) 1603180 1603228 48 0.0
.ARM.attributes 46 46 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 179960 179960 0 0.0
.comment 204 204 0 0.0
.copy.table 24 24 0 0.0
.cy_m0p_image 6216 6216 0 0.0
.cy_sharedmem 8 8 0 0.0
.data 2456 2456 0 0.0
.debug_abbrev 1048108 1048129 21 0.0
.debug_aranges 103376 103376 0 0.0
.debug_frame 346312 346312 0 0.0
.debug_info 21914186 21914488 302 0.0
.debug_line 3248361 3248448 87 0.0
.debug_loc 3259042 3259321 279 0.0
.debug_ranges 302512 302512 0 0.0
.debug_str 3221667 3221667 0 0.0
.heap 850928 850928 0 0.0
.noinit 148 148 0 0.0
.ramVectors 736 736 0 0.0
.shstrtab 288 288 0 0.0
.stab 156 156 0 0.0
.stabstr 335 335 0 0.0
.stack_dummy 4096 4096 0 0.0
.strtab 468360 468360 0 0.0
.symtab 375168 375168 0 0.0
.text 1412376 1412424 48 0.0
.zero.table 0 0 0 0.0
8 8 0 0.0
lock cy8ckit_062s2_43012 (read only) 845896 845896 0 0.0
(read/write) 1640876 1640924 48 0.0
.ARM.attributes 46 46 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 184976 184976 0 0.0
.comment 204 204 0 0.0
.copy.table 24 24 0 0.0
.cy_m0p_image 6216 6216 0 0.0
.cy_sharedmem 8 8 0 0.0
.data 2472 2472 0 0.0
.debug_abbrev 1055543 1055564 21 0.0
.debug_aranges 104048 104048 0 0.0
.debug_frame 349140 349140 0 0.0
.debug_info 22293934 22294233 299 0.0
.debug_line 3257182 3257269 87 0.0
.debug_loc 3298895 3299174 279 0.0
.debug_ranges 305856 305856 0 0.0
.debug_str 3249088 3249088 0 0.0
.heap 845896 845896 0 0.0
.noinit 148 148 0 0.0
.ramVectors 736 736 0 0.0
.shstrtab 288 288 0 0.0
.stab 156 156 0 0.0
.stabstr 335 335 0 0.0
.stack_dummy 4096 4096 0 0.0
.strtab 474563 474563 0 0.0
.symtab 378352 378352 0 0.0
.text 1445040 1445088 48 0.0
.zero.table 0 0 0 0.0
8 8 0 0.0
qpg lighting-app qpg6105+debug (read/write) 1129148 1129164 16 0.0
.bss 106112 106112 0 0.0
.data 1028 1028 0 0.0
.text 576244 576260 16 0.0
lock-app qpg6105+debug (read/write) 1100160 1100168 8 0.0
.bss 102344 102344 0 0.0
.data 1032 1032 0 0.0
.text 547260 547268 8 0.0
telink light-switch-app tlsr9518adk80d (read/write) 808972 809088 116 0.0
bss 71344 71344 0 0.0
noinit 43488 43488 0 0.0
text 571452 571516 64 0.0
lighting-app tlsr9518adk80d (read/write) 830888 831004 116 0.0
bss 72200 72200 0 0.0
noinit 43488 43488 0 0.0
text 589576 589638 62 0.0

The fake platform's event loop does not actually process the SystemLayer events.
@github-actions
Copy link

github-actions bot commented Sep 4, 2022

PR #22375: Size comparison from 05172d2 to 1a864c7

Increases (34 builds for bl602, cc13x2_26x2, cyw30739, efr32, esp32, k32w, linux, mbed, nrfconnect, psoc6, qpg, telink)
platform target config section 05172d2 1a864c7 change % change
bl602 lighting-app bl602 (read/write) 1386174 1386214 40 0.0
.text 1052572 1052608 36 0.0
bl602+rpc (read/write) 1431830 1431862 32 0.0
.text 1084328 1084364 36 0.0
cc13x2_26x2 all-clusters-app LP_CC2652R7 (read only) 675335 675359 24 0.0
.text 585808 585832 24 0.0
all-clusters-minimal-app LP_CC2652R7 (read only) 640047 640071 24 0.0
.text 561360 561384 24 0.0
lock-ftd LP_CC2652R7 (read only) 676403 676419 16 0.0
.text 598856 598872 16 0.0
lock-mtd LP_CC2652R7 (read only) 659355 659379 24 0.0
.text 556552 556576 24 0.0
pump-app LP_CC2652R7 (read only) 685223 685247 24 0.0
.text 594660 594684 24 0.0
pump-controller-app LP_CC2652R7 (read only) 669707 669731 24 0.0
.text 583600 583624 24 0.0
shell LP_CC2652R7 (read only) 665986 666010 24 0.0
.text 579900 579924 24 0.0
cyw30739 light cyw930739m2evb_01 (read/write) 586866 586882 16 0.0
.app_xip_area 463524 463540 16 0.0
lock cyw930739m2evb_01 (read/write) 592610 592634 24 0.0
.app_xip_area 464484 464508 24 0.0
ota-requestor-no-progress-logging cyw930739m2evb_01 (read/write) 599794 599810 16 0.0
.app_xip_area 477172 477188 16 0.0
efr32 lighting-app BRD4161A (read/write) 1108512 1108544 32 0.0
.text 970088 970120 32 0.0
BRD4161A+rpc (read/write) 972156 972188 32 0.0
.text 819040 819072 32 0.0
BRD4161A+rs911x (read/write) 1002228 1002260 32 0.0
.text 830976 831008 32 0.0
lock-app BRD4161A+wf200 (read/write) 1150288 1150304 16 0.0
.text 995948 995964 16 0.0
window-app BRD4161A (read/write) 1099752 1099784 32 0.0
.text 959864 959896 32 0.0
esp32 all-clusters-app c3devkit (read only) 1033882 1033912 30 0.0
.flash.text 1033882 1033912 30 0.0
m5stack (read only) 1086503 1086519 16 0.0
.flash.text 1081119 1081135 16 0.0
k32w light k32w0+release (read/write) 648188 648204 16 0.0
.text 572680 572696 16 0.0
lock k32w0+release (read/write) 705184 705200 16 0.0
.text 629220 629236 16 0.0
linux chip-tool-ipv6only arm64 (read only) 1031920 10319380 176 0.0
(read/write) 705169 705185 16 0.0
.bss 33297 33313 16 0.0
.rodata 499300 499348 48 0.0
.text 8167492 8167620 128 0.0
thermostat-no-ble arm64 (read only) 2362964 2363156 192 0.0
.rodata 141404 141452 48 0.0
.text 1983520 1983664 144 0.0
mbed lock-app CY8CPROTO_062_4343W+release (read/write) 2455184 2455232 48 0.0
.text 1417828 1417876 48 0.0
nrfconnect all-clusters-app nrf52840dk_nrf52840 (read/write) 1181071 1181151 80 0.0
rodata 143504 143552 48 0.0
text 814980 815016 36 0.0
all-clusters-minimal-app nrf52840dk_nrf52840 (read/write) 1160251 1160347 96 0.0
rodata 135092 135140 48 0.0
text 803372 803412 40 0.0
psoc6 all-clusters cy8ckit_062s2_43012 (read/write) 1742732 1742764 32 0.0
.debug_abbrev 1221450 1221471 21 0.0
.debug_info 26715281 26715582 301 0.0
.debug_line 3657380 3657467 87 0.0
.debug_loc 3573063 3573342 279 0.0
.text 1542960 1542992 32 0.0
all-clusters-minimal cy8ckit_062s2_43012 (read/write) 1685932 1685964 32 0.0
.debug_abbrev 1213289 1213310 21 0.0
.debug_info 26451903 26452204 301 0.0
.debug_line 3677896 3677983 87 0.0
.debug_loc 3560700 3560979 279 0.0
.text 1486896 1486928 32 0.0
light cy8ckit_062s2_43012 (read/write) 1603180 1603228 48 0.0
.debug_abbrev 1048108 1048129 21 0.0
.debug_info 21914186 21914487 301 0.0
.debug_line 3248361 3248448 87 0.0
.debug_loc 3259042 3259321 279 0.0
.text 1412376 1412424 48 0.0
lock cy8ckit_062s2_43012 (read/write) 1640876 1640924 48 0.0
.debug_abbrev 1055543 1055564 21 0.0
.debug_info 22293934 22294233 299 0.0
.debug_line 3257182 3257269 87 0.0
.debug_loc 3298895 3299174 279 0.0
.text 1445040 1445088 48 0.0
qpg lighting-app qpg6105+debug (read/write) 1129148 1129164 16 0.0
.text 576244 576260 16 0.0
lock-app qpg6105+debug (read/write) 1100160 1100176 16 0.0
.text 547260 547276 16 0.0
telink light-switch-app tlsr9518adk80d (read/write) 808972 809088 116 0.0
text 571452 571514 62 0.0
lighting-app tlsr9518adk80d (read/write) 830888 831004 116 0.0
text 589576 589640 64 0.0
Decreases (7 builds for cc13x2_26x2, esp32)
platform target config section 05172d2 1a864c7 change % change
cc13x2_26x2 all-clusters-app LP_CC2652R7 (read/write) 176072 176048 -24 -0.0
lock-ftd LP_CC2652R7 (read/write) 165316 165300 -16 -0.0
lock-mtd LP_CC2652R7 (read/write) 178052 178028 -24 -0.0
pump-app LP_CC2652R7 (read/write) 157200 157176 -24 -0.0
pump-controller-app LP_CC2652R7 (read/write) 172828 172804 -24 -0.0
shell LP_CC2652R7 (read/write) 180940 180916 -24 -0.0
esp32 all-clusters-app m5stack (read/write) 490924 490916 -8 -0.0
.flash.rodata 247464 247456 -8 -0.0
Full report (34 builds for bl602, cc13x2_26x2, cyw30739, efr32, esp32, k32w, linux, mbed, nrfconnect, psoc6, qpg, telink)
platform target config section 05172d2 1a864c7 change % change
bl602 lighting-app bl602 (read/write) 1386174 1386214 40 0.0
.bss 120298 120298 0 0.0
.data 4488 4488 0 0.0
.text 1052572 1052608 36 0.0
bl602+rpc (read/write) 1431830 1431862 32 0.0
.bss 127730 127730 0 0.0
.data 4600 4600 0 0.0
.text 1084328 1084364 36 0.0
cc13x2_26x2 all-clusters-app LP_CC2652R7 (read only) 675335 675359 24 0.0
(read/write) 176072 176048 -24 -0.0
.bss 74300 74300 0 0.0
.data 3380 3380 0 0.0
.rodata 89215 89215 0 0.0
.text 585808 585832 24 0.0
all-clusters-minimal-app LP_CC2652R7 (read only) 640047 640071 24 0.0
(read/write) 157868 157868 0 0.0
.bss 73572 73572 0 0.0
.data 3380 3380 0 0.0
.rodata 78367 78367 0 0.0
.text 561360 561384 24 0.0
lock-ftd LP_CC2652R7 (read only) 676403 676419 16 0.0
(read/write) 165316 165300 -16 -0.0
.bss 71500 71500 0 0.0
.data 3304 3304 0 0.0
.rodata 77067 77067 0 0.0
.text 598856 598872 16 0.0
lock-mtd LP_CC2652R7 (read only) 659355 659379 24 0.0
(read/write) 178052 178028 -24 -0.0
.bss 67188 67188 0 0.0
.data 3304 3304 0 0.0
.rodata 102323 102323 0 0.0
.text 556552 556576 24 0.0
pump-app LP_CC2652R7 (read only) 685223 685247 24 0.0
(read/write) 157200 157176 -24 -0.0
.bss 71436 71436 0 0.0
.data 3296 3296 0 0.0
.rodata 90079 90079 0 0.0
.text 594660 594684 24 0.0
pump-controller-app LP_CC2652R7 (read only) 669707 669731 24 0.0
(read/write) 172828 172804 -24 -0.0
.bss 71548 71548 0 0.0
.data 3292 3292 0 0.0
.rodata 85627 85627 0 0.0
.text 583600 583624 24 0.0
shell LP_CC2652R7 (read only) 665986 666010 24 0.0
(read/write) 180940 180916 -24 -0.0
.bss 76620 76620 0 0.0
.data 3376 3376 0 0.0
.rodata 85770 85770 0 0.0
.text 579900 579924 24 0.0
cyw30739 light cyw930739m2evb_01 (read/write) 586866 586882 16 0.0
.app_xip_area 463524 463540 16 0.0
.bss 65776 65776 0 0.0
.data 744 744 0 0.0
.rodata 0 0 0 0.0
.text 112 112 0 0.0
lock cyw930739m2evb_01 (read/write) 592610 592634 24 0.0
.app_xip_area 464484 464508 24 0.0
.bss 70560 70560 0 0.0
.data 748 748 0 0.0
.rodata 0 0 0 0.0
.text 112 112 0 0.0
ota-requestor-no-progress-logging cyw930739m2evb_01 (read/write) 599794 599810 16 0.0
.app_xip_area 477172 477188 16 0.0
.bss 65088 65088 0 0.0
.data 716 716 0 0.0
.rodata 0 0 0 0.0
.text 112 112 0 0.0
efr32 lighting-app BRD4161A (read/write) 1108512 1108544 32 0.0
.bss 136332 136332 0 0.0
.data 2072 2072 0 0.0
.text 970088 970120 32 0.0
BRD4161A+rpc (read/write) 972156 972188 32 0.0
.bss 150844 150844 0 0.0
.data 2252 2252 0 0.0
.text 819040 819072 32 0.0
BRD4161A+rs911x (read/write) 1002228 1002260 32 0.0
.bss 169168 169168 0 0.0
.data 2064 2064 0 0.0
.text 830976 831008 32 0.0
lock-app BRD4161A+wf200 (read/write) 1150288 1150304 16 0.0
.bss 152248 152248 0 0.0
.data 2072 2072 0 0.0
.text 995948 995964 16 0.0
window-app BRD4161A (read/write) 1099752 1099784 32 0.0
.bss 137772 137772 0 0.0
.data 2096 2096 0 0.0
.text 959864 959896 32 0.0
esp32 all-clusters-app c3devkit (read only) 1033882 1033912 30 0.0
(read/write) 1493646 1493646 0 0.0
.dram0.bss 71120 71120 0 0.0
.dram0.data 13696 13696 0 0.0
.flash.rodata 218160 218160 0 0.0
.flash.text 1033882 1033912 30 0.0
.iram0.text 65204 65204 0 0.0
m5stack (read only) 1086503 1086519 16 0.0
(read/write) 490924 490916 -8 -0.0
.dram0.bss 76640 76640 0 0.0
.dram0.data 34152 34152 0 0.0
.flash.rodata 247464 247456 -8 -0.0
.flash.text 1081119 1081135 16 0.0
.iram0.text 123939 123939 0 0.0
k32w light k32w0+release (read/write) 648188 648204 16 0.0
.bss 70712 70712 0 0.0
.data 2068 2068 0 0.0
.text 572680 572696 16 0.0
lock k32w0+release (read/write) 705184 705200 16 0.0
.bss 71160 71160 0 0.0
.data 2076 2076 0 0.0
.text 629220 629236 16 0.0
linux chip-tool-ipv6only arm64 (read only) 1031920 10319380 176 0.0
(read/write) 705169 705185 16 0.0
.bss 33297 33313 16 0.0
.data 3280 3280 0 0.0
.data.rel.ro 649784 649784 0 0.0
.dynamic 560 560 0 0.0
.got 13840 13840 0 0.0
.init 24 24 0 0.0
.init_array 200 200 0 0.0
.rodata 499300 499348 48 0.0
.text 8167492 8167620 128 0.0
thermostat-no-ble arm64 (read only) 2362964 2363156 192 0.0
(read/write) 141857 141857 0 0.0
.bss 55233 55233 0 0.0
.data 1680 1680 0 0.0
.data.rel.ro 76112 76112 0 0.0
.dynamic 560 560 0 0.0
.got 5056 5056 0 0.0
.init 24 24 0 0.0
.init_array 416 416 0 0.0
.rodata 141404 141452 48 0.0
.text 1983520 1983664 144 0.0
mbed lock-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2455184 2455232 48 0.0
.bss 215044 215044 0 0.0
.data 5872 5872 0 0.0
.text 1417828 1417876 48 0.0
nrfconnect all-clusters-app nrf52840dk_nrf52840 (read/write) 1181071 1181151 80 0.0
bss 143641 143641 0 0.0
rodata 143504 143552 48 0.0
text 814980 815016 36 0.0
all-clusters-minimal-app nrf52840dk_nrf52840 (read/write) 1160251 1160347 96 0.0
bss 142868 142868 0 0.0
rodata 135092 135140 48 0.0
text 803372 803412 40 0.0
psoc6 all-clusters cy8ckit_062s2_43012 (read only) 841960 841960 0 0.0
(read/write) 1742732 1742764 32 0.0
.ARM.attributes 46 46 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 188720 188720 0 0.0
.comment 204 204 0 0.0
.copy.table 24 24 0 0.0
.cy_m0p_image 6216 6216 0 0.0
.cy_sharedmem 8 8 0 0.0
.data 2664 2664 0 0.0
.debug_abbrev 1221450 1221471 21 0.0
.debug_aranges 111728 111728 0 0.0
.debug_frame 372964 372964 0 0.0
.debug_info 26715281 26715582 301 0.0
.debug_line 3657380 3657467 87 0.0
.debug_loc 3573063 3573342 279 0.0
.debug_ranges 338424 338424 0 0.0
.debug_str 3427396 3427396 0 0.0
.heap 841960 841960 0 0.0
.noinit 148 148 0 0.0
.ramVectors 736 736 0 0.0
.shstrtab 288 288 0 0.0
.stab 156 156 0 0.0
.stabstr 335 335 0 0.0
.stack_dummy 4096 4096 0 0.0
.strtab 570587 570587 0 0.0
.symtab 421488 421488 0 0.0
.text 1542960 1542992 32 0.0
.zero.table 8 8 0 0.0
text 0 0 0 0.0
all-clusters-minimal cy8ckit_062s2_43012 (read only) 842696 842696 0 0.0
(read/write) 1685932 1685964 32 0.0
.ARM.attributes 46 46 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 187984 187984 0 0.0
.comment 204 204 0 0.0
.copy.table 24 24 0 0.0
.cy_m0p_image 6216 6216 0 0.0
.cy_sharedmem 8 8 0 0.0
.data 2664 2664 0 0.0
.debug_abbrev 1213289 1213310 21 0.0
.debug_aranges 111200 111200 0 0.0
.debug_frame 376044 376044 0 0.0
.debug_info 26451903 26452204 301 0.0
.debug_line 3677896 3677983 87 0.0
.debug_loc 3560700 3560979 279 0.0
.debug_ranges 337040 337040 0 0.0
.debug_str 3416401 3416401 0 0.0
.heap 842696 842696 0 0.0
.noinit 148 148 0 0.0
.ramVectors 736 736 0 0.0
.shstrtab 288 288 0 0.0
.stab 156 156 0 0.0
.stabstr 335 335 0 0.0
.stack_dummy 4096 4096 0 0.0
.strtab 535061 535061 0 0.0
.symtab 408080 408080 0 0.0
.text 1486896 1486928 32 0.0
.zero.table 0 0 0 0.0
8 8 0 0.0
light cy8ckit_062s2_43012 (read only) 850928 850928 0 0.0
(read/write) 1603180 1603228 48 0.0
.ARM.attributes 46 46 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 179960 179960 0 0.0
.comment 204 204 0 0.0
.copy.table 24 24 0 0.0
.cy_m0p_image 6216 6216 0 0.0
.cy_sharedmem 8 8 0 0.0
.data 2456 2456 0 0.0
.debug_abbrev 1048108 1048129 21 0.0
.debug_aranges 103376 103376 0 0.0
.debug_frame 346312 346312 0 0.0
.debug_info 21914186 21914487 301 0.0
.debug_line 3248361 3248448 87 0.0
.debug_loc 3259042 3259321 279 0.0
.debug_ranges 302512 302512 0 0.0
.debug_str 3221667 3221667 0 0.0
.heap 850928 850928 0 0.0
.noinit 148 148 0 0.0
.ramVectors 736 736 0 0.0
.shstrtab 288 288 0 0.0
.stab 156 156 0 0.0
.stabstr 335 335 0 0.0
.stack_dummy 4096 4096 0 0.0
.strtab 468360 468360 0 0.0
.symtab 375168 375168 0 0.0
.text 1412376 1412424 48 0.0
.zero.table 0 0 0 0.0
8 8 0 0.0
lock cy8ckit_062s2_43012 (read only) 845896 845896 0 0.0
(read/write) 1640876 1640924 48 0.0
.ARM.attributes 46 46 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 184976 184976 0 0.0
.comment 204 204 0 0.0
.copy.table 24 24 0 0.0
.cy_m0p_image 6216 6216 0 0.0
.cy_sharedmem 8 8 0 0.0
.data 2472 2472 0 0.0
.debug_abbrev 1055543 1055564 21 0.0
.debug_aranges 104048 104048 0 0.0
.debug_frame 349140 349140 0 0.0
.debug_info 22293934 22294233 299 0.0
.debug_line 3257182 3257269 87 0.0
.debug_loc 3298895 3299174 279 0.0
.debug_ranges 305856 305856 0 0.0
.debug_str 3249088 3249088 0 0.0
.heap 845896 845896 0 0.0
.noinit 148 148 0 0.0
.ramVectors 736 736 0 0.0
.shstrtab 288 288 0 0.0
.stab 156 156 0 0.0
.stabstr 335 335 0 0.0
.stack_dummy 4096 4096 0 0.0
.strtab 474563 474563 0 0.0
.symtab 378352 378352 0 0.0
.text 1445040 1445088 48 0.0
.zero.table 0 0 0 0.0
8 8 0 0.0
qpg lighting-app qpg6105+debug (read/write) 1129148 1129164 16 0.0
.bss 106112 106112 0 0.0
.data 1028 1028 0 0.0
.text 576244 576260 16 0.0
lock-app qpg6105+debug (read/write) 1100160 1100176 16 0.0
.bss 102344 102344 0 0.0
.data 1032 1032 0 0.0
.text 547260 547276 16 0.0
telink light-switch-app tlsr9518adk80d (read/write) 808972 809088 116 0.0
bss 71344 71344 0 0.0
noinit 43488 43488 0 0.0
text 571452 571514 62 0.0
lighting-app tlsr9518adk80d (read/write) 830888 831004 116 0.0
bss 72200 72200 0 0.0
noinit 43488 43488 0 0.0
text 589576 589640 64 0.0

@andy31415 andy31415 merged commit 1972342 into project-chip:master Sep 5, 2022
@msandstedt
Copy link
Contributor

How do we reckon this is less risky?

Just in terms of the differences in behavior from what we have been testing so far....

Isn't simple, but definitely correct, what we want for a scheduler?

Yes, it is. But to get to "correct" we would need to fix #22377 somehow and stop using timers for ScheduleWork and them we might have a chance of "correct"....

The real question here is not "what is correct?" but "what can we get done in the next < 2 work weeks?"

OK, fair enough.

@bzbarsky-apple bzbarsky-apple deleted the fix-timer-cancellation branch September 6, 2022 13:44
plan44 added a commit to plan44/connectedhomeip that referenced this pull request Sep 8, 2022
…roject-chip#22375

This follows the rationale in  project-chip#22375 about posting the same work (same callback and appstate) again should not cancel the previously scheduled instance. Implemented now for the CHIP_SYSTEM_CONFIG_USE_LIBEV=1 case as well.
isiu-apple pushed a commit to isiu-apple/connectedhomeip that referenced this pull request Sep 16, 2022
…ip#22375)

* Duplicate src/system/tests/TestSystemScheduleLambda.cpp history in src/system/tests/TestSystemScheduleWork.cpp history.

* Fix timer cancellation to be reliable in LayerImplSelect.

To minimize risk, the changes here keep the "grab all the timers we
should fire, then fire them" setup instead of switching to the "fire
the timers one at a time" approach LayerImplFreeRTOS uses.

The fix consists of the following parts:

1) Store the list of timers to fire in a member, so we can cancel things from
   that list as needed.
2) To avoid canceling things scheduled by ScheduleWork, remove the CancelTimer
   call in ScheduleWork.  This does mean we now allow multiple timers for the
   same callback+appState in the timer list, if they were created by
   ScheduleWork, but that should be OK, since the only reason that pair needs to
   be unique is to allow cancellation and we never want to cancel the things
   ScheduleWork schedules.  As a followup we should stop using the timer list
   for ScheduleWork altogether and use ScheduleLambda like LayerImplFreeRTOS
   does, but that involves fixing the unit tests that call ScheduleWork without
   actually running the platfor manager event loop and expect it to work
   somehow.

TestRead was failing the sanity assert for not losing track of timers
to fire, because it was spinning a nested event loop.  The changes to
that test stop it from doing that.

Fixes project-chip#19387
Fixes project-chip#22160

* Add a unit test that timer cancelling works even for currently "in progress" timers

* Address review comments.

* Fix shadowing problem.

* Turn off TestSystemScheduleWork on esp32 QEMU for now.

* Turn off TestSystemScheduleWork on the fake platform too.

The fake platform's event loop does not actually process the SystemLayer events.

Co-authored-by: Andrei Litvin <andy314@gmail.com>
plan44 added a commit to plan44/connectedhomeip that referenced this pull request Oct 8, 2022
This follows the rationale in  project-chip#22375 about posting the same work (same callback and appstate) again should not cancel the previously scheduled instance.
plan44 added a commit to plan44/connectedhomeip that referenced this pull request Oct 28, 2022
This follows the rationale in  project-chip#22375 about posting the same work (same callback and appstate) again should not cancel the previously scheduled instance.
plan44 added a commit to plan44/connectedhomeip that referenced this pull request Dec 29, 2022
This follows the rationale in  project-chip#22375 about posting the same work (same callback and appstate) again should not cancel the previously scheduled instance.
plan44 added a commit to plan44/connectedhomeip that referenced this pull request Apr 6, 2023
This follows the rationale in  project-chip#22375 about posting the same work (same callback and appstate) again should not cancel the previously scheduled instance.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants