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

Implement persistent storage for attributes with "NVM" storage selected. #13172

Merged

Conversation

bzbarsky-apple
Copy link
Contributor

@bzbarsky-apple bzbarsky-apple commented Dec 21, 2021

Problem

Attributes marked as "NVM" storage are not actually stored across reboots.

Change overview

  1. Set the CurrentLevel attribute in all-clusters app to be NVM and default to 254.
  2. Remove the hardcoded setting of that attribute to 255 during boot in all-clusters app.
  3. Define and implement AttributePersistenceProvider to read/write persistent attributes.
  4. Fix bug in ServerStorageDelegate::SyncGetKeyValue: it was not setting the size outparam to the actual size read.
  5. Move EmberAfAttributeMetadata and a few functions for working with strings into a new header that can be included in places where generated headers (which af.h and af-types.h include) can't be.
  6. Rearrange the logic in emAfLoadAttributeDefaults a bit: instead of loading the default value into the RAM store and then checking for a persisted value, check for a persisted value first (if the attribute might have one), and only look for a default value if there is no persisted value. This removes the need for a separate emAfLoadAttributesFromStorage pass (which made sense back when that code was all generated, but it's not anymore).
  7. Fix emAfSaveAttributeToStorageIfNeeded to actually store the value.

Testing

Manual testing as follows:

  1. Commission chip-all-clusters-app on m5stack with node id 17.
  2. chip-tool levelcontrol read current-level 17 1 and verify value is 254
  3. chip-tool levelcontrol move-to-level 128 0 0 0 17 1
  4. Reboot the m5stack
  5. chip-tool levelcontrol read current-level 17 1

Without these changes, step 5 showed "254". Now it shows "128".

@github-actions
Copy link

github-actions bot commented Dec 21, 2021

PR #13172: Size comparison from bf7feea to 7bc13b8

Increases above 0.2%:

platform target config section bf7feea 7bc13b8 change % change
linux thermostat-no-ble arm64 .got 3888 3904 16 0.4
Increases (25 builds for efr32, esp32, k32w, linux, mbed, nrfconnect, p6, qpg, telink)
platform target config section bf7feea 7bc13b8 change % change
efr32 lighting-app BRD4161A (read only) 830568 831636 1068 0.1
(read/write) 127384 127396 12 0.0
.bss 125504 125520 16 0.0
.text 830560 831628 1068 0.1
BRD4161A+rpc (read only) 818196 819280 1084 0.1
(read/write) 144048 144056 8 0.0
.bss 142072 142080 8 0.0
.text 818188 819272 1084 0.1
window-app BRD4161A (read only) 803944 805028 1084 0.1
(read/write) 126320 126336 16 0.0
.bss 124488 124504 16 0.0
.text 803936 805020 1084 0.1
esp32 all-clusters-app c3devkit (read only) 883166 883990 824 0.1
(read/write) 1312986 1313154 168 0.0
.dram0.bss 69384 69400 16 0.0
.flash.rodata 176320 176472 152 0.1
.flash.text 883166 883990 824 0.1
m5stack (read only) 943435 944287 852 0.1
(read/write) 442080 442240 160 0.0
.dram0.bss 73888 73904 16 0.0
.flash.rodata 203128 203272 144 0.1
.flash.text 938051 938903 852 0.1
k32w light k32w061+release (read/write) 648764 649540 776 0.1
.bss 76512 76528 16 0.0
.text 564548 565308 760 0.1
lock k32w061+release (read/write) 633472 634240 768 0.1
.bss 76224 76232 8 0.0
.text 549588 550348 760 0.1
linux chip-tool-ipv6only arm64 (read only) 7006076 7008508 2432 0.0
(read/write) 326289 326433 144 0.0
.bss 54641 54673 32 0.1
.data.rel.ro 210144 210240 96 0.0
.got 56712 56728 16 0.0
.rodata 384228 384532 304 0.1
.text 5928548 5930436 1888 0.0
thermostat-no-ble arm64 (read only) 2017908 2020436 2528 0.1
(read/write) 144497 144625 128 0.1
.bss 64417 64433 16 0.0
.data.rel.ro 72376 72472 96 0.1
.got 3888 3904 16 0.4
.rodata 128932 129252 320 0.2
.text 1676304 1678272 1968 0.1
mbed all-clusters-app CY8CPROTO_062_4343W+release (read/write) 2340104 2341056 952 0.0
.bss 188660 188668 8 0.0
.text 1302680 1303632 952 0.1
lighting-app CY8CPROTO_062_4343W+release (read/write) 2330576 2331520 944 0.0
.bss 180936 180944 8 0.0
.text 1293176 1294120 944 0.1
lock-app CY8CPROTO_062_4343W+release (read/write) 2303672 2304552 880 0.0
.bss 179984 179992 8 0.0
.text 1266272 1267152 880 0.1
nrfconnect lighting-app nrf52840dk_nrf52840 (read/write) 935967 936923 956 0.1
bss 118428 118440 12 0.0
rodata 108124 108296 172 0.2
text 631864 632612 748 0.1
nrf52840dk_nrf52840+rpc (read/write) 922367 923295 928 0.1
bss 115472 115484 12 0.0
rodata 101540 101716 176 0.2
text 627176 627924 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 859730 860658 928 0.1
bss 116712 116724 12 0.0
rodata 103048 103224 176 0.2
text 559308 560056 748 0.1
lock-app nrf52840dk_nrf52840 (read/write) 908111 909039 928 0.1
bss 117616 117628 12 0.0
rodata 103428 103604 176 0.2
text 609692 610440 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 832042 832982 940 0.1
bss 115928 115940 12 0.0
rodata 98392 98564 172 0.2
text 537172 537920 748 0.1
pump-app nrf52840dk_nrf52840 (read/write) 909375 910331 956 0.1
bss 117376 117388 12 0.0
rodata 103644 103816 172 0.2
text 610928 611676 748 0.1
pump-controller-app nrf52840dk_nrf52840 (read/write) 906191 907151 960 0.1
bss 117404 117416 12 0.0
rodata 102900 103076 176 0.2
text 608440 609188 748 0.1
p6 all-clusters-app default (read/write) 2392056 2393160 1104 0.0
.bss 116860 116876 16 0.0
.text 1350320 1351424 1104 0.1
light-app default (read/write) 2325104 2326192 1088 0.0
.bss 106184 106200 16 0.0
.text 1283368 1284456 1088 0.1
lock-app default (read/write) 2297312 2298408 1096 0.0
.bss 105064 105080 16 0.0
.text 1255576 1256672 1096 0.1
qpg lighting-app qpg6105+debug (read only) 532232 533000 768 0.1
.bss 86840 86856 16 0.0
.text 526912 527680 768 0.1
lock-app qpg6105+debug (read only) 503912 504688 776 0.2
.bss 85976 85992 16 0.0
.text 498592 499368 776 0.2
telink lighting-app tlsr9518adk80d (read/write) 832258 833330 1072 0.1
bss 87088 87096 8 0.0
text 580366 581238 872 0.2
Full report (31 builds for efr32, esp32, k32w, linux, mbed, nrfconnect, p6, qpg, telink)
platform target config section bf7feea 7bc13b8 change % change
efr32 lighting-app BRD4161A (read only) 830568 831636 1068 0.1
(read/write) 127384 127396 12 0.0
.bss 125504 125520 16 0.0
.data 1876 1876 0 0.0
.text 830560 831628 1068 0.1
BRD4161A+rpc (read only) 818196 819280 1084 0.1
(read/write) 144048 144056 8 0.0
.bss 142072 142080 8 0.0
.data 1976 1976 0 0.0
.text 818188 819272 1084 0.1
window-app BRD4161A (read only) 803944 805028 1084 0.1
(read/write) 126320 126336 16 0.0
.bss 124488 124504 16 0.0
.data 1832 1832 0 0.0
.text 803936 805020 1084 0.1
esp32 all-clusters-app c3devkit (read only) 883166 883990 824 0.1
(read/write) 1312986 1313154 168 0.0
.dram0.bss 69384 69400 16 0.0
.dram0.data 14220 14220 0 0.0
.flash.rodata 176320 176472 152 0.1
.flash.text 883166 883990 824 0.1
.iram0.text 62254 62254 0 0.0
m5stack (read only) 943435 944287 852 0.1
(read/write) 442080 442240 160 0.0
.dram0.bss 73888 73904 16 0.0
.dram0.data 34056 34056 0 0.0
.flash.rodata 203128 203272 144 0.1
.flash.text 938051 938903 852 0.1
.iram0.text 122671 122671 0 0.0
k32w light k32w061+release (read/write) 648764 649540 776 0.1
.bss 76512 76528 16 0.0
.data 1904 1904 0 0.0
.text 564548 565308 760 0.1
lock k32w061+release (read/write) 633472 634240 768 0.1
.bss 76224 76232 8 0.0
.data 1860 1860 0 0.0
.text 549588 550348 760 0.1
linux chip-tool-ipv6only arm64 (read only) 7006076 7008508 2432 0.0
(read/write) 326289 326433 144 0.0
.bss 54641 54673 32 0.1
.data 1096 1096 0 0.0
.data.rel.ro 210144 210240 96 0.0
.dynamic 560 560 0 0.0
.got 56712 56728 16 0.0
.init 24 24 0 0.0
.init_array 168 168 0 0.0
.rodata 384228 384532 304 0.1
.text 5928548 5930436 1888 0.0
thermostat-no-ble arm64 (read only) 2017908 2020436 2528 0.1
(read/write) 144497 144625 128 0.1
.bss 64417 64433 16 0.0
.data 880 880 0 0.0
.data.rel.ro 72376 72472 96 0.1
.dynamic 560 560 0 0.0
.got 3888 3904 16 0.4
.init 24 24 0 0.0
.init_array 296 296 0 0.0
.rodata 128932 129252 320 0.2
.text 1676304 1678272 1968 0.1
mbed all-clusters-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2340104 2341056 952 0.0
.bss 188660 188668 8 0.0
.data 5272 5272 0 0.0
.text 1302680 1303632 952 0.1
lighting-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2330576 2331520 944 0.0
.bss 180936 180944 8 0.0
.data 5552 5552 0 0.0
.text 1293176 1294120 944 0.1
lock-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2303672 2304552 880 0.0
.bss 179984 179992 8 0.0
.data 5544 5544 0 0.0
.text 1266272 1267152 880 0.1
pigweed-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 1140008 1140008 0 0.0
.bss 11756 11756 0 0.0
.data 4368 4368 0 0.0
.text 103392 103392 0 0.0
shell CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2053688 2053688 0 0.0
.bss 156972 156972 0 0.0
.data 4864 4864 0 0.0
.text 1016288 1016288 0 0.0
nrfconnect lighting-app nrf52840dk_nrf52840 (read/write) 935967 936923 956 0.1
bss 118428 118440 12 0.0
rodata 108124 108296 172 0.2
text 631864 632612 748 0.1
nrf52840dk_nrf52840+rpc (read/write) 922367 923295 928 0.1
bss 115472 115484 12 0.0
rodata 101540 101716 176 0.2
text 627176 627924 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 859730 860658 928 0.1
bss 116712 116724 12 0.0
rodata 103048 103224 176 0.2
text 559308 560056 748 0.1
lock-app nrf52840dk_nrf52840 (read/write) 908111 909039 928 0.1
bss 117616 117628 12 0.0
rodata 103428 103604 176 0.2
text 609692 610440 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 832042 832982 940 0.1
bss 115928 115940 12 0.0
rodata 98392 98564 172 0.2
text 537172 537920 748 0.1
pigweed-app nrf52840dk_nrf52840 (read/write) 542351 542351 0 0.0
bss 52588 52588 0 0.0
rodata 50668 50668 0 0.0
text 376892 376892 0 0.0
pump-app nrf52840dk_nrf52840 (read/write) 909375 910331 956 0.1
bss 117376 117388 12 0.0
rodata 103644 103816 172 0.2
text 610928 611676 748 0.1
pump-controller-app nrf52840dk_nrf52840 (read/write) 906191 907151 960 0.1
bss 117404 117416 12 0.0
rodata 102900 103076 176 0.2
text 608440 609188 748 0.1
shell nrf52840dk_nrf52840 (read/write) 796079 796079 0 0.0
bss 109464 109464 0 0.0
rodata 78096 78096 0 0.0
text 532048 532048 0 0.0
nrf5340dk_nrf5340_cpuapp (read/write) 708710 708710 0 0.0
bss 107352 107352 0 0.0
rodata 72396 72396 0 0.0
text 449544 449544 0 0.0
p6 all-clusters-app default (read/write) 2392056 2393160 1104 0.0
.bss 116860 116876 16 0.0
.data 2552 2552 0 0.0
.text 1350320 1351424 1104 0.1
light-app default (read/write) 2325104 2326192 1088 0.0
.bss 106184 106200 16 0.0
.data 2384 2384 0 0.0
.text 1283368 1284456 1088 0.1
lock-app default (read/write) 2297312 2298408 1096 0.0
.bss 105064 105080 16 0.0
.data 2336 2336 0 0.0
.text 1255576 1256672 1096 0.1
qpg lighting-app qpg6105+debug (read only) 532232 533000 768 0.1
(read/write) 146936 146936 0 0.0
.bss 86840 86856 16 0.0
.data 1004 1004 0 0.0
.text 526912 527680 768 0.1
lock-app qpg6105+debug (read only) 503912 504688 776 0.2
(read/write) 146940 146940 0 0.0
.bss 85976 85992 16 0.0
.data 952 952 0 0.0
.text 498592 499368 776 0.2
persistent-storage-app qpg6105+debug (read only) 106448 106448 0 0.0
(read/write) 146938 146938 0 0.0
.bss 36146 36146 0 0.0
.data 288 288 0 0.0
.text 101128 101128 0 0.0
telink lighting-app tlsr9518adk80d (read/write) 832258 833330 1072 0.1
bss 87088 87096 8 0.0
noinit 37160 37160 0 0.0
text 580366 581238 872 0.2

@github-actions
Copy link

github-actions bot commented Dec 21, 2021

PR #13172: Size comparison from bf7feea to 2a1ae49

Increases above 0.2%:

platform target config section bf7feea 2a1ae49 change % change
linux thermostat-no-ble arm64 .got 3888 3904 16 0.4
Increases (23 builds for efr32, k32w, linux, mbed, nrfconnect, p6, qpg, telink)
platform target config section bf7feea 2a1ae49 change % change
efr32 lighting-app BRD4161A (read only) 830568 831636 1068 0.1
(read/write) 127384 127396 12 0.0
.bss 125504 125520 16 0.0
.text 830560 831628 1068 0.1
BRD4161A+rpc (read only) 818196 819280 1084 0.1
(read/write) 144048 144056 8 0.0
.bss 142072 142080 8 0.0
.text 818188 819272 1084 0.1
window-app BRD4161A (read only) 803944 805028 1084 0.1
(read/write) 126320 126336 16 0.0
.bss 124488 124504 16 0.0
.text 803936 805020 1084 0.1
k32w light k32w061+release (read/write) 648764 649540 776 0.1
.bss 76512 76528 16 0.0
.text 564548 565308 760 0.1
lock k32w061+release (read/write) 633472 634240 768 0.1
.bss 76224 76232 8 0.0
.text 549588 550348 760 0.1
linux chip-tool-ipv6only arm64 (read only) 7006076 7008508 2432 0.0
(read/write) 326289 326433 144 0.0
.bss 54641 54673 32 0.1
.data.rel.ro 210144 210240 96 0.0
.got 56712 56728 16 0.0
.rodata 384228 384532 304 0.1
.text 5928548 5930436 1888 0.0
thermostat-no-ble arm64 (read only) 2017908 2020436 2528 0.1
(read/write) 144497 144625 128 0.1
.bss 64417 64433 16 0.0
.data.rel.ro 72376 72472 96 0.1
.got 3888 3904 16 0.4
.rodata 128932 129252 320 0.2
.text 1676304 1678272 1968 0.1
mbed all-clusters-app CY8CPROTO_062_4343W+release (read/write) 2340104 2341056 952 0.0
.bss 188660 188668 8 0.0
.text 1302680 1303632 952 0.1
lighting-app CY8CPROTO_062_4343W+release (read/write) 2330576 2331520 944 0.0
.bss 180936 180944 8 0.0
.text 1293176 1294120 944 0.1
lock-app CY8CPROTO_062_4343W+release (read/write) 2303672 2304552 880 0.0
.bss 179984 179992 8 0.0
.text 1266272 1267152 880 0.1
nrfconnect lighting-app nrf52840dk_nrf52840 (read/write) 935967 936923 956 0.1
bss 118428 118440 12 0.0
rodata 108124 108296 172 0.2
text 631864 632612 748 0.1
nrf52840dk_nrf52840+rpc (read/write) 922367 923295 928 0.1
bss 115472 115484 12 0.0
rodata 101540 101716 176 0.2
text 627176 627924 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 859730 860658 928 0.1
bss 116712 116724 12 0.0
rodata 103048 103224 176 0.2
text 559308 560056 748 0.1
lock-app nrf52840dk_nrf52840 (read/write) 908111 909039 928 0.1
bss 117616 117628 12 0.0
rodata 103428 103604 176 0.2
text 609692 610440 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 832042 832982 940 0.1
bss 115928 115940 12 0.0
rodata 98392 98564 172 0.2
text 537172 537920 748 0.1
pump-app nrf52840dk_nrf52840 (read/write) 909375 910331 956 0.1
bss 117376 117388 12 0.0
rodata 103644 103816 172 0.2
text 610928 611676 748 0.1
pump-controller-app nrf52840dk_nrf52840 (read/write) 906191 907151 960 0.1
bss 117404 117416 12 0.0
rodata 102900 103076 176 0.2
text 608440 609188 748 0.1
p6 all-clusters-app default (read/write) 2392056 2393160 1104 0.0
.bss 116860 116876 16 0.0
.text 1350320 1351424 1104 0.1
light-app default (read/write) 2325104 2326192 1088 0.0
.bss 106184 106200 16 0.0
.text 1283368 1284456 1088 0.1
lock-app default (read/write) 2297312 2298408 1096 0.0
.bss 105064 105080 16 0.0
.text 1255576 1256672 1096 0.1
qpg lighting-app qpg6105+debug (read only) 532232 533000 768 0.1
.bss 86840 86856 16 0.0
.text 526912 527680 768 0.1
lock-app qpg6105+debug (read only) 503912 504688 776 0.2
.bss 85976 85992 16 0.0
.text 498592 499368 776 0.2
telink lighting-app tlsr9518adk80d (read/write) 832258 833330 1072 0.1
bss 87088 87096 8 0.0
text 580366 581238 872 0.2
Full report (29 builds for efr32, k32w, linux, mbed, nrfconnect, p6, qpg, telink)
platform target config section bf7feea 2a1ae49 change % change
efr32 lighting-app BRD4161A (read only) 830568 831636 1068 0.1
(read/write) 127384 127396 12 0.0
.bss 125504 125520 16 0.0
.data 1876 1876 0 0.0
.text 830560 831628 1068 0.1
BRD4161A+rpc (read only) 818196 819280 1084 0.1
(read/write) 144048 144056 8 0.0
.bss 142072 142080 8 0.0
.data 1976 1976 0 0.0
.text 818188 819272 1084 0.1
window-app BRD4161A (read only) 803944 805028 1084 0.1
(read/write) 126320 126336 16 0.0
.bss 124488 124504 16 0.0
.data 1832 1832 0 0.0
.text 803936 805020 1084 0.1
k32w light k32w061+release (read/write) 648764 649540 776 0.1
.bss 76512 76528 16 0.0
.data 1904 1904 0 0.0
.text 564548 565308 760 0.1
lock k32w061+release (read/write) 633472 634240 768 0.1
.bss 76224 76232 8 0.0
.data 1860 1860 0 0.0
.text 549588 550348 760 0.1
linux chip-tool-ipv6only arm64 (read only) 7006076 7008508 2432 0.0
(read/write) 326289 326433 144 0.0
.bss 54641 54673 32 0.1
.data 1096 1096 0 0.0
.data.rel.ro 210144 210240 96 0.0
.dynamic 560 560 0 0.0
.got 56712 56728 16 0.0
.init 24 24 0 0.0
.init_array 168 168 0 0.0
.rodata 384228 384532 304 0.1
.text 5928548 5930436 1888 0.0
thermostat-no-ble arm64 (read only) 2017908 2020436 2528 0.1
(read/write) 144497 144625 128 0.1
.bss 64417 64433 16 0.0
.data 880 880 0 0.0
.data.rel.ro 72376 72472 96 0.1
.dynamic 560 560 0 0.0
.got 3888 3904 16 0.4
.init 24 24 0 0.0
.init_array 296 296 0 0.0
.rodata 128932 129252 320 0.2
.text 1676304 1678272 1968 0.1
mbed all-clusters-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2340104 2341056 952 0.0
.bss 188660 188668 8 0.0
.data 5272 5272 0 0.0
.text 1302680 1303632 952 0.1
lighting-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2330576 2331520 944 0.0
.bss 180936 180944 8 0.0
.data 5552 5552 0 0.0
.text 1293176 1294120 944 0.1
lock-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2303672 2304552 880 0.0
.bss 179984 179992 8 0.0
.data 5544 5544 0 0.0
.text 1266272 1267152 880 0.1
pigweed-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 1140008 1140008 0 0.0
.bss 11756 11756 0 0.0
.data 4368 4368 0 0.0
.text 103392 103392 0 0.0
shell CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2053688 2053688 0 0.0
.bss 156972 156972 0 0.0
.data 4864 4864 0 0.0
.text 1016288 1016288 0 0.0
nrfconnect lighting-app nrf52840dk_nrf52840 (read/write) 935967 936923 956 0.1
bss 118428 118440 12 0.0
rodata 108124 108296 172 0.2
text 631864 632612 748 0.1
nrf52840dk_nrf52840+rpc (read/write) 922367 923295 928 0.1
bss 115472 115484 12 0.0
rodata 101540 101716 176 0.2
text 627176 627924 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 859730 860658 928 0.1
bss 116712 116724 12 0.0
rodata 103048 103224 176 0.2
text 559308 560056 748 0.1
lock-app nrf52840dk_nrf52840 (read/write) 908111 909039 928 0.1
bss 117616 117628 12 0.0
rodata 103428 103604 176 0.2
text 609692 610440 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 832042 832982 940 0.1
bss 115928 115940 12 0.0
rodata 98392 98564 172 0.2
text 537172 537920 748 0.1
pigweed-app nrf52840dk_nrf52840 (read/write) 542351 542351 0 0.0
bss 52588 52588 0 0.0
rodata 50668 50668 0 0.0
text 376892 376892 0 0.0
pump-app nrf52840dk_nrf52840 (read/write) 909375 910331 956 0.1
bss 117376 117388 12 0.0
rodata 103644 103816 172 0.2
text 610928 611676 748 0.1
pump-controller-app nrf52840dk_nrf52840 (read/write) 906191 907151 960 0.1
bss 117404 117416 12 0.0
rodata 102900 103076 176 0.2
text 608440 609188 748 0.1
shell nrf52840dk_nrf52840 (read/write) 796079 796079 0 0.0
bss 109464 109464 0 0.0
rodata 78096 78096 0 0.0
text 532048 532048 0 0.0
nrf5340dk_nrf5340_cpuapp (read/write) 708710 708710 0 0.0
bss 107352 107352 0 0.0
rodata 72396 72396 0 0.0
text 449544 449544 0 0.0
p6 all-clusters-app default (read/write) 2392056 2393160 1104 0.0
.bss 116860 116876 16 0.0
.data 2552 2552 0 0.0
.text 1350320 1351424 1104 0.1
light-app default (read/write) 2325104 2326192 1088 0.0
.bss 106184 106200 16 0.0
.data 2384 2384 0 0.0
.text 1283368 1284456 1088 0.1
lock-app default (read/write) 2297312 2298408 1096 0.0
.bss 105064 105080 16 0.0
.data 2336 2336 0 0.0
.text 1255576 1256672 1096 0.1
qpg lighting-app qpg6105+debug (read only) 532232 533000 768 0.1
(read/write) 146936 146936 0 0.0
.bss 86840 86856 16 0.0
.data 1004 1004 0 0.0
.text 526912 527680 768 0.1
lock-app qpg6105+debug (read only) 503912 504688 776 0.2
(read/write) 146940 146940 0 0.0
.bss 85976 85992 16 0.0
.data 952 952 0 0.0
.text 498592 499368 776 0.2
persistent-storage-app qpg6105+debug (read only) 106448 106448 0 0.0
(read/write) 146938 146938 0 0.0
.bss 36146 36146 0 0.0
.data 288 288 0 0.0
.text 101128 101128 0 0.0
telink lighting-app tlsr9518adk80d (read/write) 832258 833330 1072 0.1
bss 87088 87096 8 0.0
noinit 37160 37160 0 0.0
text 580366 581238 872 0.2

@github-actions
Copy link

github-actions bot commented Dec 21, 2021

PR #13172: Size comparison from afec776 to 3c6525c

Increases above 0.2%:

platform target config section afec776 3c6525c change % change
linux thermostat-no-ble arm64 .got 3896 3912 16 0.4
Increases (25 builds for efr32, esp32, k32w, linux, mbed, nrfconnect, p6, qpg, telink)
platform target config section afec776 3c6525c change % change
efr32 lighting-app BRD4161A (read only) 830568 831636 1068 0.1
(read/write) 127384 127396 12 0.0
.bss 125504 125520 16 0.0
.text 830560 831628 1068 0.1
BRD4161A+rpc (read only) 818196 819280 1084 0.1
(read/write) 144048 144056 8 0.0
.bss 142072 142080 8 0.0
.text 818188 819272 1084 0.1
window-app BRD4161A (read only) 804016 805100 1084 0.1
(read/write) 126320 126336 16 0.0
.bss 124488 124504 16 0.0
.text 804008 805092 1084 0.1
esp32 all-clusters-app c3devkit (read only) 885820 886644 824 0.1
(read/write) 1313018 1313186 168 0.0
.dram0.bss 69384 69400 16 0.0
.flash.rodata 176352 176504 152 0.1
.flash.text 885820 886644 824 0.1
m5stack (read only) 946503 947331 828 0.1
(read/write) 442112 442272 160 0.0
.dram0.bss 73888 73904 16 0.0
.flash.rodata 203160 203304 144 0.1
.flash.text 941119 941947 828 0.1
k32w light k32w061+release (read/write) 648764 649540 776 0.1
.bss 76512 76528 16 0.0
.text 564548 565308 760 0.1
lock k32w061+release (read/write) 633472 634240 768 0.1
.bss 76224 76232 8 0.0
.text 549588 550348 760 0.1
linux chip-tool-ipv6only arm64 (read only) 7007292 7009740 2448 0.0
(read/write) 326353 326497 144 0.0
.bss 54641 54673 32 0.1
.data.rel.ro 210200 210296 96 0.0
.got 56720 56736 16 0.0
.rodata 384244 384548 304 0.1
.text 5929556 5931460 1904 0.0
thermostat-no-ble arm64 (read only) 2018564 2021092 2528 0.1
(read/write) 144561 144689 128 0.1
.bss 64417 64433 16 0.0
.data.rel.ro 72432 72528 96 0.1
.got 3896 3912 16 0.4
.rodata 128932 129252 320 0.2
.text 1676768 1678736 1968 0.1
mbed all-clusters-app CY8CPROTO_062_4343W+release (read/write) 2342856 2343808 952 0.0
.bss 188660 188668 8 0.0
.text 1305432 1306384 952 0.1
lighting-app CY8CPROTO_062_4343W+release (read/write) 2330656 2331600 944 0.0
.bss 180936 180944 8 0.0
.text 1293256 1294200 944 0.1
lock-app CY8CPROTO_062_4343W+release (read/write) 2303752 2304696 944 0.0
.bss 179984 179992 8 0.0
.text 1266352 1267296 944 0.1
nrfconnect lighting-app nrf52840dk_nrf52840 (read/write) 935967 936923 956 0.1
bss 118428 118440 12 0.0
rodata 108124 108296 172 0.2
text 631864 632612 748 0.1
nrf52840dk_nrf52840+rpc (read/write) 922367 923295 928 0.1
bss 115472 115484 12 0.0
rodata 101540 101716 176 0.2
text 627176 627924 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 859730 860658 928 0.1
bss 116712 116724 12 0.0
rodata 103048 103224 176 0.2
text 559308 560056 748 0.1
lock-app nrf52840dk_nrf52840 (read/write) 908111 909039 928 0.1
bss 117616 117628 12 0.0
rodata 103428 103604 176 0.2
text 609692 610440 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 832042 832982 940 0.1
bss 115928 115940 12 0.0
rodata 98392 98564 172 0.2
text 537172 537920 748 0.1
pump-app nrf52840dk_nrf52840 (read/write) 909375 910331 956 0.1
bss 117376 117388 12 0.0
rodata 103644 103816 172 0.2
text 610928 611676 748 0.1
pump-controller-app nrf52840dk_nrf52840 (read/write) 906191 907151 960 0.1
bss 117404 117416 12 0.0
rodata 102900 103076 176 0.2
text 608440 609188 748 0.1
p6 all-clusters-app default (read/write) 2395264 2396360 1096 0.0
.bss 116860 116876 16 0.0
.text 1353528 1354624 1096 0.1
light-app default (read/write) 2325208 2326304 1096 0.0
.bss 106184 106200 16 0.0
.text 1283472 1284568 1096 0.1
lock-app default (read/write) 2297424 2298512 1088 0.0
.bss 105064 105080 16 0.0
.text 1255688 1256776 1088 0.1
qpg lighting-app qpg6105+debug (read only) 532232 533000 768 0.1
.bss 86840 86856 16 0.0
.text 526912 527680 768 0.1
lock-app qpg6105+debug (read only) 503912 504688 776 0.2
.bss 85976 85992 16 0.0
.text 498592 499368 776 0.2
telink lighting-app tlsr9518adk80d (read/write) 832258 833330 1072 0.1
bss 87088 87096 8 0.0
text 580366 581238 872 0.2
Full report (31 builds for efr32, esp32, k32w, linux, mbed, nrfconnect, p6, qpg, telink)
platform target config section afec776 3c6525c change % change
efr32 lighting-app BRD4161A (read only) 830568 831636 1068 0.1
(read/write) 127384 127396 12 0.0
.bss 125504 125520 16 0.0
.data 1876 1876 0 0.0
.text 830560 831628 1068 0.1
BRD4161A+rpc (read only) 818196 819280 1084 0.1
(read/write) 144048 144056 8 0.0
.bss 142072 142080 8 0.0
.data 1976 1976 0 0.0
.text 818188 819272 1084 0.1
window-app BRD4161A (read only) 804016 805100 1084 0.1
(read/write) 126320 126336 16 0.0
.bss 124488 124504 16 0.0
.data 1832 1832 0 0.0
.text 804008 805092 1084 0.1
esp32 all-clusters-app c3devkit (read only) 885820 886644 824 0.1
(read/write) 1313018 1313186 168 0.0
.dram0.bss 69384 69400 16 0.0
.dram0.data 14220 14220 0 0.0
.flash.rodata 176352 176504 152 0.1
.flash.text 885820 886644 824 0.1
.iram0.text 62254 62254 0 0.0
m5stack (read only) 946503 947331 828 0.1
(read/write) 442112 442272 160 0.0
.dram0.bss 73888 73904 16 0.0
.dram0.data 34056 34056 0 0.0
.flash.rodata 203160 203304 144 0.1
.flash.text 941119 941947 828 0.1
.iram0.text 122671 122671 0 0.0
k32w light k32w061+release (read/write) 648764 649540 776 0.1
.bss 76512 76528 16 0.0
.data 1904 1904 0 0.0
.text 564548 565308 760 0.1
lock k32w061+release (read/write) 633472 634240 768 0.1
.bss 76224 76232 8 0.0
.data 1860 1860 0 0.0
.text 549588 550348 760 0.1
linux chip-tool-ipv6only arm64 (read only) 7007292 7009740 2448 0.0
(read/write) 326353 326497 144 0.0
.bss 54641 54673 32 0.1
.data 1096 1096 0 0.0
.data.rel.ro 210200 210296 96 0.0
.dynamic 560 560 0 0.0
.got 56720 56736 16 0.0
.init 24 24 0 0.0
.init_array 168 168 0 0.0
.rodata 384244 384548 304 0.1
.text 5929556 5931460 1904 0.0
thermostat-no-ble arm64 (read only) 2018564 2021092 2528 0.1
(read/write) 144561 144689 128 0.1
.bss 64417 64433 16 0.0
.data 880 880 0 0.0
.data.rel.ro 72432 72528 96 0.1
.dynamic 560 560 0 0.0
.got 3896 3912 16 0.4
.init 24 24 0 0.0
.init_array 296 296 0 0.0
.rodata 128932 129252 320 0.2
.text 1676768 1678736 1968 0.1
mbed all-clusters-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2342856 2343808 952 0.0
.bss 188660 188668 8 0.0
.data 5280 5280 0 0.0
.text 1305432 1306384 952 0.1
lighting-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2330656 2331600 944 0.0
.bss 180936 180944 8 0.0
.data 5552 5552 0 0.0
.text 1293256 1294200 944 0.1
lock-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2303752 2304696 944 0.0
.bss 179984 179992 8 0.0
.data 5544 5544 0 0.0
.text 1266352 1267296 944 0.1
pigweed-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 1140008 1140008 0 0.0
.bss 11756 11756 0 0.0
.data 4368 4368 0 0.0
.text 103392 103392 0 0.0
shell CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2053840 2053840 0 0.0
.bss 156972 156972 0 0.0
.data 4864 4864 0 0.0
.text 1016440 1016440 0 0.0
nrfconnect lighting-app nrf52840dk_nrf52840 (read/write) 935967 936923 956 0.1
bss 118428 118440 12 0.0
rodata 108124 108296 172 0.2
text 631864 632612 748 0.1
nrf52840dk_nrf52840+rpc (read/write) 922367 923295 928 0.1
bss 115472 115484 12 0.0
rodata 101540 101716 176 0.2
text 627176 627924 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 859730 860658 928 0.1
bss 116712 116724 12 0.0
rodata 103048 103224 176 0.2
text 559308 560056 748 0.1
lock-app nrf52840dk_nrf52840 (read/write) 908111 909039 928 0.1
bss 117616 117628 12 0.0
rodata 103428 103604 176 0.2
text 609692 610440 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 832042 832982 940 0.1
bss 115928 115940 12 0.0
rodata 98392 98564 172 0.2
text 537172 537920 748 0.1
pigweed-app nrf52840dk_nrf52840 (read/write) 542351 542351 0 0.0
bss 52588 52588 0 0.0
rodata 50668 50668 0 0.0
text 376892 376892 0 0.0
pump-app nrf52840dk_nrf52840 (read/write) 909375 910331 956 0.1
bss 117376 117388 12 0.0
rodata 103644 103816 172 0.2
text 610928 611676 748 0.1
pump-controller-app nrf52840dk_nrf52840 (read/write) 906191 907151 960 0.1
bss 117404 117416 12 0.0
rodata 102900 103076 176 0.2
text 608440 609188 748 0.1
shell nrf52840dk_nrf52840 (read/write) 796079 796079 0 0.0
bss 109464 109464 0 0.0
rodata 78096 78096 0 0.0
text 532048 532048 0 0.0
nrf5340dk_nrf5340_cpuapp (read/write) 708710 708710 0 0.0
bss 107352 107352 0 0.0
rodata 72396 72396 0 0.0
text 449544 449544 0 0.0
p6 all-clusters-app default (read/write) 2395264 2396360 1096 0.0
.bss 116860 116876 16 0.0
.data 2552 2552 0 0.0
.text 1353528 1354624 1096 0.1
light-app default (read/write) 2325208 2326304 1096 0.0
.bss 106184 106200 16 0.0
.data 2384 2384 0 0.0
.text 1283472 1284568 1096 0.1
lock-app default (read/write) 2297424 2298512 1088 0.0
.bss 105064 105080 16 0.0
.data 2336 2336 0 0.0
.text 1255688 1256776 1088 0.1
qpg lighting-app qpg6105+debug (read only) 532232 533000 768 0.1
(read/write) 146936 146936 0 0.0
.bss 86840 86856 16 0.0
.data 1004 1004 0 0.0
.text 526912 527680 768 0.1
lock-app qpg6105+debug (read only) 503912 504688 776 0.2
(read/write) 146940 146940 0 0.0
.bss 85976 85992 16 0.0
.data 952 952 0 0.0
.text 498592 499368 776 0.2
persistent-storage-app qpg6105+debug (read only) 106448 106448 0 0.0
(read/write) 146938 146938 0 0.0
.bss 36146 36146 0 0.0
.data 288 288 0 0.0
.text 101128 101128 0 0.0
telink lighting-app tlsr9518adk80d (read/write) 832258 833330 1072 0.1
bss 87088 87096 8 0.0
noinit 37160 37160 0 0.0
text 580366 581238 872 0.2

@github-actions
Copy link

github-actions bot commented Dec 21, 2021

PR #13172: Size comparison from afec776 to ca676e0

Increases above 0.2%:

platform target config section afec776 ca676e0 change % change
linux thermostat-no-ble arm64 .got 3896 3912 16 0.4
Increases (25 builds for efr32, esp32, k32w, linux, mbed, nrfconnect, p6, qpg, telink)
platform target config section afec776 ca676e0 change % change
efr32 lighting-app BRD4161A (read only) 830568 831636 1068 0.1
(read/write) 127384 127396 12 0.0
.bss 125504 125520 16 0.0
.text 830560 831628 1068 0.1
BRD4161A+rpc (read only) 818196 819280 1084 0.1
(read/write) 144048 144056 8 0.0
.bss 142072 142080 8 0.0
.text 818188 819272 1084 0.1
window-app BRD4161A (read only) 804016 805100 1084 0.1
(read/write) 126320 126336 16 0.0
.bss 124488 124504 16 0.0
.text 804008 805092 1084 0.1
esp32 all-clusters-app c3devkit (read only) 885820 886644 824 0.1
(read/write) 1313018 1313186 168 0.0
.dram0.bss 69384 69400 16 0.0
.flash.rodata 176352 176504 152 0.1
.flash.text 885820 886644 824 0.1
m5stack (read only) 946503 947331 828 0.1
(read/write) 442112 442272 160 0.0
.dram0.bss 73888 73904 16 0.0
.flash.rodata 203160 203304 144 0.1
.flash.text 941119 941947 828 0.1
k32w light k32w061+release (read/write) 648764 649540 776 0.1
.bss 76512 76528 16 0.0
.text 564548 565308 760 0.1
lock k32w061+release (read/write) 633472 634240 768 0.1
.bss 76224 76232 8 0.0
.text 549588 550348 760 0.1
linux chip-tool-ipv6only arm64 (read only) 7007292 7010668 3376 0.0
(read/write) 326353 326513 160 0.0
.bss 54641 54673 32 0.1
.data.rel.ro 210200 210296 96 0.0
.got 56720 56752 32 0.1
.rodata 384244 384628 384 0.1
.text 5929556 5932260 2704 0.0
thermostat-no-ble arm64 (read only) 2018564 2021092 2528 0.1
(read/write) 144561 144689 128 0.1
.bss 64417 64433 16 0.0
.data.rel.ro 72432 72528 96 0.1
.got 3896 3912 16 0.4
.rodata 128932 129252 320 0.2
.text 1676768 1678736 1968 0.1
mbed all-clusters-app CY8CPROTO_062_4343W+release (read/write) 2342856 2343808 952 0.0
.bss 188660 188668 8 0.0
.text 1305432 1306384 952 0.1
lighting-app CY8CPROTO_062_4343W+release (read/write) 2330656 2331600 944 0.0
.bss 180936 180944 8 0.0
.text 1293256 1294200 944 0.1
lock-app CY8CPROTO_062_4343W+release (read/write) 2303752 2304696 944 0.0
.bss 179984 179992 8 0.0
.text 1266352 1267296 944 0.1
nrfconnect lighting-app nrf52840dk_nrf52840 (read/write) 935967 936923 956 0.1
bss 118428 118440 12 0.0
rodata 108124 108296 172 0.2
text 631864 632612 748 0.1
nrf52840dk_nrf52840+rpc (read/write) 922367 923295 928 0.1
bss 115472 115484 12 0.0
rodata 101540 101716 176 0.2
text 627176 627924 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 859730 860658 928 0.1
bss 116712 116724 12 0.0
rodata 103048 103224 176 0.2
text 559308 560056 748 0.1
lock-app nrf52840dk_nrf52840 (read/write) 908111 909039 928 0.1
bss 117616 117628 12 0.0
rodata 103428 103604 176 0.2
text 609692 610440 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 832042 832982 940 0.1
bss 115928 115940 12 0.0
rodata 98392 98564 172 0.2
text 537172 537920 748 0.1
pump-app nrf52840dk_nrf52840 (read/write) 909375 910331 956 0.1
bss 117376 117388 12 0.0
rodata 103644 103816 172 0.2
text 610928 611676 748 0.1
pump-controller-app nrf52840dk_nrf52840 (read/write) 906191 907151 960 0.1
bss 117404 117416 12 0.0
rodata 102900 103076 176 0.2
text 608440 609188 748 0.1
p6 all-clusters-app default (read/write) 2395264 2396360 1096 0.0
.bss 116860 116876 16 0.0
.text 1353528 1354624 1096 0.1
light-app default (read/write) 2325208 2326304 1096 0.0
.bss 106184 106200 16 0.0
.text 1283472 1284568 1096 0.1
lock-app default (read/write) 2297424 2298512 1088 0.0
.bss 105064 105080 16 0.0
.text 1255688 1256776 1088 0.1
qpg lighting-app qpg6105+debug (read only) 532232 533000 768 0.1
.bss 86840 86856 16 0.0
.text 526912 527680 768 0.1
lock-app qpg6105+debug (read only) 503912 504688 776 0.2
.bss 85976 85992 16 0.0
.text 498592 499368 776 0.2
telink lighting-app tlsr9518adk80d (read/write) 832258 833330 1072 0.1
bss 87088 87096 8 0.0
text 580366 581238 872 0.2
Full report (31 builds for efr32, esp32, k32w, linux, mbed, nrfconnect, p6, qpg, telink)
platform target config section afec776 ca676e0 change % change
efr32 lighting-app BRD4161A (read only) 830568 831636 1068 0.1
(read/write) 127384 127396 12 0.0
.bss 125504 125520 16 0.0
.data 1876 1876 0 0.0
.text 830560 831628 1068 0.1
BRD4161A+rpc (read only) 818196 819280 1084 0.1
(read/write) 144048 144056 8 0.0
.bss 142072 142080 8 0.0
.data 1976 1976 0 0.0
.text 818188 819272 1084 0.1
window-app BRD4161A (read only) 804016 805100 1084 0.1
(read/write) 126320 126336 16 0.0
.bss 124488 124504 16 0.0
.data 1832 1832 0 0.0
.text 804008 805092 1084 0.1
esp32 all-clusters-app c3devkit (read only) 885820 886644 824 0.1
(read/write) 1313018 1313186 168 0.0
.dram0.bss 69384 69400 16 0.0
.dram0.data 14220 14220 0 0.0
.flash.rodata 176352 176504 152 0.1
.flash.text 885820 886644 824 0.1
.iram0.text 62254 62254 0 0.0
m5stack (read only) 946503 947331 828 0.1
(read/write) 442112 442272 160 0.0
.dram0.bss 73888 73904 16 0.0
.dram0.data 34056 34056 0 0.0
.flash.rodata 203160 203304 144 0.1
.flash.text 941119 941947 828 0.1
.iram0.text 122671 122671 0 0.0
k32w light k32w061+release (read/write) 648764 649540 776 0.1
.bss 76512 76528 16 0.0
.data 1904 1904 0 0.0
.text 564548 565308 760 0.1
lock k32w061+release (read/write) 633472 634240 768 0.1
.bss 76224 76232 8 0.0
.data 1860 1860 0 0.0
.text 549588 550348 760 0.1
linux chip-tool-ipv6only arm64 (read only) 7007292 7010668 3376 0.0
(read/write) 326353 326513 160 0.0
.bss 54641 54673 32 0.1
.data 1096 1096 0 0.0
.data.rel.ro 210200 210296 96 0.0
.dynamic 560 560 0 0.0
.got 56720 56752 32 0.1
.init 24 24 0 0.0
.init_array 168 168 0 0.0
.rodata 384244 384628 384 0.1
.text 5929556 5932260 2704 0.0
thermostat-no-ble arm64 (read only) 2018564 2021092 2528 0.1
(read/write) 144561 144689 128 0.1
.bss 64417 64433 16 0.0
.data 880 880 0 0.0
.data.rel.ro 72432 72528 96 0.1
.dynamic 560 560 0 0.0
.got 3896 3912 16 0.4
.init 24 24 0 0.0
.init_array 296 296 0 0.0
.rodata 128932 129252 320 0.2
.text 1676768 1678736 1968 0.1
mbed all-clusters-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2342856 2343808 952 0.0
.bss 188660 188668 8 0.0
.data 5280 5280 0 0.0
.text 1305432 1306384 952 0.1
lighting-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2330656 2331600 944 0.0
.bss 180936 180944 8 0.0
.data 5552 5552 0 0.0
.text 1293256 1294200 944 0.1
lock-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2303752 2304696 944 0.0
.bss 179984 179992 8 0.0
.data 5544 5544 0 0.0
.text 1266352 1267296 944 0.1
pigweed-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 1140008 1140008 0 0.0
.bss 11756 11756 0 0.0
.data 4368 4368 0 0.0
.text 103392 103392 0 0.0
shell CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2053840 2053840 0 0.0
.bss 156972 156972 0 0.0
.data 4864 4864 0 0.0
.text 1016440 1016440 0 0.0
nrfconnect lighting-app nrf52840dk_nrf52840 (read/write) 935967 936923 956 0.1
bss 118428 118440 12 0.0
rodata 108124 108296 172 0.2
text 631864 632612 748 0.1
nrf52840dk_nrf52840+rpc (read/write) 922367 923295 928 0.1
bss 115472 115484 12 0.0
rodata 101540 101716 176 0.2
text 627176 627924 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 859730 860658 928 0.1
bss 116712 116724 12 0.0
rodata 103048 103224 176 0.2
text 559308 560056 748 0.1
lock-app nrf52840dk_nrf52840 (read/write) 908111 909039 928 0.1
bss 117616 117628 12 0.0
rodata 103428 103604 176 0.2
text 609692 610440 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 832042 832982 940 0.1
bss 115928 115940 12 0.0
rodata 98392 98564 172 0.2
text 537172 537920 748 0.1
pigweed-app nrf52840dk_nrf52840 (read/write) 542351 542351 0 0.0
bss 52588 52588 0 0.0
rodata 50668 50668 0 0.0
text 376892 376892 0 0.0
pump-app nrf52840dk_nrf52840 (read/write) 909375 910331 956 0.1
bss 117376 117388 12 0.0
rodata 103644 103816 172 0.2
text 610928 611676 748 0.1
pump-controller-app nrf52840dk_nrf52840 (read/write) 906191 907151 960 0.1
bss 117404 117416 12 0.0
rodata 102900 103076 176 0.2
text 608440 609188 748 0.1
shell nrf52840dk_nrf52840 (read/write) 796079 796079 0 0.0
bss 109464 109464 0 0.0
rodata 78096 78096 0 0.0
text 532048 532048 0 0.0
nrf5340dk_nrf5340_cpuapp (read/write) 708710 708710 0 0.0
bss 107352 107352 0 0.0
rodata 72396 72396 0 0.0
text 449544 449544 0 0.0
p6 all-clusters-app default (read/write) 2395264 2396360 1096 0.0
.bss 116860 116876 16 0.0
.data 2552 2552 0 0.0
.text 1353528 1354624 1096 0.1
light-app default (read/write) 2325208 2326304 1096 0.0
.bss 106184 106200 16 0.0
.data 2384 2384 0 0.0
.text 1283472 1284568 1096 0.1
lock-app default (read/write) 2297424 2298512 1088 0.0
.bss 105064 105080 16 0.0
.data 2336 2336 0 0.0
.text 1255688 1256776 1088 0.1
qpg lighting-app qpg6105+debug (read only) 532232 533000 768 0.1
(read/write) 146936 146936 0 0.0
.bss 86840 86856 16 0.0
.data 1004 1004 0 0.0
.text 526912 527680 768 0.1
lock-app qpg6105+debug (read only) 503912 504688 776 0.2
(read/write) 146940 146940 0 0.0
.bss 85976 85992 16 0.0
.data 952 952 0 0.0
.text 498592 499368 776 0.2
persistent-storage-app qpg6105+debug (read only) 106448 106448 0 0.0
(read/write) 146938 146938 0 0.0
.bss 36146 36146 0 0.0
.data 288 288 0 0.0
.text 101128 101128 0 0.0
telink lighting-app tlsr9518adk80d (read/write) 832258 833330 1072 0.1
bss 87088 87096 8 0.0
noinit 37160 37160 0 0.0
text 580366 581238 872 0.2

@stale
Copy link

stale bot commented Dec 29, 2021

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@stale stale bot added the stale Stale issue or PR label Dec 29, 2021
@bzbarsky-apple bzbarsky-apple removed the stale Stale issue or PR label Dec 31, 2021
General changes:

1. Set the CurrentLevel attribute in all-clusters app to be NVM and
   default to 254.  This requires some YAML changes to expect the new
   value.
2. Remove the hardcoded setting of that attribute to 255 during boot
   in the ESP32 all-clusters app.
3. Define and implement AttributePersistenceProvider to read/write persistent
   attributes.
4. Fix bug in ServerStorageDelegate::SyncGetKeyValue: it was not setting the
   size outparam to the actual size read.
5. Move EmberAfAttributeMetadata and a few functions for working with
   strings into a new header that can be included in places where
   generated headers (which af.h and af-types.h include) can't be.
6. Add those functions to out mock attribute-storage to fix linking of
   some tests.  Fix mistyped "darwin" in gn files so the tests get run
   on Darwin too, not just on Linux.
7. Rearrange the logic in emAfLoadAttributeDefaults a bit: instead of
   loading the default value into the RAM store and then checking for
   a persisted value, check for a persisted value first (if the
   attribute might have one), and only look for a default value if
   there is no persisted value. This removes the need for a separate
   emAfLoadAttributesFromStorage pass (which made sense back when that
   code was all generated, but it's not anymore).
8. Fix emAfSaveAttributeToStorageIfNeeded to actually store the value.
@github-actions
Copy link

github-actions bot commented Jan 6, 2022

PR #13172: Size comparison from 89b87f1 to 8b9a342

Increases above 0.2%:

platform target config section 89b87f1 8b9a342 change % change
linux thermostat-no-ble arm64 .got 3936 3952 16 0.4
Increases (22 builds for efr32, esp32, k32w, linux, nrfconnect, p6, qpg, telink)
platform target config section 89b87f1 8b9a342 change % change
efr32 lighting-app BRD4161A (read only) 829396 830464 1068 0.1
(read/write) 127068 127088 20 0.0
.bss 125192 125208 16 0.0
.text 829388 830456 1068 0.1
BRD4161A+rpc (read only) 816576 817644 1068 0.1
(read/write) 143736 143744 8 0.0
.bss 141760 141768 8 0.0
.text 816568 817636 1068 0.1
window-app BRD4161A (read only) 802844 803912 1068 0.1
(read/write) 126008 126024 16 0.0
.bss 124176 124192 16 0.0
.text 802836 803904 1068 0.1
esp32 all-clusters-app c3devkit (read only) 889178 890002 824 0.1
(read/write) 1313770 1313922 152 0.0
.dram0.bss 69288 69296 8 0.0
.flash.rodata 177184 177336 152 0.1
.flash.text 889178 890002 824 0.1
m5stack (read only) 949083 949951 868 0.1
(read/write) 445352 445512 160 0.0
.dram0.bss 73776 73792 16 0.0
.flash.rodata 206504 206648 144 0.1
.flash.text 943699 944567 868 0.1
k32w light k32w061+release (read/write) 648472 649248 776 0.1
.bss 76216 76232 16 0.0
.text 564552 565312 760 0.1
lock k32w061+release (read/write) 633296 634064 768 0.1
.bss 75928 75936 8 0.0
.text 549708 550468 760 0.1
linux chip-tool-ipv6only arm64 (read only) 7011468 7014860 3392 0.0
(read/write) 324849 325009 160 0.0
.bss 54209 54241 32 0.1
.data.rel.ro 208968 209064 96 0.0
.got 56888 56920 32 0.1
.rodata 383108 383508 400 0.1
.text 5936084 5938788 2704 0.0
thermostat-no-ble arm64 (read only) 2024348 2026876 2528 0.1
(read/write) 144049 144193 144 0.1
.bss 64001 64033 32 0.0
.data.rel.ro 72296 72392 96 0.1
.got 3936 3952 16 0.4
.rodata 128524 128844 320 0.2
.text 1683152 1685120 1968 0.1
nrfconnect lighting-app nrf52840dk_nrf52840 (read/write) 935763 936671 908 0.1
bss 118188 118200 12 0.0
rodata 108048 108220 172 0.2
text 631948 632696 748 0.1
nrf52840dk_nrf52840+rpc (read/write) 921187 922131 944 0.1
bss 115232 115244 12 0.0
rodata 100488 100664 176 0.2
text 627300 628048 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 846706 847634 928 0.1
bss 116080 116092 12 0.0
rodata 101220 101396 176 0.2
text 548888 549636 748 0.1
lock-app nrf52840dk_nrf52840 (read/write) 907875 908831 956 0.1
bss 117376 117388 12 0.0
rodata 103320 103492 172 0.2
text 609820 610568 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 819046 819986 940 0.1
bss 115296 115308 12 0.0
rodata 96544 96716 172 0.2
text 526796 527544 748 0.1
pump-app nrf52840dk_nrf52840 (read/write) 909151 910063 912 0.1
bss 117136 117148 12 0.0
rodata 103532 103708 176 0.2
text 611032 611780 748 0.1
pump-controller-app nrf52840dk_nrf52840 (read/write) 905987 906911 924 0.1
bss 117164 117176 12 0.0
rodata 102792 102964 172 0.2
text 608568 609316 748 0.1
p6 all-clusters-app default (read/write) 2401288 2402376 1088 0.0
.bss 116748 116764 16 0.0
.text 1359552 1360640 1088 0.1
light-app default (read/write) 2324568 2325640 1072 0.0
.bss 105872 105888 16 0.0
.text 1282832 1283904 1072 0.1
lock-app default (read/write) 2296768 2297840 1072 0.0
.bss 104752 104768 16 0.0
.text 1255032 1256104 1072 0.1
qpg lighting-app qpg6105+debug (read only) 531664 532424 760 0.1
.bss 86672 86688 16 0.0
.text 526344 527104 760 0.1
lock-app qpg6105+debug (read only) 503444 504204 760 0.2
.bss 85808 85824 16 0.0
.text 498124 498884 760 0.2
telink lighting-app tlsr9518adk80d (read/write) 832242 833298 1056 0.1
bss 86856 86864 8 0.0
text 580682 581554 872 0.2
Full report (26 builds for efr32, esp32, k32w, linux, nrfconnect, p6, qpg, telink)
platform target config section 89b87f1 8b9a342 change % change
efr32 lighting-app BRD4161A (read only) 829396 830464 1068 0.1
(read/write) 127068 127088 20 0.0
.bss 125192 125208 16 0.0
.data 1876 1876 0 0.0
.text 829388 830456 1068 0.1
BRD4161A+rpc (read only) 816576 817644 1068 0.1
(read/write) 143736 143744 8 0.0
.bss 141760 141768 8 0.0
.data 1976 1976 0 0.0
.text 816568 817636 1068 0.1
window-app BRD4161A (read only) 802844 803912 1068 0.1
(read/write) 126008 126024 16 0.0
.bss 124176 124192 16 0.0
.data 1832 1832 0 0.0
.text 802836 803904 1068 0.1
esp32 all-clusters-app c3devkit (read only) 889178 890002 824 0.1
(read/write) 1313770 1313922 152 0.0
.dram0.bss 69288 69296 8 0.0
.dram0.data 14236 14236 0 0.0
.flash.rodata 177184 177336 152 0.1
.flash.text 889178 890002 824 0.1
.iram0.text 62254 62254 0 0.0
m5stack (read only) 949083 949951 868 0.1
(read/write) 445352 445512 160 0.0
.dram0.bss 73776 73792 16 0.0
.dram0.data 34064 34064 0 0.0
.flash.rodata 206504 206648 144 0.1
.flash.text 943699 944567 868 0.1
.iram0.text 122671 122671 0 0.0
k32w light k32w061+release (read/write) 648472 649248 776 0.1
.bss 76216 76232 16 0.0
.data 1904 1904 0 0.0
.text 564552 565312 760 0.1
lock k32w061+release (read/write) 633296 634064 768 0.1
.bss 75928 75936 8 0.0
.data 1860 1860 0 0.0
.text 549708 550468 760 0.1
linux chip-tool-ipv6only arm64 (read only) 7011468 7014860 3392 0.0
(read/write) 324849 325009 160 0.0
.bss 54209 54241 32 0.1
.data 1096 1096 0 0.0
.data.rel.ro 208968 209064 96 0.0
.dynamic 560 560 0 0.0
.got 56888 56920 32 0.1
.init 24 24 0 0.0
.init_array 168 168 0 0.0
.rodata 383108 383508 400 0.1
.text 5936084 5938788 2704 0.0
thermostat-no-ble arm64 (read only) 2024348 2026876 2528 0.1
(read/write) 144049 144193 144 0.1
.bss 64001 64033 32 0.0
.data 880 880 0 0.0
.data.rel.ro 72296 72392 96 0.1
.dynamic 560 560 0 0.0
.got 3936 3952 16 0.4
.init 24 24 0 0.0
.init_array 296 296 0 0.0
.rodata 128524 128844 320 0.2
.text 1683152 1685120 1968 0.1
nrfconnect lighting-app nrf52840dk_nrf52840 (read/write) 935763 936671 908 0.1
bss 118188 118200 12 0.0
rodata 108048 108220 172 0.2
text 631948 632696 748 0.1
nrf52840dk_nrf52840+rpc (read/write) 921187 922131 944 0.1
bss 115232 115244 12 0.0
rodata 100488 100664 176 0.2
text 627300 628048 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 846706 847634 928 0.1
bss 116080 116092 12 0.0
rodata 101220 101396 176 0.2
text 548888 549636 748 0.1
lock-app nrf52840dk_nrf52840 (read/write) 907875 908831 956 0.1
bss 117376 117388 12 0.0
rodata 103320 103492 172 0.2
text 609820 610568 748 0.1
nrf5340dk_nrf5340_cpuapp (read/write) 819046 819986 940 0.1
bss 115296 115308 12 0.0
rodata 96544 96716 172 0.2
text 526796 527544 748 0.1
pigweed-app nrf52840dk_nrf52840 (read/write) 541835 541835 0 0.0
bss 52588 52588 0 0.0
rodata 50104 50104 0 0.0
text 376940 376940 0 0.0
pump-app nrf52840dk_nrf52840 (read/write) 909151 910063 912 0.1
bss 117136 117148 12 0.0
rodata 103532 103708 176 0.2
text 611032 611780 748 0.1
pump-controller-app nrf52840dk_nrf52840 (read/write) 905987 906911 924 0.1
bss 117164 117176 12 0.0
rodata 102792 102964 172 0.2
text 608568 609316 748 0.1
shell nrf52840dk_nrf52840 (read/write) 796843 796843 0 0.0
bss 109536 109536 0 0.0
rodata 78188 78188 0 0.0
text 532664 532664 0 0.0
nrf5340dk_nrf5340_cpuapp (read/write) 709670 709670 0 0.0
bss 107424 107424 0 0.0
rodata 72492 72492 0 0.0
text 450340 450340 0 0.0
p6 all-clusters-app default (read/write) 2401288 2402376 1088 0.0
.bss 116748 116764 16 0.0
.data 2592 2592 0 0.0
.text 1359552 1360640 1088 0.1
light-app default (read/write) 2324568 2325640 1072 0.0
.bss 105872 105888 16 0.0
.data 2384 2384 0 0.0
.text 1282832 1283904 1072 0.1
lock-app default (read/write) 2296768 2297840 1072 0.0
.bss 104752 104768 16 0.0
.data 2336 2336 0 0.0
.text 1255032 1256104 1072 0.1
qpg lighting-app qpg6105+debug (read only) 531664 532424 760 0.1
(read/write) 146936 146936 0 0.0
.bss 86672 86688 16 0.0
.data 1004 1004 0 0.0
.text 526344 527104 760 0.1
lock-app qpg6105+debug (read only) 503444 504204 760 0.2
(read/write) 146940 146940 0 0.0
.bss 85808 85824 16 0.0
.data 952 952 0 0.0
.text 498124 498884 760 0.2
persistent-storage-app qpg6105+debug (read only) 106448 106448 0 0.0
(read/write) 146938 146938 0 0.0
.bss 36146 36146 0 0.0
.data 288 288 0 0.0
.text 101128 101128 0 0.0
telink lighting-app tlsr9518adk80d (read/write) 832242 833298 1056 0.1
bss 86856 86864 8 0.0
noinit 37160 37160 0 0.0
text 580682 581554 872 0.2

@bzbarsky-apple bzbarsky-apple merged commit ec71346 into project-chip:master Jan 6, 2022
@bzbarsky-apple bzbarsky-apple deleted the attribute-persistence branch January 6, 2022 20:53
step0035 pushed a commit to hank820/connectedhomeip that referenced this pull request Feb 8, 2022
…ed. (project-chip#13172)

General changes:

1. Set the CurrentLevel attribute in all-clusters app to be NVM and
   default to 254.  This requires some YAML changes to expect the new
   value.
2. Remove the hardcoded setting of that attribute to 255 during boot
   in the ESP32 all-clusters app.
3. Define and implement AttributePersistenceProvider to read/write persistent
   attributes.
4. Fix bug in ServerStorageDelegate::SyncGetKeyValue: it was not setting the
   size outparam to the actual size read.
5. Move EmberAfAttributeMetadata and a few functions for working with
   strings into a new header that can be included in places where
   generated headers (which af.h and af-types.h include) can't be.
6. Add those functions to out mock attribute-storage to fix linking of
   some tests.  Fix mistyped "darwin" in gn files so the tests get run
   on Darwin too, not just on Linux.
7. Rearrange the logic in emAfLoadAttributeDefaults a bit: instead of
   loading the default value into the RAM store and then checking for
   a persisted value, check for a persisted value first (if the
   attribute might have one), and only look for a default value if
   there is no persisted value. This removes the need for a separate
   emAfLoadAttributesFromStorage pass (which made sense back when that
   code was all generated, but it's not anymore).
8. Fix emAfSaveAttributeToStorageIfNeeded to actually store the value.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants