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 Descriptor cluster when linking statically. #11392

Merged

Conversation

bzbarsky-apple
Copy link
Contributor

@bzbarsky-apple bzbarsky-apple commented Nov 3, 2021

Specific changes:

  1. Stop using weak symbols for cluster init callbacks. The way things
    are, if a cluster has no commands its file might not get linked at
    all (because the weak symbols satisfy the linker), and hence its
    init callback would never be called. This was hitting the
    Descriptor cluster.

  2. Add a bunch of no-op cluster init callbacks so we can link successfully.
    Add some files to the all-clusters-app link that were missing.

Fixes #11344

Problem

See #11344.

Change overview

See above.

Testing

  • Verified that manual attempts to read Descriptor from all-clusters-app running on m5stack work.

Note: This PR used to have changes to src/app/chip_data_model.gni to use static_library instead of source_set, but that fails to link ibCHIPAppServer.so on Android...

@github-actions
Copy link

github-actions bot commented Nov 3, 2021

PR #11392: Size comparison from 38fe11e to 9f4db8e

Increases above 0.2%:

platform target config section 38fe11e 9f4db8e change % change
linux all-clusters-app debug .rodata 139925 140373 448 0.3
bridge-app debug+rpc .data 1568 1584 16 1.0
lighting-app debug+rpc .data 1170 1202 32 2.7
ota-requestor-app debug .data 816 848 32 3.9
tv-app debug .data 2704 2736 32 1.2
qpg lighting-app qpg6100+debug .data 1004 1008 4 0.4
lock-app qpg6100+debug .data 960 968 8 0.8
Increases (22 builds for efr32, esp32, k32w, linux, nrfconnect, p6, qpg, telink)
platform target config section 38fe11e 9f4db8e change % change
efr32 lighting-app BRD4161A (read only) 737168 737184 16 0.0
.text 737160 737176 16 0.0
lock-app BRD4161A (read only) 716432 716464 32 0.0
.text 716424 716456 32 0.0
window-app BRD4161A (read only) 717332 717364 32 0.0
(read/write) 112724 112728 4 0.0
.data 1720 1724 4 0.2
.text 717324 717356 32 0.0
esp32 all-clusters-app c3devkit (read only) 880670 882334 1664 0.2
(read/write) 1308064 1308320 256 0.0
.dram0.bss 58584 58616 32 0.1
.dram0.data 16464 16472 8 0.0
.flash.rodata 199776 199984 208 0.1
.flash.text 880670 882334 1664 0.2
.iram0.text 57554 57564 10 0.0
m5stack (read only) 911823 913111 1288 0.1
.dram0.bss 61088 61128 40 0.1
.dram0.data 32100 32108 8 0.0
.flash.text 911823 913111 1288 0.1
k32w lighting-app k32w061+se05x+release (read/write) 699416 699540 124 0.0
.bss 77824 77836 12 0.0
.data 1904 1908 4 0.2
.text 613888 613996 108 0.0
shell k32w061+debug (read/write) 657656 657676 20 0.0
.bss 78992 79000 8 0.0
.text 571024 571036 12 0.0
linux all-clusters-app debug (read only) 1691153 1691601 448 0.0
.rodata 139925 140373 448 0.3
bridge-app debug+rpc (read only) 1287373 1287397 24 0.0
.data 1568 1584 16 1.0
.rodata 111460 111468 8 0.0
.text 1080021 1080037 16 0.0
lighting-app debug+rpc (read/write) 102288 102336 48 0.0
.data 1170 1202 32 2.7
.data.rel.ro 55168 55200 32 0.1
ota-requestor-app debug .data 816 848 32 3.9
tv-app debug .data 2704 2736 32 1.2
nrfconnect lighting-app nrf52840dk_nrf52840 (read/write) 861379 861395 16 0.0
text 577712 577716 4 0.0
nrf52840dk_nrf52840+rpc (read/write) 823755 823771 16 0.0
text 551896 551900 4 0.0
nrf5340dk_nrf5340_cpuapp text 507168 507172 4 0.0
lock-app nrf52840dk_nrf52840 (read/write) 838083 838099 16 0.0
text 559188 559196 8 0.0
nrf5340dk_nrf5340_cpuapp (read/write) 763382 763398 16 0.0
text 488736 488748 12 0.0
pump-controller-app nrf52840dk_nrf52840 text 558924 558932 8 0.0
p6 lock-app default (read/write) 2213648 2213680 32 0.0
.text 1171912 1171944 32 0.0
qpg lighting-app qpg6100+debug (read only) 490708 490824 116 0.0
(read/write) 114140 114144 4 0.0
.data 1004 1008 4 0.4
.text 485388 485504 116 0.0
lock-app qpg6100+debug (read only) 467048 467052 4 0.0
.data 960 968 8 0.8
.text 461728 461732 4 0.0
telink lighting-app tlsr9518adk80d (read/write) 662894 662902 8 0.0
text 458058 458062 4 0.0
Decreases (12 builds for efr32, esp32, linux, mbed, nrfconnect, p6)
platform target config section 38fe11e 9f4db8e change % change
efr32 lighting-app BRD4161A (read/write) 114588 114580 -8 -0.0
.data 1756 1752 -4 -0.2
esp32 all-clusters-app m5stack (read/write) 427828 425600 -2228 -0.5
.flash.rodata 208476 206200 -2276 -1.1
linux all-clusters-app debug (read/write) 119696 119664 -32 -0.0
.data 1042 1010 -32 -3.1
bridge-app debug+rpc .bss 35024 34992 -32 -0.1
chip-tool debug (read only) 4422981 4400613 -22368 -0.5
(read/write) 125888 124152 -1736 -1.4
.bss 18224 16520 -1704 -9.4
.data.rel.ro 100032 99984 -48 -0.0
.rodata 226384 222905 -3479 -1.5
.text 3928277 3909557 -18720 -0.5
lighting-app debug+rpc (read only) 1548401 1547561 -840 -0.1
.bss 40664 40656 -8 -0.0
.init_array 528 520 -8 -1.5
.rodata 130129 129393 -736 -0.6
.text 1284690 1284610 -80 -0.0
ota-provider-app debug (read only) 1243889 1236145 -7744 -0.6
(read/write) 67488 67392 -96 -0.1
.bss 37088 36992 -96 -0.3
.rodata 112456 111904 -552 -0.5
.text 1035330 1028162 -7168 -0.7
ota-requestor-app debug (read only) 1311169 1302817 -8352 -0.6
(read/write) 76808 76728 -80 -0.1
.bss 45344 45232 -112 -0.2
.rodata 123344 122859 -485 -0.4
.text 1090034 1082194 -7840 -0.7
tv-app debug (read only) 1810537 1790401 -20136 -1.1
(read/write) 289912 289608 -304 -0.1
.bss 222736 222528 -208 -0.1
.data.rel.ro 58824 58712 -112 -0.2
.got 4408 4392 -16 -0.4
.rodata 155528 154168 -1360 -0.9
.text 1512722 1494322 -18400 -1.2
mbed all-clusters-app CY8CPROTO_062_4343W+release (read/write) 2293160 2293096 -64 -0.0
.text 1255760 1255696 -64 -0.0
nrfconnect pump-app nrf52840dk_nrf52840 text 563368 563360 -8 -0.0
p6 all-clusters-app default (read/write) 2300656 2300576 -80 -0.0
.text 1258920 1258840 -80 -0.0
Full report (38 builds for efr32, esp32, k32w, linux, mbed, nrfconnect, p6, qpg, telink)
platform target config section 38fe11e 9f4db8e change % change
efr32 lighting-app BRD4161A (read only) 737168 737184 16 0.0
(read/write) 114588 114580 -8 -0.0
.bss 112828 112828 0 0.0
.data 1756 1752 -4 -0.2
.text 737160 737176 16 0.0
BRD4161A+rpc (read only) 726364 726364 0 0.0
(read/write) 131204 131204 0 0.0
.bss 129332 129332 0 0.0
.data 1872 1872 0 0.0
.text 726356 726356 0 0.0
lock-app BRD4161A (read only) 716432 716464 32 0.0
(read/write) 112404 112404 0 0.0
.bss 110684 110684 0 0.0
.data 1716 1716 0 0.0
.text 716424 716456 32 0.0
window-app BRD4161A (read only) 717332 717364 32 0.0
(read/write) 112724 112728 4 0.0
.bss 111004 111004 0 0.0
.data 1720 1724 4 0.2
.text 717324 717356 32 0.0
esp32 all-clusters-app c3devkit (read only) 880670 882334 1664 0.2
(read/write) 1308064 1308320 256 0.0
.dram0.bss 58584 58616 32 0.1
.dram0.data 16464 16472 8 0.0
.flash.rodata 199776 199984 208 0.1
.flash.text 880670 882334 1664 0.2
.iram0.text 57554 57564 10 0.0
m5stack (read only) 911823 913111 1288 0.1
(read/write) 427828 425600 -2228 -0.5
.dram0.bss 61088 61128 40 0.1
.dram0.data 32100 32108 8 0.0
.flash.rodata 208476 206200 -2276 -1.1
.flash.text 911823 913111 1288 0.1
.iram0.text 125115 125115 0 0.0
k32w lighting-app k32w061+se05x+release (read/write) 699416 699540 124 0.0
.bss 77824 77836 12 0.0
.data 1904 1908 4 0.2
.text 613888 613996 108 0.0
lock-app k32w061+debug (read/write) 591724 591724 0 0.0
.bss 68340 68340 0 0.0
.data 1868 1868 0 0.0
.text 515716 515716 0 0.0
shell k32w061+debug (read/write) 657656 657676 20 0.0
.bss 78992 79000 8 0.0
.data 1840 1840 0 0.0
.text 571024 571036 12 0.0
linux all-clusters-app debug (read only) 1691153 1691601 448 0.0
(read/write) 119696 119664 -32 -0.0
.bss 51120 51120 0 0.0
.data 1042 1010 -32 -3.1
.data.rel.ro 62272 62272 0 0.0
.dynamic 592 592 0 0.0
.got 4088 4088 0 0.0
.init 27 27 0 0.0
.init_array 536 536 0 0.0
.rodata 139925 140373 448 0.3
.text 1417810 1417810 0 0.0
bridge-app debug+rpc (read only) 1287373 1287397 24 0.0
(read/write) 69320 69320 0 0.0
.bss 35024 34992 -32 -0.1
.data 1568 1584 16 1.0
.data.rel.ro 27768 27768 0 0.0
.dynamic 592 592 0 0.0
.got 3952 3952 0 0.0
.init 27 27 0 0.0
.init_array 400 400 0 0.0
.rodata 111460 111468 8 0.0
.text 1080021 1080037 16 0.0
chip-tool debug (read only) 4422981 4400613 -22368 -0.5
(read/write) 125888 124152 -1736 -1.4
.bss 18224 16520 -1704 -9.4
.data 2224 2224 0 0.0
.data.rel.ro 100032 99984 -48 -0.0
.dynamic 592 592 0 0.0
.got 4368 4368 0 0.0
.init 27 27 0 0.0
.init_array 424 424 0 0.0
.rodata 226384 222905 -3479 -1.5
.text 3928277 3909557 -18720 -0.5
lighting-app debug+rpc (read only) 1548401 1547561 -840 -0.1
(read/write) 102288 102336 48 0.0
.bss 40664 40656 -8 -0.0
.data 1170 1202 32 2.7
.data.rel.ro 55168 55200 32 0.1
.dynamic 608 608 0 0.0
.got 4112 4112 0 0.0
.init 27 27 0 0.0
.init_array 528 520 -8 -1.5
.rodata 130129 129393 -736 -0.6
.text 1284690 1284610 -80 -0.0
ota-provider-app debug (read only) 1243889 1236145 -7744 -0.6
(read/write) 67488 67392 -96 -0.1
.bss 37088 36992 -96 -0.3
.data 752 752 0 0.0
.data.rel.ro 24568 24568 0 0.0
.dynamic 592 592 0 0.0
.got 4016 4016 0 0.0
.init 27 27 0 0.0
.init_array 440 440 0 0.0
.rodata 112456 111904 -552 -0.5
.text 1035330 1028162 -7168 -0.7
ota-requestor-app debug (read only) 1311169 1302817 -8352 -0.6
(read/write) 76808 76728 -80 -0.1
.bss 45344 45232 -112 -0.2
.data 816 848 32 3.9
.data.rel.ro 25512 25512 0 0.0
.dynamic 592 592 0 0.0
.got 3984 3984 0 0.0
.init 27 27 0 0.0
.init_array 512 512 0 0.0
.rodata 123344 122859 -485 -0.4
.text 1090034 1082194 -7840 -0.7
shell debug (read only) 786641 786641 0 0.0
(read/write) 57600 57600 0 0.0
.bss 16040 16040 0 0.0
.data 242 242 0 0.0
.data.rel.ro 36816 36816 0 0.0
.dynamic 592 592 0 0.0
.got 3528 3528 0 0.0
.init 27 27 0 0.0
.init_array 336 336 0 0.0
.rodata 77839 77839 0 0.0
.text 607314 607314 0 0.0
tv-app debug (read only) 1810537 1790401 -20136 -1.1
(read/write) 289912 289608 -304 -0.1
.bss 222736 222528 -208 -0.1
.data 2704 2736 32 1.2
.data.rel.ro 58824 58712 -112 -0.2
.dynamic 592 592 0 0.0
.got 4408 4392 -16 -0.4
.init 27 27 0 0.0
.init_array 608 608 0 0.0
.rodata 155528 154168 -1360 -0.9
.text 1512722 1494322 -18400 -1.2
mbed all-clusters-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2293160 2293096 -64 -0.0
.bss 179940 179940 0 0.0
.data 5216 5216 0 0.0
.heap 851288 851288 0 0.0
.text 1255760 1255696 -64 -0.0
lighting-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2272728 2272728 0 0.0
.bss 171980 171980 0 0.0
.data 5568 5568 0 0.0
.heap 858896 858896 0 0.0
.text 1235328 1235328 0 0.0
lock-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2250448 2250448 0 0.0
.bss 170876 170876 0 0.0
.data 5560 5560 0 0.0
.heap 860008 860008 0 0.0
.text 1213048 1213048 0 0.0
pigweed-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 1139744 1139744 0 0.0
.bss 11752 11752 0 0.0
.data 4368 4368 0 0.0
.heap 1020328 1020328 0 0.0
.text 103128 103128 0 0.0
shell CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2048368 2048368 0 0.0
.bss 156224 156224 0 0.0
.data 4960 4960 0 0.0
.heap 875264 875264 0 0.0
.text 1010968 1010968 0 0.0
nrfconnect lighting-app nrf52840dk_nrf52840 (read/write) 861379 861395 16 0.0
bss 111288 111288 0 0.0
rodata 96772 96772 0 0.0
text 577712 577716 4 0.0
nrf52840dk_nrf52840+rpc (read/write) 823755 823771 16 0.0
bss 107640 107640 0 0.0
rodata 87948 87948 0 0.0
text 551896 551900 4 0.0
nrf5340dk_nrf5340_cpuapp (read/write) 786418 786418 0 0.0
bss 112664 112664 0 0.0
rodata 92028 92028 0 0.0
text 507168 507172 4 0.0
lock-app nrf52840dk_nrf52840 (read/write) 838083 838099 16 0.0
bss 110324 110324 0 0.0
rodata 93140 93140 0 0.0
text 559188 559196 8 0.0
nrf5340dk_nrf5340_cpuapp (read/write) 763382 763398 16 0.0
bss 111732 111732 0 0.0
rodata 88448 88448 0 0.0
text 488736 488748 12 0.0
pigweed-app nrf52840dk_nrf52840 (read/write) 497323 497323 0 0.0
bss 51824 51824 0 0.0
rodata 45776 45776 0 0.0
text 339436 339436 0 0.0
pump-app nrf52840dk_nrf52840 (read/write) 844195 844195 0 0.0
bss 110460 110460 0 0.0
rodata 94852 94852 0 0.0
text 563368 563360 -8 -0.0
pump-controller-app nrf52840dk_nrf52840 (read/write) 837955 837955 0 0.0
bss 110360 110360 0 0.0
rodata 93140 93140 0 0.0
text 558924 558932 8 0.0
shell nrf52840dk_nrf52840 (read/write) 775975 775975 0 0.0
bss 109080 109080 0 0.0
rodata 72412 72412 0 0.0
text 519904 519904 0 0.0
nrf5340dk_nrf5340_cpuapp (read/write) 691010 691010 0 0.0
bss 110060 110060 0 0.0
rodata 67052 67052 0 0.0
text 440496 440496 0 0.0
p6 all-clusters-app default (read/write) 2300656 2300576 -80 -0.0
.bss 107880 107880 0 0.0
.data 2520 2520 0 0.0
.heap 922944 922944 0 0.0
.text 1258920 1258840 -80 -0.0
lock-app default (read/write) 2213648 2213680 32 0.0
.bss 95680 95680 0 0.0
.data 2392 2392 0 0.0
.heap 935272 935272 0 0.0
.text 1171912 1171944 32 0.0
qpg lighting-app qpg6100+debug (read only) 490708 490824 116 0.0
(read/write) 114140 114144 4 0.0
.bss 50968 50968 0 0.0
.data 1004 1008 4 0.4
.text 485388 485504 116 0.0
lock-app qpg6100+debug (read only) 467048 467052 4 0.0
(read/write) 114144 114144 0 0.0
.bss 49912 49912 0 0.0
.data 960 968 8 0.8
.text 461728 461732 4 0.0
persistent-storage-app qpg6100+debug (read only) 153212 153212 0 0.0
(read/write) 114140 114140 0 0.0
.bss 18920 18920 0 0.0
.data 356 356 0 0.0
.text 147892 147892 0 0.0
telink lighting-app tlsr9518adk80d (read/write) 662894 662902 8 0.0
bss 69100 69100 0 0.0
noinit 33216 33216 0 0.0
text 458058 458062 4 0.0

