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

Use Matter{{clusterName}}PluginServerInitCallback instead of the per endpoint init callback for diagnostics related cluster AttributeAccessInterface instance #10938

Conversation

vivien-apple
Copy link
Contributor

Problem

Diagnostics clusters uses the per endpoint init callback instead of the cluster "plugin" callback. Because of this they need to check against a static bool to make sure to not register the AttributeAccessInterface twice.

Change overview

  • Use Matter{{clusterName}}PluginServerInitCallback instead of the per-endpoint callback

@github-actions
Copy link

github-actions bot commented Oct 26, 2021

PR #10938: Size comparison from 93fef33 to 94bbfa2

8 builds (for k32w, p6, qpg, telink)
platform target config section 93fef33 94bbfa2 change % change
k32w lock-app k32w061+debug .bss 69196 69180 -16 -0.0
.data 1864 1864 0 0.0
.text 515140 515024 -116 -0.0
shell k32w061+debug .bss 63256 63256 0 0.0
.data 672 672 0 0.0
.text 359572 359572 0 0.0
lighting-app k32w061+se05x+release .bss 78712 78688 -24 -0.0
.data 1900 1900 0 0.0
.text 613776 613660 -116 -0.0
p6 lock-app default .bss 67176 67160 -16 -0.0
.data 2416 2416 0 0.0
.heap 963752 963768 16 0.0
.text 1126088 1125976 -112 -0.0
qpg lighting-app qpg6100+debug .bss 52416 52400 -16 -0.0
.data 1000 1000 0 0.0
.text 485044 484912 -132 -0.0
lock-app qpg6100+debug .bss 51360 51344 -16 -0.0
.data 956 956 0 0.0
.text 461264 461132 -132 -0.0
persistent-storage-app qpg6100+debug .bss 27752 27752 0 0.0
.data 372 372 0 0.0
.text 149900 149900 0 0.0
telink lighting-app tlsr9518adk80d bss 69940 69940 0 0.0
noinit 33216 33216 0 0.0
text 457672 457482 -190 -0.0
12 builds (for efr32, linux)
platform target config section 93fef33 94bbfa2 change % change
efr32 lighting-app BRD4161A .bss 113684 113668 -16 -0.0
.data 1752 1752 0 0.0
.text 735816 735696 -120 -0.0
lock-app BRD4161A .bss 111540 111524 -16 -0.0
.data 1712 1712 0 0.0
.text 715080 714960 -120 -0.0
window-app BRD4161A .bss 111852 111836 -16 -0.0
.data 1716 1716 0 0.0
.text 715876 715756 -120 -0.0
lighting-app BRD4161A+rpc .bss 130188 130172 -16 -0.0
.data 1852 1852 0 0.0
.text 723232 723120 -112 -0.0
linux all-clusters-app debug .bss 50160 50160 0 0.0
.data 978 978 0 0.0
.data.rel.ro 60640 60592 -48 -0.1
.dynamic 592 592 0 0.0
.got 4088 4088 0 0.0
.init 27 27 0 0.0
.init_array 512 512 0 0.0
.rodata 134517 134517 0 0.0
.text 1354018 1353794 -224 -0.0
chip-tool debug .bss 17680 17680 0 0.0
.data 1584 1584 0 0.0
.data.rel.ro 94624 94624 0 0.0
.dynamic 592 592 0 0.0
.got 4368 4368 0 0.0
.init 27 27 0 0.0
.init_array 416 416 0 0.0
.rodata 207396 207396 0 0.0
.text 3624245 3624245 0 0.0
ota-provider-app debug .bss 37440 37440 0 0.0
.data 752 752 0 0.0
.data.rel.ro 24488 24488 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 110344 110344 0 0.0
.text 1023714 1023714 0 0.0
ota-requestor-app debug .bss 205696 205696 0 0.0
.data 752 752 0 0.0
.data.rel.ro 25832 25832 0 0.0
.dynamic 592 592 0 0.0
.got 4144 4144 0 0.0
.init 27 27 0 0.0
.init_array 512 512 0 0.0
.rodata 128424 128424 0 0.0
.text 1142146 1142146 0 0.0
shell debug .bss 16136 16136 0 0.0
.data 242 242 0 0.0
.data.rel.ro 36496 36496 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 76495 76495 0 0.0
.text 599458 599458 0 0.0
tv-app debug .bss 215536 215536 0 0.0
.data 2032 2032 0 0.0
.data.rel.ro 57424 57392 -32 -0.1
.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 152072 152072 0 0.0
.text 1454338 1454114 -224 -0.0
bridge-app debug+rpc .bss 51856 51856 0 0.0
.data 976 976 0 0.0
.data.rel.ro 27112 27064 -48 -0.2
.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 109740 109740 0 0.0
.text 1064293 1064069 -224 -0.0
lighting-app debug+rpc .bss 41176 41176 0 0.0
.data 1106 1106 0 0.0
.data.rel.ro 53808 53776 -32 -0.1
.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 126897 126897 0 0.0
.text 1262178 1261954 -224 -0.0
14 builds (for mbed, nrfconnect)
platform target config section 93fef33 94bbfa2 change % change
mbed all-clusters-app CY8CPROTO_062_4343W+release .bss 179596 179580 -16 -0.0
.data 5192 5192 0 0.0
.heap 851656 851672 16 0.0
.text 1251216 1251064 -152 -0.0
lighting-app CY8CPROTO_062_4343W+release .bss 171060 171044 -16 -0.0
.data 5464 5464 0 0.0
.heap 859920 859936 16 0.0
.text 1219256 1219104 -152 -0.0
lock-app CY8CPROTO_062_4343W+release .bss 169980 169964 -16 -0.0
.data 5432 5432 0 0.0
.heap 861032 861048 16 0.0
.text 1197280 1197136 -144 -0.0
pigweed-app CY8CPROTO_062_4343W+release .bss 11760 11760 0 0.0
.data 4360 4360 0 0.0
.heap 1020328 1020328 0 0.0
.text 103064 103064 0 0.0
nrfconnect lighting-app nrf52840dk_nrf52840 bss 112136 112132 -4 -0.0
rodata 97100 97080 -20 -0.0
text 577204 577104 -100 -0.0
lock-app nrf52840dk_nrf52840 bss 111208 111200 -8 -0.0
rodata 93500 93480 -20 -0.0
text 558764 558664 -100 -0.0
pigweed-app nrf52840dk_nrf52840 bss 51824 51824 0 0.0
rodata 45776 45776 0 0.0
text 339456 339456 0 0.0
pump-app nrf52840dk_nrf52840 bss 111308 111304 -4 -0.0
rodata 94700 94680 -20 -0.0
text 561868 561768 -100 -0.0
pump-controller-app nrf52840dk_nrf52840 bss 111204 111200 -4 -0.0
rodata 93476 93456 -20 -0.0
text 558508 558408 -100 -0.0
shell nrf52840dk_nrf52840 bss 109072 109072 0 0.0
rodata 72536 72536 0 0.0
text 520324 520324 0 0.0
lighting-app nrf52840dk_nrf52840+rpc bss 108376 108372 -4 -0.0
rodata 87876 87856 -20 -0.0
text 550396 550296 -100 -0.0
nrf5340dk_nrf5340_cpuapp bss 113508 113504 -4 -0.0
rodata 92340 92320 -20 -0.0
text 506676 506576 -100 -0.0
lock-app nrf5340dk_nrf5340_cpuapp bss 112580 112576 -4 -0.0
rodata 88760 88740 -20 -0.0
text 488228 488128 -100 -0.0
shell nrf5340dk_nrf5340_cpuapp bss 110056 110056 0 0.0
rodata 67180 67180 0 0.0
text 440936 440936 0 0.0
2 builds (for esp32)
platform target config section 93fef33 94bbfa2 change % change
esp32 all-clusters-app c3devkit .dram0.bss 58232 58208 -24 -0.0
.dram0.data 16464 16440 -24 -0.1
.flash.rodata 198048 198024 -24 -0.0
.flash.text 874382 873498 -884 -0.1
.iram0.text 57564 57554 -10 -0.0
m5stack .dram0.bss 60736 60704 -32 -0.1
.dram0.data 32084 32084 0 0.0
.flash.rodata 206808 206764 -44 -0.0
.flash.text 905451 904775 -676 -0.1
.iram0.text 125115 125115 0 0.0

@pullapprove pullapprove bot requested a review from selissia October 26, 2021 07:48
@vivien-apple vivien-apple force-pushed the Clusters_AttributeAccessInterfaceIntoPluginInit branch from 94bbfa2 to 85611ac Compare October 26, 2021 08:04
@github-actions
Copy link

github-actions bot commented Oct 26, 2021

PR #10938: Size comparison from 341c00d to 85611ac

8 builds (for k32w, p6, qpg, telink)
platform target config section 341c00d 85611ac change % change
k32w lock-app k32w061+debug .bss 69196 69172 -24 -0.0
.data 1864 1864 0 0.0
.text 515140 515008 -132 -0.0
shell k32w061+debug .bss 63256 63256 0 0.0
.data 672 672 0 0.0
.text 359572 359572 0 0.0
lighting-app k32w061+se05x+release .bss 78712 78680 -32 -0.0
.data 1900 1900 0 0.0
.text 613776 613644 -132 -0.0
p6 lock-app default .bss 67176 67160 -16 -0.0
.data 2416 2416 0 0.0
.heap 963752 963768 16 0.0
.text 1126088 1125960 -128 -0.0
qpg lighting-app qpg6100+debug .bss 52416 52400 -16 -0.0
.data 1000 1000 0 0.0
.text 485044 484896 -148 -0.0
lock-app qpg6100+debug .bss 51360 51344 -16 -0.0
.data 956 956 0 0.0
.text 461264 461116 -148 -0.0
persistent-storage-app qpg6100+debug .bss 27752 27752 0 0.0
.data 372 372 0 0.0
.text 149900 149900 0 0.0
telink lighting-app tlsr9518adk80d bss 69940 69940 0 0.0
noinit 33216 33216 0 0.0
text 457672 457448 -224 -0.0
4 builds (for efr32)
platform target config section 341c00d 85611ac change % change
efr32 lighting-app BRD4161A .bss 113684 113668 -16 -0.0
.data 1752 1752 0 0.0
.text 735816 735680 -136 -0.0
lock-app BRD4161A .bss 111540 111524 -16 -0.0
.data 1712 1712 0 0.0
.text 715080 714944 -136 -0.0
window-app BRD4161A .bss 111852 111836 -16 -0.0
.data 1716 1716 0 0.0
.text 715876 715740 -136 -0.0
lighting-app BRD4161A+rpc .bss 130188 130172 -16 -0.0
.data 1852 1852 0 0.0
.text 723232 723104 -128 -0.0
4 builds (for mbed)
platform target config section 341c00d 85611ac change % change
mbed all-clusters-app CY8CPROTO_062_4343W+release .bss 179604 179580 -24 -0.0
.data 5192 5192 0 0.0
.heap 851648 851672 24 0.0
.text 1251552 1251400 -152 -0.0
lighting-app CY8CPROTO_062_4343W+release .bss 171060 171036 -24 -0.0
.data 5464 5464 0 0.0
.heap 859920 859944 24 0.0
.text 1219256 1219104 -152 -0.0
lock-app CY8CPROTO_062_4343W+release .bss 169980 169956 -24 -0.0
.data 5432 5432 0 0.0
.heap 861032 861056 24 0.0
.text 1197280 1197136 -144 -0.0
pigweed-app CY8CPROTO_062_4343W+release .bss 11760 11760 0 0.0
.data 4360 4360 0 0.0
.heap 1020328 1020328 0 0.0
.text 103064 103064 0 0.0
12 builds (for esp32, nrfconnect)
platform target config section 341c00d 85611ac change % change
esp32 all-clusters-app c3devkit .dram0.bss 58232 58208 -24 -0.0
.dram0.data 16464 16440 -24 -0.1
.flash.rodata 198072 198040 -32 -0.0
.flash.text 874742 873854 -888 -0.1
.iram0.text 57564 57554 -10 -0.0
m5stack .dram0.bss 60744 60704 -40 -0.1
.dram0.data 32084 32084 0 0.0
.flash.rodata 206832 206780 -52 -0.0
.flash.text 905895 905119 -776 -0.1
.iram0.text 125115 125115 0 0.0
nrfconnect lighting-app nrf52840dk_nrf52840 bss 112136 112128 -8 -0.0
rodata 97100 97080 -20 -0.0
text 577204 577088 -116 -0.0
lock-app nrf52840dk_nrf52840 bss 111208 111200 -8 -0.0
rodata 93500 93480 -20 -0.0
text 558764 558648 -116 -0.0
pigweed-app nrf52840dk_nrf52840 bss 51824 51824 0 0.0
rodata 45776 45776 0 0.0
text 339456 339456 0 0.0
pump-app nrf52840dk_nrf52840 bss 111308 111300 -8 -0.0
rodata 94700 94680 -20 -0.0
text 561868 561752 -116 -0.0
pump-controller-app nrf52840dk_nrf52840 bss 111204 111200 -4 -0.0
rodata 93476 93456 -20 -0.0
text 558508 558392 -116 -0.0
shell nrf52840dk_nrf52840 bss 109072 109072 0 0.0
rodata 72536 72536 0 0.0
text 520324 520324 0 0.0
lighting-app nrf52840dk_nrf52840+rpc bss 108376 108372 -4 -0.0
rodata 87876 87856 -20 -0.0
text 550396 550280 -116 -0.0
nrf5340dk_nrf5340_cpuapp bss 113508 113504 -4 -0.0
rodata 92340 92320 -20 -0.0
text 506676 506560 -116 -0.0
lock-app nrf5340dk_nrf5340_cpuapp bss 112580 112576 -4 -0.0
rodata 88760 88740 -20 -0.0
text 488228 488112 -116 -0.0
shell nrf5340dk_nrf5340_cpuapp bss 110056 110056 0 0.0
rodata 67180 67180 0 0.0
text 440936 440936 0 0.0