Specific changes:

1) Stop using weak symbols for cluster init callbacks.  The way things
   are, if a cluster has no commands its file might not get linked at
   all (because the weak symbols satisfy the linker), and hence its
   init callback would never be called.  This was hitting the
   Descriptor cluster.

2) Add a bunch of no-op cluster init callbacks so we can link successfully.
   Add some files to the all-clusters-app link that were missing.

Fixes project-chip#11344
@bzbarsky-apple bzbarsky-apple force-pushed the fix-descriptor-static-link branch from 9f4db8e to 4417e56 Compare November 4, 2021 03:18
@github-actions
Copy link

github-actions bot commented Nov 4, 2021

PR #11392: Size comparison from ee7682d to 4417e56

Increases (20 builds for efr32, esp32, k32w, linux, nrfconnect, p6, qpg, telink)
platform target config section ee7682d 4417e56 change % change
efr32 lighting-app BRD4161A (read only) 737432 737448 16 0.0
.text 737424 737440 16 0.0
BRD4161A+rpc (read only) 726628 726644 16 0.0
.text 726620 726636 16 0.0
lock-app BRD4161A (read only) 716696 716728 32 0.0
.text 716688 716720 32 0.0
window-app BRD4161A (read only) 717612 717628 16 0.0
.text 717604 717620 16 0.0
esp32 all-clusters-app c3devkit (read only) 880890 882550 1660 0.2
(read/write) 1308120 1308376 256 0.0
.dram0.bss 58584 58616 32 0.1
.dram0.data 16464 16472 8 0.0
.flash.rodata 199832 200040 208 0.1
.flash.text 880890 882550 1660 0.2
.iram0.text 57554 57564 10 0.0
m5stack (read only) 912007 913335 1328 0.1
.dram0.bss 61088 61128 40 0.1
.dram0.data 32100 32108 8 0.0
.flash.text 912007 913335 1328 0.1
k32w lock-app k32w061+debug (read/write) 591956 591972 16 0.0
.text 515948 515964 16 0.0
linux all-clusters-app debug (read only) 1697761 1697777 16 0.0
.text 1423874 1423890 16 0.0
bridge-app debug+rpc (read only) 1292477 1292493 16 0.0
.text 1084805 1084821 16 0.0
lighting-app debug+rpc (read only) 1553505 1553521 16 0.0
.text 1289474 1289490 16 0.0
tv-app debug (read only) 1817113 1817129 16 0.0
.text 1518786 1518802 16 0.0
nrfconnect lighting-app nrf52840dk_nrf52840 text 577912 577916 4 0.0
nrf52840dk_nrf52840+rpc text 552100 552104 4 0.0
nrf5340dk_nrf5340_cpuapp text 507372 507376 4 0.0
lock-app nrf52840dk_nrf52840 (read/write) 838331 838347 16 0.0
text 559388 559400 12 0.0
nrf5340dk_nrf5340_cpuapp text 488940 488948 8 0.0
pump-controller-app nrf52840dk_nrf52840 (read/write) 838183 838199 16 0.0
text 559124 559136 12 0.0
p6 lock-app default (read/write) 2213928 2213944 16 0.0
.text 1172192 1172208 16 0.0
qpg lighting-app qpg6100+debug (read only) 490932 490948 16 0.0
.text 485612 485628 16 0.0
telink lighting-app tlsr9518adk80d text 458206 458210 4 0.0
Decreases (4 builds for esp32, mbed, nrfconnect, p6)
platform target config section ee7682d 4417e56 change % change
esp32 all-clusters-app m5stack (read/write) 427876 425648 -2228 -0.5
.flash.rodata 208524 206248 -2276 -1.1
mbed all-clusters-app CY8CPROTO_062_4343W+release (read/write) 2293328 2293264 -64 -0.0
.text 1255928 1255864 -64 -0.0
nrfconnect pump-app nrf52840dk_nrf52840 (read/write) 844439 844423 -16 -0.0
text 563568 563560 -8 -0.0
p6 all-clusters-app default (read/write) 2301080 2301000 -80 -0.0
.text 1259344 1259264 -80 -0.0
Full report (38 builds for efr32, esp32, k32w, linux, mbed, nrfconnect, p6, qpg, telink)
platform target config section ee7682d 4417e56 change % change
efr32 lighting-app BRD4161A (read only) 737432 737448 16 0.0
(read/write) 114588 114588 0 0.0
.bss 112828 112828 0 0.0
.data 1756 1756 0 0.0
.text 737424 737440 16 0.0
BRD4161A+rpc (read only) 726628 726644 16 0.0
(read/write) 131204 131204 0 0.0
.bss 129332 129332 0 0.0
.data 1872 1872 0 0.0
.text 726620 726636 16 0.0
lock-app BRD4161A (read only) 716696 716728 32 0.0
(read/write) 112404 112404 0 0.0
.bss 110684 110684 0 0.0
.data 1716 1716 0 0.0
.text 716688 716720 32 0.0
window-app BRD4161A (read only) 717612 717628 16 0.0
(read/write) 112724 112724 0 0.0
.bss 111004 111004 0 0.0
.data 1720 1720 0 0.0
.text 717604 717620 16 0.0
esp32 all-clusters-app c3devkit (read only) 880890 882550 1660 0.2
(read/write) 1308120 1308376 256 0.0
.dram0.bss 58584 58616 32 0.1
.dram0.data 16464 16472 8 0.0
.flash.rodata 199832 200040 208 0.1
.flash.text 880890 882550 1660 0.2
.iram0.text 57554 57564 10 0.0
m5stack (read only) 912007 913335 1328 0.1
(read/write) 427876 425648 -2228 -0.5
.dram0.bss 61088 61128 40 0.1
.dram0.data 32100 32108 8 0.0
.flash.rodata 208524 206248 -2276 -1.1
.flash.text 912007 913335 1328 0.1
.iram0.text 125115 125115 0 0.0
k32w lighting-app k32w061+se05x+release (read/write) 699648 699648 0 0.0
.bss 77824 77824 0 0.0
.data 1904 1904 0 0.0
.text 614120 614120 0 0.0
lock-app k32w061+debug (read/write) 591956 591972 16 0.0
.bss 68340 68340 0 0.0
.data 1868 1868 0 0.0
.text 515948 515964 16 0.0
shell k32w061+debug (read/write) 657904 657904 0 0.0
.bss 78992 78992 0 0.0
.data 1840 1840 0 0.0
.text 571272 571272 0 0.0
linux all-clusters-app debug (read only) 1697761 1697777 16 0.0
(read/write) 119696 119696 0 0.0
.bss 51120 51120 0 0.0
.data 1042 1042 0 0.0
.data.rel.ro 62272 62272 0 0.0
.dynamic 592 592 0 0.0
.got 4088 4088 0 0.0
.init 27 27 0 0.0
.init_array 536 536 0 0.0
.rodata 140469 140469 0 0.0
.text 1423874 1423890 16 0.0
bridge-app debug+rpc (read only) 1292477 1292493 16 0.0
(read/write) 69320 69320 0 0.0
.bss 35024 35024 0 0.0
.data 1568 1568 0 0.0
.data.rel.ro 27768 27768 0 0.0
.dynamic 592 592 0 0.0
.got 3952 3952 0 0.0
.init 27 27 0 0.0
.init_array 400 400 0 0.0
.rodata 111780 111780 0 0.0
.text 1084805 1084821 16 0.0
chip-tool debug (read only) 4429253 4429253 0 0.0
(read/write) 125888 125888 0 0.0
.bss 18224 18224 0 0.0
.data 2224 2224 0 0.0
.data.rel.ro 100032 100032 0 0.0
.dynamic 592 592 0 0.0
.got 4368 4368 0 0.0
.init 27 27 0 0.0
.init_array 424 424 0 0.0
.rodata 226992 226992 0 0.0
.text 3933941 3933941 0 0.0
lighting-app debug+rpc (read only) 1553505 1553521 16 0.0
(read/write) 102288 102288 0 0.0
.bss 40664 40664 0 0.0
.data 1170 1170 0 0.0
.data.rel.ro 55168 55168 0 0.0
.dynamic 608 608 0 0.0
.got 4112 4112 0 0.0
.init 27 27 0 0.0
.init_array 528 528 0 0.0
.rodata 130449 130449 0 0.0
.text 1289474 1289490 16 0.0
ota-provider-app debug (read only) 1251761 1251761 0 0.0
(read/write) 67488 67488 0 0.0
.bss 37088 37088 0 0.0
.data 752 752 0 0.0
.data.rel.ro 24568 24568 0 0.0
.dynamic 592 592 0 0.0
.got 4016 4016 0 0.0
.init 27 27 0 0.0
.init_array 440 440 0 0.0
.rodata 113032 113032 0 0.0
.text 1042626 1042626 0 0.0
ota-requestor-app debug (read only) 1329497 1329497 0 0.0
(read/write) 76744 76744 0 0.0
.bss 45216 45216 0 0.0
.data 816 816 0 0.0
.data.rel.ro 25576 25576 0 0.0
.dynamic 592 592 0 0.0
.got 3992 3992 0 0.0
.init 27 27 0 0.0
.init_array 512 512 0 0.0
.rodata 124464 124464 0 0.0
.text 1106978 1106978 0 0.0
shell debug (read only) 786641 786641 0 0.0
(read/write) 57600 57600 0 0.0
.bss 16040 16040 0 0.0
.data 242 242 0 0.0
.data.rel.ro 36816 36816 0 0.0
.dynamic 592 592 0 0.0
.got 3528 3528 0 0.0
.init 27 27 0 0.0
.init_array 336 336 0 0.0
.rodata 77839 77839 0 0.0
.text 607314 607314 0 0.0
tv-app debug (read only) 1817113 1817129 16 0.0
(read/write) 289912 289912 0 0.0
.bss 222736 222736 0 0.0
.data 2704 2704 0 0.0
.data.rel.ro 58824 58824 0 0.0
.dynamic 592 592 0 0.0
.got 4408 4408 0 0.0
.init 27 27 0 0.0
.init_array 608 608 0 0.0
.rodata 156040 156040 0 0.0
.text 1518786 1518802 16 0.0
mbed all-clusters-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2293328 2293264 -64 -0.0
.bss 179940 179940 0 0.0
.data 5216 5216 0 0.0
.heap 851288 851288 0 0.0
.text 1255928 1255864 -64 -0.0
lighting-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2272760 2272760 0 0.0
.bss 171980 171980 0 0.0
.data 5568 5568 0 0.0
.heap 858896 858896 0 0.0
.text 1235360 1235360 0 0.0
lock-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2250480 2250480 0 0.0
.bss 170876 170876 0 0.0
.data 5560 5560 0 0.0
.heap 860008 860008 0 0.0
.text 1213080 1213080 0 0.0
pigweed-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 1139744 1139744 0 0.0
.bss 11752 11752 0 0.0
.data 4368 4368 0 0.0
.heap 1020328 1020328 0 0.0
.text 103128 103128 0 0.0
shell CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2048368 2048368 0 0.0
.bss 156224 156224 0 0.0
.data 4960 4960 0 0.0
.heap 875264 875264 0 0.0
.text 1010968 1010968 0 0.0
nrfconnect lighting-app nrf52840dk_nrf52840 (read/write) 861623 861623 0 0.0
bss 111288 111288 0 0.0
rodata 96808 96808 0 0.0
text 577912 577916 4 0.0
nrf52840dk_nrf52840+rpc (read/write) 824003 824003 0 0.0
bss 107640 107640 0 0.0
rodata 87988 87988 0 0.0
text 552100 552104 4 0.0
nrf5340dk_nrf5340_cpuapp (read/write) 786662 786662 0 0.0
bss 112664 112664 0 0.0
rodata 92064 92064 0 0.0
text 507372 507376 4 0.0
lock-app nrf52840dk_nrf52840 (read/write) 838331 838347 16 0.0
bss 110324 110324 0 0.0
rodata 93180 93180 0 0.0
text 559388 559400 12 0.0
nrf5340dk_nrf5340_cpuapp (read/write) 763626 763626 0 0.0
bss 111732 111732 0 0.0
rodata 88484 88484 0 0.0
text 488940 488948 8 0.0
pigweed-app nrf52840dk_nrf52840 (read/write) 497323 497323 0 0.0
bss 51824 51824 0 0.0
rodata 45776 45776 0 0.0
text 339436 339436 0 0.0
pump-app nrf52840dk_nrf52840 (read/write) 844439 844423 -16 -0.0
bss 110460 110460 0 0.0
rodata 94888 94888 0 0.0
text 563568 563560 -8 -0.0
pump-controller-app nrf52840dk_nrf52840 (read/write) 838183 838199 16 0.0
bss 110360 110360 0 0.0
rodata 93176 93176 0 0.0
text 559124 559136 12 0.0
shell nrf52840dk_nrf52840 (read/write) 775975 775975 0 0.0
bss 109080 109080 0 0.0
rodata 72412 72412 0 0.0
text 519904 519904 0 0.0
nrf5340dk_nrf5340_cpuapp (read/write) 691010 691010 0 0.0
bss 110060 110060 0 0.0
rodata 67052 67052 0 0.0
text 440496 440496 0 0.0
p6 all-clusters-app default (read/write) 2301080 2301000 -80 -0.0
.bss 107880 107880 0 0.0
.data 2520 2520 0 0.0
.heap 922944 922944 0 0.0
.text 1259344 1259264 -80 -0.0
lock-app default (read/write) 2213928 2213944 16 0.0
.bss 95680 95680 0 0.0
.data 2392 2392 0 0.0
.heap 935272 935272 0 0.0
.text 1172192 1172208 16 0.0
qpg lighting-app qpg6100+debug (read only) 490932 490948 16 0.0
(read/write) 114140 114140 0 0.0
.bss 50968 50968 0 0.0
.data 1004 1004 0 0.0
.text 485612 485628 16 0.0
lock-app qpg6100+debug (read only) 467280 467280 0 0.0
(read/write) 114144 114144 0 0.0
.bss 49912 49912 0 0.0
.data 960 960 0 0.0
.text 461960 461960 0 0.0
persistent-storage-app qpg6100+debug (read only) 153212 153212 0 0.0
(read/write) 114140 114140 0 0.0
.bss 18920 18920 0 0.0
.data 356 356 0 0.0
.text 147892 147892 0 0.0
telink lighting-app tlsr9518adk80d (read/write) 663086 663086 0 0.0
bss 69100 69100 0 0.0
noinit 33216 33216 0 0.0
text 458206 458210 4 0.0