…endpoint init callback for diagnostics related cluster AttributeAccessInterface instance
@vivien-apple vivien-apple force-pushed the Clusters_AttributeAccessInterfaceIntoPluginInit branch from 85611ac to 219ecdc Compare October 26, 2021 09:33
@github-actions
Copy link

Size increase report for "gn_qpg-example-build" from 62a6f85

File Section File VM
chip-qpg6100-lighting-example.out .heap 0 16
chip-qpg6100-lighting-example.out .bss 0 -16
chip-qpg6100-lighting-example.out .text -148 -148
Full report output
BLOAT REPORT

Files found only in the build output:
    report.csv

Comparing ./master_artifact/chip-qpg6100-lighting-example.out.map and ./pull_artifact/chip-qpg6100-lighting-example.out.map:

BLOAT EXECUTION FAILED WITH CODE 1:
bloaty: unknown file type for file './pull_artifact/chip-qpg6100-lighting-example.out.map'

Comparing ./master_artifact/chip-qpg6100-lighting-example.out and ./pull_artifact/chip-qpg6100-lighting-example.out:

sections,vmsize,filesize
[Unmapped],0,148
.heap,16,0
.shstrtab,0,2
.bss,-16,0
.debug_frame,0,-48
.debug_abbrev,0,-111
.text,-148,-148
.debug_line,0,-162
.debug_loc,0,-185
.debug_info,0,-304
.symtab,0,-528
.debug_str,0,-682
.strtab,0,-1022


@github-actions
Copy link

Size increase report for "esp32-example-build" from 62a6f85

File Section File VM
chip-all-clusters-app.elf .iram0.text_end 0 10
chip-all-clusters-app.elf .dram0.heap_start 0 -8
chip-all-clusters-app.elf .iram0.text -10 -10
chip-all-clusters-app.elf .dram0.bss 0 -24
chip-all-clusters-app.elf .dram0.data -24 -16
chip-all-clusters-app.elf .flash.rodata -32 -32
chip-all-clusters-app.elf .flash.text -888 -888
Full report output
BLOAT REPORT

Files found only in the build output:
    report.csv

Comparing ./master_artifact/chip-all-clusters-app.elf and ./pull_artifact/chip-all-clusters-app.elf:

sections,vmsize,filesize
[Unmapped],0,954
.iram0.text_end,10,0
.shstrtab,0,2
.riscv.attributes,0,-2
.dram0.heap_start,-8,0
.iram0.text,-10,-10
.dram0.bss,-24,0
.dram0.data,-16,-24
.flash.rodata,-32,-32
.debug_aranges,0,-96
.debug_frame,0,-260
.symtab,0,-464
.debug_ranges,0,-480
.flash.text,-888,-888
.debug_str,0,-903
.strtab,0,-1670
.debug_loc,0,-2241
.debug_abbrev,0,-5730
.debug_line,0,-7271
.debug_info,0,-188325