@andy31415 andy31415 merged commit abcae0d into project-chip:master Nov 4, 2021
@bzbarsky-apple bzbarsky-apple deleted the fix-descriptor-static-link branch November 4, 2021 17:37
woody-apple added a commit that referenced this pull request Nov 4, 2021
andy31415 added a commit to andy31415/connectedhomeip that referenced this pull request Nov 4, 2021
andy31415 added a commit that referenced this pull request Nov 4, 2021
bzbarsky-apple added a commit to bzbarsky-apple/connectedhomeip that referenced this pull request Nov 4, 2021
Specific changes:

1) Stop using weak symbols for cluster init callbacks.  The way things
   are, if a cluster has no commands its file might not get linked at
   all (because the weak symbols satisfy the linker), and hence its
   init callback would never be called.  This was hitting the
   Descriptor cluster.

2) Add a bunch of no-op cluster init callbacks so we can link successfully.
   Add some files to the all-clusters-app link that were missing.

Fixes project-chip#11344
bzbarsky-apple added a commit to bzbarsky-apple/connectedhomeip that referenced this pull request Nov 4, 2021
Specific changes:

1) Stop using weak symbols for cluster init callbacks.  The way things
   are, if a cluster has no commands its file might not get linked at
   all (because the weak symbols satisfy the linker), and hence its
   init callback would never be called.  This was hitting the
   Descriptor cluster.

2) Add a bunch of no-op cluster init callbacks so we can link successfully.
   Add some files to the all-clusters-app link that were missing.

Fixes project-chip#11344
PSONALl pushed a commit to PSONALl/connectedhomeip that referenced this pull request Dec 3, 2021
Specific changes:

1) Stop using weak symbols for cluster init callbacks.  The way things
   are, if a cluster has no commands its file might not get linked at
   all (because the weak symbols satisfy the linker), and hence its
   init callback would never be called.  This was hitting the
   Descriptor cluster.

2) Add a bunch of no-op cluster init callbacks so we can link successfully.
   Add some files to the all-clusters-app link that were missing.

Fixes project-chip#11344
PSONALl pushed a commit to PSONALl/connectedhomeip that referenced this pull request Dec 3, 2021
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.

Descriptor cluster broken on esp32 (and probably other platforms that use static linking)
4 participants