@github-actions
Copy link

Size increase report for "nrfconnect-example-build" from 62a6f85

File Section File VM
chip-lock.elf device_handles 4 4
chip-lock.elf bss 0 -8
chip-lock.elf [LOAD #3 [RW]] 0 -24
chip-lock.elf rodata -24 -20
chip-lock.elf text -116 -116
Full report output
BLOAT REPORT

Files found only in the build output:
    report.csv

Comparing ./master_artifact/chip-shell.elf and ./pull_artifact/chip-shell.elf:

sections,vmsize,filesize

Comparing ./master_artifact/chip-lock.elf and ./pull_artifact/chip-lock.elf:

sections,vmsize,filesize
device_handles,4,4
.shstrtab,0,2
bss,-8,0
[LOAD #3 [RW]],-24,0
rodata,-20,-24
.debug_frame,0,-48
.debug_abbrev,0,-111
text,-116,-116
.debug_line,0,-161
.debug_loc,0,-190
.debug_info,0,-304
.symtab,0,-528
.debug_str,0,-682
.strtab,0,-1022


@bzbarsky-apple
Copy link
Contributor

@andy31415 andy31415 merged commit edc22bd into project-chip:master Oct 27, 2021
JasonLiuZhuoCheng pushed a commit to JasonLiuZhuoCheng/connectedhomeip that referenced this pull request Oct 28, 2021
…endpoint init callback for diagnostics related cluster AttributeAccessInterface instance (project-chip#10938)

* Use Matter{{clusterName}}PluginServerInitCallback instead of the per endpoint init callback for diagnostics related cluster AttributeAccessInterface instance

* Update generated content
carol-apple pushed a commit to carol-apple/connectedhomeip that referenced this pull request Oct 28, 2021
…endpoint init callback for diagnostics related cluster AttributeAccessInterface instance (project-chip#10938)

* Use Matter{{clusterName}}PluginServerInitCallback instead of the per endpoint init callback for diagnostics related cluster AttributeAccessInterface instance

* Update generated content
PSONALl pushed a commit to PSONALl/connectedhomeip that referenced this pull request Dec 3, 2021
…endpoint init callback for diagnostics related cluster AttributeAccessInterface instance (project-chip#10938)

* Use Matter{{clusterName}}PluginServerInitCallback instead of the per endpoint init callback for diagnostics related cluster AttributeAccessInterface instance

* Update generated content
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