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

Separate out AttributePathExpandIterator::Position #36980

Merged
merged 62 commits into from
Jan 10, 2025

Conversation

andy31415
Copy link
Contributor

@andy31415 andy31415 commented Jan 7, 2025

We currently iterate over attribute paths for wildcard expansion only (and an extra check for path validity). We do not require a full iterator (e.g. data model provider) unless actively iterating.

This PR splits AttributePathExpandIterator into actual iterator and position (which is used to resume an iteration). This saves some RAM (don't need to have DMProvider for example) and allows easier management/changes of this iterator in the future as we consider options for DM::Provider ineterfaces.

Testing

  • Unit tests updated and a lot of tests already cover this code (it is used in all Read/subscribe/chunk tests).
  • Added an explicit additional unit test that wildcard expansion checks path validity while non-wildcard does not (these were only previously hit during Read tests and those are slow and harder to debug)
  • checked with pahole and was unable to optimize ReadHandler more for size (it still reports 20 bytes padding, however I was unable to fix that no matter what I moved around - it either becomes a hole after mSessionHandle or becomes padding, regardless what I do ... not sure why)
  • checked with bloaty on a qpg-light build (as a small device) and it reports 0 or negative txt increase and a 160 bytes BSS saving. Other platforms still have some increase however quite small (given the large readability/maintainability updates here)

Copy link

semanticdiff-com bot commented Jan 7, 2025

Review changes with  SemanticDiff

Copy link

github-actions bot commented Jan 7, 2025

PR #36980: Size comparison from e7f6d0e to 652e389

Full report (11 builds for cc13x4_26x4, cc32xx, qpg, stm32, tizen)
platform target config section e7f6d0e 652e389 change % change
cc13x4_26x4 lighting-app LP_EM_CC1354P10_6 FLASH 840208 840320 112 0.0
RAM 123696 123696 0 0.0
lock-ftd LP_EM_CC1354P10_6 FLASH 825748 825852 104 0.0
RAM 125584 125584 0 0.0
pump-app LP_EM_CC1354P10_6 FLASH 772568 772680 112 0.0
RAM 114060 114060 0 0.0
pump-controller-app LP_EM_CC1354P10_6 FLASH 756748 756868 120 0.0
RAM 114260 114260 0 0.0
cc32xx air-purifier CC3235SF_LAUNCHXL FLASH 540049 540153 104 0.0
RAM 205800 205800 0 0.0
lock CC3235SF_LAUNCHXL FLASH 574217 574313 96 0.0
RAM 205944 205944 0 0.0
qpg lighting-app qpg6105+debug FLASH 664328 664416 88 0.0
RAM 105456 105456 0 0.0
lock-app qpg6105+debug FLASH 622156 622252 96 0.0
RAM 99908 99908 0 0.0
stm32 light STM32WB5MM-DK FLASH 485080 485192 112 0.0
RAM 144912 144912 0 0.0
tizen all-clusters-app arm unknown 5160 5160 0 0.0
FLASH 1780980 1781200 220 0.0
RAM 93684 93684 0 0.0
chip-tool-ubsan arm unknown 10844 10844 0 0.0
FLASH 17999086 18002158 3072 0.0
RAM 7855832 7857932 2100 0.0

src/app/AttributePathExpandIterator.cpp Outdated Show resolved Hide resolved
src/app/AttributePathExpandIterator.cpp Outdated Show resolved Hide resolved
src/app/AttributePathExpandIterator.cpp Outdated Show resolved Hide resolved
src/app/AttributePathExpandIterator.cpp Outdated Show resolved Hide resolved
src/app/AttributePathExpandIterator.cpp Outdated Show resolved Hide resolved
src/app/AttributePathExpandIterator.h Outdated Show resolved Hide resolved
src/app/InteractionModelEngine.cpp Outdated Show resolved Hide resolved
src/app/ReadHandler.h Outdated Show resolved Hide resolved
src/app/ReadHandler.h Outdated Show resolved Hide resolved
src/app/reporting/Engine.cpp Outdated Show resolved Hide resolved
@andy31415 andy31415 requested a review from a team as a code owner January 10, 2025 03:57
@andy31415 andy31415 force-pushed the attribute-path-expand-state branch from e3b7aba to e6b8003 Compare January 10, 2025 14:31
Copy link

PR #36980: Size comparison from e7082e2 to e6b8003

Full report (3 builds for cc32xx, stm32)
platform target config section e7082e2 e6b8003 change % change
cc32xx air-purifier CC3235SF_LAUNCHXL FLASH 540285 540301 16 0.0
RAM 205816 205304 -512 -0.2
lock CC3235SF_LAUNCHXL FLASH 574453 574461 8 0.0
RAM 205960 205448 -512 -0.2
stm32 light STM32WB5MM-DK FLASH 485136 485168 32 0.0
RAM 144912 144752 -160 -0.1

@andy31415 andy31415 removed the request for review from a team January 10, 2025 14:43
Copy link

github-actions bot commented Jan 10, 2025

PR #36980: Size comparison from b528132 to 9de15ec

Full report (70 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
platform target config section b528132 9de15ece change % change
bl602 lighting-app bl602+mfd+littlefs+rpc FLASH 1354946 1354962 16 0.0
RAM 104152 103960 -192 -0.2
bl702 lighting-app bl702+eth FLASH 726512 726580 68 0.0
RAM 25361 25361 0 0.0
bl702+wifi FLASH 913126 913194 68 0.0
RAM 14101 14101 0 0.0
bl706+mfd+rpc+littlefs FLASH 1173960 1174028 68 0.0
RAM 23941 23941 0 0.0
bl702l lighting-app bl702l+mfd+littlefs FLASH 1083028 1083096 68 0.0
RAM 16612 16612 0 0.0
cc13x4_26x4 lighting-app LP_EM_CC1354P10_6 FLASH 840400 840384 -16 -0.0
RAM 123712 123552 -160 -0.1
lock-ftd LP_EM_CC1354P10_6 FLASH 825932 825908 -24 -0.0
RAM 125600 125440 -160 -0.1
pump-app LP_EM_CC1354P10_6 FLASH 772836 772828 -8 -0.0
RAM 114076 113916 -160 -0.1
pump-controller-app LP_EM_CC1354P10_6 FLASH 757016 757000 -16 -0.0
RAM 114276 114116 -160 -0.1
cc32xx air-purifier CC3235SF_LAUNCHXL FLASH 540285 540269 -16 -0.0
RAM 205816 205304 -512 -0.2
lock CC3235SF_LAUNCHXL FLASH 574453 574429 -24 -0.0
RAM 205960 205448 -512 -0.2
cyw30739 light CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 681809 681793 -16 -0.0
RAM 78756 78596 -160 -0.2
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 701653 701637 -16 -0.0
RAM 81396 81236 -160 -0.2
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 701653 701637 -16 -0.0
RAM 81396 81236 -160 -0.2
CYW930739M2EVB-02 unknown 2040 2040 0 0.0
FLASH 658589 658573 -16 -0.0
RAM 73824 73664 -160 -0.2
light-switch CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 618425 618409 -16 -0.0
RAM 71748 71588 -160 -0.2
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 638053 638037 -16 -0.0
RAM 74292 74132 -160 -0.2
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 638053 638037 -16 -0.0
RAM 74292 74132 -160 -0.2
lock CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 637825 637801 -24 -0.0
RAM 74756 74596 -160 -0.2
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 657533 657517 -16 -0.0
RAM 77300 77140 -160 -0.2
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 657533 657517 -16 -0.0
RAM 77300 77140 -160 -0.2
thermostat CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 614445 614429 -16 -0.0
RAM 68844 68684 -160 -0.2
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 634297 634281 -16 -0.0
RAM 71476 71316 -160 -0.2
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 634297 634281 -16 -0.0
RAM 71476 71316 -160 -0.2
efr32 lock-app BRD4187C FLASH 932740 932708 -32 -0.0
RAM 160228 160068 -160 -0.1
BRD4338a FLASH 747208 747216 8 0.0
RAM 233356 233196 -160 -0.1
window-app BRD4187C FLASH 1025656 1025656 0 0.0
RAM 128332 128172 -160 -0.1
esp32 all-clusters-app c3devkit DRAM 95352 95192 -160 -0.2
FLASH 1541996 1541978 -18 -0.0
IRAM 82552 82552 0 0.0
m5stack DRAM 116332 116172 -160 -0.1
FLASH 1548246 1548362 116 0.0
IRAM 117039 117039 0 0.0
linux air-purifier-app debug unknown 4752 4752 0 0.0
FLASH 2731685 2731859 174 0.0
RAM 133160 133160 0 0.0
all-clusters-app debug unknown 5560 5560 0 0.0
FLASH 6020306 6020546 240 0.0
RAM 526008 526008 0 0.0
all-clusters-minimal-app debug unknown 5456 5456 0 0.0
FLASH 5356400 5356578 178 0.0
RAM 243072 243072 0 0.0
bridge-app debug unknown 5472 5472 0 0.0
FLASH 4704816 4705026 210 0.0
RAM 221824 221824 0 0.0
chip-tool debug unknown 5992 5992 0 0.0
FLASH 12938676 12938884 208 0.0
RAM 587002 587002 0 0.0
chip-tool-ipv6only arm64 unknown 21560 21560 0 0.0
FLASH 11053856 11054224 368 0.0
RAM 638064 638064 0 0.0
fabric-admin debug unknown 5816 5816 0 0.0
FLASH 11334801 11335009 208 0.0
RAM 587346 587346 0 0.0
fabric-bridge-app debug unknown 4728 4728 0 0.0
FLASH 4529968 4530176 208 0.0
RAM 208928 208928 0 0.0
fabric-sync debug unknown 4968 4968 0 0.0
FLASH 5641333 5641525 192 0.0
RAM 477880 477880 0 0.0
lighting-app debug+rpc+ui unknown 6136 6136 0 0.0
FLASH 5640945 5641169 224 0.0
RAM 232072 232072 0 0.0
lock-app debug unknown 5408 5408 0 0.0
FLASH 4753184 4753392 208 0.0
RAM 208072 208072 0 0.0
ota-provider-app debug unknown 4768 4768 0 0.0
FLASH 4379730 4379938 208 0.0
RAM 201744 201744 0 0.0
ota-requestor-app debug unknown 4720 4720 0 0.0
FLASH 4518638 4518846 208 0.0
RAM 206312 206312 0 0.0
shell debug unknown 4248 4248 0 0.0
FLASH 3037885 3038125 240 0.0
RAM 160792 160792 0 0.0
thermostat-no-ble arm64 unknown 9584 9584 0 0.0
FLASH 4120104 4120472 368 0.0
RAM 246384 246384 0 0.0
tv-app debug unknown 5736 5736 0 0.0
FLASH 5990677 5990869 192 0.0
RAM 601312 601312 0 0.0
tv-casting-app debug unknown 5320 5320 0 0.0
FLASH 11167325 11167501 176 0.0
RAM 700496 700496 0 0.0
nrfconnect all-clusters-app nrf52840dk_nrf52840 FLASH 918156 918140 -16 -0.0
RAM 143332 143172 -160 -0.1
nrf7002dk_nrf5340_cpuapp FLASH 890664 890708 44 0.0
RAM 141519 141359 -160 -0.1
all-clusters-minimal-app nrf52840dk_nrf52840 FLASH 852220 852204 -16 -0.0
RAM 142244 142084 -160 -0.1
nxp contact k32w0+release FLASH 586112 586064 -48 -0.0
RAM 71112 70952 -160 -0.2
mcxw71+release FLASH 601624 601584 -40 -0.0
RAM 63328 63168 -160 -0.3
light k32w0+release FLASH 612748 612732 -16 -0.0
RAM 70504 70344 -160 -0.2
k32w1+release FLASH 687384 687368 -16 -0.0
RAM 48920 48760 -160 -0.3
lock mcxw71+release FLASH 763704 763664 -40 -0.0
RAM 70956 70796 -160 -0.2
psoc6 all-clusters cy8ckit_062s2_43012 FLASH 1647684 1647700 16 0.0
RAM 212144 211632 -512 -0.2
all-clusters-minimal cy8ckit_062s2_43012 FLASH 1555316 1555348 32 0.0
RAM 208960 208448 -512 -0.2
light cy8ckit_062s2_43012 FLASH 1470420 1470452 32 0.0
RAM 200928 200416 -512 -0.3
lock cy8ckit_062s2_43012 FLASH 1468156 1468188 32 0.0
RAM 225280 224768 -512 -0.2
qpg lighting-app qpg6105+debug FLASH 664392 664344 -48 -0.0
RAM 105456 105296 -160 -0.2
lock-app qpg6105+debug FLASH 622204 622164 -40 -0.0
RAM 99908 99748 -160 -0.2
stm32 light STM32WB5MM-DK FLASH 485136 485136 0 0.0
RAM 144912 144752 -160 -0.1
telink bridge-app tlsr9258a FLASH 683698 683700 2 0.0
RAM 91248 91088 -160 -0.2
contact-sensor-app tlsr9528a_retention FLASH 623938 623954 16 0.0
RAM 31488 31488 0 0.0
light-app-ota-compress-lzma-shell-factory-data tl3218x FLASH 772772 772786 14 0.0
RAM 49348 49348 0 0.0
light-app-ota-shell-factory-data tl7218x FLASH 777388 777390 2 0.0
RAM 99812 99652 -160 -0.2
light-switch-app-ota-compress-lzma-shell-factory-data tlsr9528a FLASH 711380 711382 2 0.0
RAM 73544 73384 -160 -0.2
lighting-app-ota-factory-data tlsr9118bdk40d FLASH 628384 628386 2 0.0
RAM 142180 142020 -160 -0.1
lighting-app-ota-rpc-factory-data-4mb tlsr9518adk80d FLASH 814398 814400 2 0.0
RAM 99724 99564 -160 -0.2
tizen all-clusters-app arm unknown 5160 5160 0 0.0
FLASH 1781748 1781812 64 0.0
RAM 93720 93720 0 0.0
chip-tool-ubsan arm unknown 10924 10924 0 0.0
FLASH 18121646 18123534 1888 0.0
RAM 7909212 7910792 1580 0.0

Copy link
Contributor

@bzbarsky-apple bzbarsky-apple left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

I agree the super-long name for the "restart" function is weird and indicates we have some sort of layering issue....

Copy link

github-actions bot commented Jan 10, 2025

PR #36980: Size comparison from 87f7c4c to 13eef77

Full report (70 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
platform target config section 87f7c4c 13eef77 change % change
bl602 lighting-app bl602+mfd+littlefs+rpc FLASH 1355062 1355078 16 0.0
RAM 104152 103960 -192 -0.2
bl702 lighting-app bl702+eth FLASH 726456 726524 68 0.0
RAM 25361 25361 0 0.0
bl702+wifi FLASH 913070 913138 68 0.0
RAM 14101 14101 0 0.0
bl706+mfd+rpc+littlefs FLASH 1173904 1173972 68 0.0
RAM 23941 23941 0 0.0
bl702l lighting-app bl702l+mfd+littlefs FLASH 1082972 1083040 68 0.0
RAM 16612 16612 0 0.0
cc13x4_26x4 lighting-app LP_EM_CC1354P10_6 FLASH 840328 840312 -16 -0.0
RAM 123712 123552 -160 -0.1
lock-ftd LP_EM_CC1354P10_6 FLASH 825868 825844 -24 -0.0
RAM 125600 125440 -160 -0.1
pump-app LP_EM_CC1354P10_6 FLASH 772756 772756 0 0.0
RAM 114076 113916 -160 -0.1
pump-controller-app LP_EM_CC1354P10_6 FLASH 756944 756928 -16 -0.0
RAM 114276 114116 -160 -0.1
cc32xx air-purifier CC3235SF_LAUNCHXL FLASH 540181 540165 -16 -0.0
RAM 205816 205304 -512 -0.2
lock CC3235SF_LAUNCHXL FLASH 574349 574325 -24 -0.0
RAM 205960 205448 -512 -0.2
cyw30739 light CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 681721 681705 -16 -0.0
RAM 78756 78596 -160 -0.2
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 701565 701549 -16 -0.0
RAM 81396 81236 -160 -0.2
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 701565 701549 -16 -0.0
RAM 81396 81236 -160 -0.2
CYW930739M2EVB-02 unknown 2040 2040 0 0.0
FLASH 658501 658485 -16 -0.0
RAM 73824 73664 -160 -0.2
light-switch CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 618337 618321 -16 -0.0
RAM 71748 71588 -160 -0.2
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 637965 637949 -16 -0.0
RAM 74292 74132 -160 -0.2
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 637965 637949 -16 -0.0
RAM 74292 74132 -160 -0.2
lock CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 637737 637713 -24 -0.0
RAM 74756 74596 -160 -0.2
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 657445 657429 -16 -0.0
RAM 77300 77140 -160 -0.2
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 657445 657429 -16 -0.0
RAM 77300 77140 -160 -0.2
thermostat CYW30739B2-P5-EVK-01 unknown 2040 2040 0 0.0
FLASH 614357 614341 -16 -0.0
RAM 68844 68684 -160 -0.2
CYW30739B2-P5-EVK-02 unknown 2040 2040 0 0.0
FLASH 634209 634193 -16 -0.0
RAM 71476 71316 -160 -0.2
CYW30739B2-P5-EVK-03 unknown 2040 2040 0 0.0
FLASH 634209 634193 -16 -0.0
RAM 71476 71316 -160 -0.2
efr32 lock-app BRD4187C FLASH 932660 932628 -32 -0.0
RAM 160228 160068 -160 -0.1
BRD4338a FLASH 747184 747192 8 0.0
RAM 233356 233196 -160 -0.1
window-app BRD4187C FLASH 1025616 1025608 -8 -0.0
RAM 128332 128172 -160 -0.1
esp32 all-clusters-app c3devkit DRAM 95352 95192 -160 -0.2
FLASH 1541932 1541914 -18 -0.0
IRAM 82552 82552 0 0.0
m5stack DRAM 116332 116172 -160 -0.1
FLASH 1548274 1548390 116 0.0
IRAM 117039 117039 0 0.0
linux air-purifier-app debug unknown 4752 4752 0 0.0
FLASH 2732057 2732231 174 0.0
RAM 133160 133160 0 0.0
all-clusters-app debug unknown 5560 5560 0 0.0
FLASH 6021926 6022166 240 0.0
RAM 526072 526072 0 0.0
all-clusters-minimal-app debug unknown 5456 5456 0 0.0
FLASH 5356774 5356952 178 0.0
RAM 243072 243072 0 0.0
bridge-app debug unknown 5472 5472 0 0.0
FLASH 4705190 4705400 210 0.0
RAM 221824 221824 0 0.0
chip-tool debug unknown 5992 5992 0 0.0
FLASH 12938958 12939134 176 0.0
RAM 587002 587002 0 0.0
chip-tool-ipv6only arm64 unknown 21560 21560 0 0.0
FLASH 11054048 11054400 352 0.0
RAM 638064 638064 0 0.0
fabric-admin debug unknown 5816 5816 0 0.0
FLASH 11335083 11335259 176 0.0
RAM 587346 587346 0 0.0
fabric-bridge-app debug unknown 4728 4728 0 0.0
FLASH 4530342 4530550 208 0.0
RAM 208928 208928 0 0.0
fabric-sync debug unknown 4968 4968 0 0.0
FLASH 5641733 5641941 208 0.0
RAM 477880 477880 0 0.0
lighting-app debug+rpc+ui unknown 6136 6136 0 0.0
FLASH 5641329 5641537 208 0.0
RAM 232072 232072 0 0.0
lock-app debug unknown 5408 5408 0 0.0
FLASH 4753590 4753798 208 0.0
RAM 208072 208072 0 0.0
ota-provider-app debug unknown 4768 4768 0 0.0
FLASH 4380104 4380312 208 0.0
RAM 201744 201744 0 0.0
ota-requestor-app debug unknown 4720 4720 0 0.0
FLASH 4519012 4519220 208 0.0
RAM 206312 206312 0 0.0
shell debug unknown 4248 4248 0 0.0
FLASH 3038253 3038493 240 0.0
RAM 160792 160792 0 0.0
thermostat-no-ble arm64 unknown 9584 9584 0 0.0
FLASH 4120344 4120712 368 0.0
RAM 246384 246384 0 0.0
tv-app debug unknown 5736 5736 0 0.0
FLASH 5991045 5991237 192 0.0
RAM 601312 601312 0 0.0
tv-casting-app debug unknown 5320 5320 0 0.0
FLASH 11167741 11167917 176 0.0
RAM 700496 700496 0 0.0
nrfconnect all-clusters-app nrf52840dk_nrf52840 FLASH 918092 918076 -16 -0.0
RAM 143332 143172 -160 -0.1
nrf7002dk_nrf5340_cpuapp FLASH 890648 890692 44 0.0
RAM 141519 141359 -160 -0.1
all-clusters-minimal-app nrf52840dk_nrf52840 FLASH 852160 852144 -16 -0.0
RAM 142244 142084 -160 -0.1
nxp contact k32w0+release FLASH 586128 586080 -48 -0.0
RAM 71112 70952 -160 -0.2
mcxw71+release FLASH 601640 601600 -40 -0.0
RAM 63328 63168 -160 -0.3
light k32w0+release FLASH 612732 612700 -32 -0.0
RAM 70504 70344 -160 -0.2
k32w1+release FLASH 687304 687288 -16 -0.0
RAM 48920 48760 -160 -0.3
lock mcxw71+release FLASH 763608 763568 -40 -0.0
RAM 70956 70796 -160 -0.2
psoc6 all-clusters cy8ckit_062s2_43012 FLASH 1647644 1647660 16 0.0
RAM 212144 211632 -512 -0.2
all-clusters-minimal cy8ckit_062s2_43012 FLASH 1555276 1555308 32 0.0
RAM 208960 208448 -512 -0.2
light cy8ckit_062s2_43012 FLASH 1470380 1470412 32 0.0
RAM 200928 200416 -512 -0.3
lock cy8ckit_062s2_43012 FLASH 1468116 1468148 32 0.0
RAM 225280 224768 -512 -0.2
qpg lighting-app qpg6105+debug FLASH 664336 664288 -48 -0.0
RAM 105456 105296 -160 -0.2
lock-app qpg6105+debug FLASH 622140 622100 -40 -0.0
RAM 99908 99748 -160 -0.2
stm32 light STM32WB5MM-DK FLASH 485072 485072 0 0.0
RAM 144912 144752 -160 -0.1
telink bridge-app tlsr9258a FLASH 683684 683686 2 0.0
RAM 91248 91088 -160 -0.2
contact-sensor-app tlsr9528a_retention FLASH 623926 623942 16 0.0
RAM 31488 31488 0 0.0
light-app-ota-compress-lzma-shell-factory-data tl3218x FLASH 772758 772772 14 0.0
RAM 49348 49348 0 0.0
light-app-ota-shell-factory-data tl7218x FLASH 777374 777376 2 0.0
RAM 99812 99652 -160 -0.2
light-switch-app-ota-compress-lzma-shell-factory-data tlsr9528a FLASH 711368 711370 2 0.0
RAM 73544 73384 -160 -0.2
lighting-app-ota-factory-data tlsr9118bdk40d FLASH 628370 628372 2 0.0
RAM 142180 142020 -160 -0.1
lighting-app-ota-rpc-factory-data-4mb tlsr9518adk80d FLASH 814384 814386 2 0.0
RAM 99724 99564 -160 -0.2
tizen all-clusters-app arm unknown 5160 5160 0 0.0
FLASH 1781736 1781800 64 0.0
RAM 93720 93720 0 0.0
chip-tool-ubsan arm unknown 10924 10924 0 0.0
FLASH 18121318 18123206 1888 0.0
RAM 7909272 7910852 1580 0.0

@mergify mergify bot merged commit a96f6ca into project-chip:master Jan 10, 2025
69 checks passed
Alami-Amine pushed a commit to Alami-Amine/connectedhomeip that referenced this pull request Jan 12, 2025
)

* Copied over the new AttributePathExpandIterator and will incrementally use it (so I can validate tests)

* Rename AttributePathExpandIterator to legacy

* Prepare for using new style iterators ... checking NOT YET enabled though

* Enabled checks ... and unit tests fail, but this now can be debugged

* Fix some of the underlying bugs: read handling logic assumes we are ok to undo

* Unit tests pass now

* Restyle

* Use new iterator in IME

* Update logic to use the new iterator on testRead

* more updates

* Restyle

* Remove the legacy attribute path expand iterator

* Update naming

* Restyle

* Remove extra argument for ReadHandler constructor

* Restyle

* Slight flash improvement

* Fix up includes

* Removed empty line

* added comment on why state is a friend class

* Comment updates

* Restyle, add some comments and add extra checks on validity check only for expansion. This saves a tiny amount of flash (32 bytes)

* Remove an include

* Comment updates, renamed mLastOutputPath to mOutputPath

* Fix one typo

* Re-arrange members of ReadHandler to optimize for memory layout. This saves 8 bytes for struct. We still have a 20-byte padding which I am unsure how to get rid of

* Restyle

* Rename State to Position

* One more rename

* Remove redundant assigment ...we are at a net 0 txt increase now on qpg

* Add more unit tests for non-obvious requirement that wildcard expansion checks path validity, however non-wildcard does not check it

* Update src/app/AttributePathExpandIterator.cpp

Co-authored-by: Tennessee Carmel-Veilleux <[email protected]>

* Update src/app/AttributePathExpandIterator.h

Co-authored-by: Tennessee Carmel-Veilleux <[email protected]>

* Update src/app/AttributePathExpandIterator.h

Co-authored-by: Tennessee Carmel-Veilleux <[email protected]>

* Update src/app/AttributePathExpandIterator.h

Co-authored-by: Tennessee Carmel-Veilleux <[email protected]>

* Update src/app/ReadHandler.h

Co-authored-by: Tennessee Carmel-Veilleux <[email protected]>

* Update src/app/ReadHandler.cpp

Co-authored-by: Tennessee Carmel-Veilleux <[email protected]>

* Update src/app/AttributePathExpandIterator.h

Co-authored-by: Tennessee Carmel-Veilleux <[email protected]>

* Use different values for the cluster ids for testing

* One more state to position change

* mExpanded is now set during output path returning. Removed 2 more sets to save another tinier amount of .text

* Remove some tests that seem redundant, keep only one

* Update src/app/AttributePathExpandIterator.cpp

Co-authored-by: Boris Zbarsky <[email protected]>

* Update src/app/AttributePathExpandIterator.cpp

Co-authored-by: Boris Zbarsky <[email protected]>

* Update src/app/AttributePathExpandIterator.cpp

Co-authored-by: Boris Zbarsky <[email protected]>

* Update src/app/AttributePathExpandIterator.cpp

Co-authored-by: Boris Zbarsky <[email protected]>

* Update src/app/InteractionModelEngine.cpp

Co-authored-by: Boris Zbarsky <[email protected]>

* Update src/app/ReadHandler.h

Co-authored-by: Boris Zbarsky <[email protected]>

* Update src/app/AttributePathExpandIterator.h

Co-authored-by: Boris Zbarsky <[email protected]>

* Update src/app/ReadHandler.h

Co-authored-by: Boris Zbarsky <[email protected]>

* Use mCompletePosition

* Another rename

* Undo submodule update

* Restyle

* Update comment text to not sound like graph parsing

* Rename method to be more descriptive

* Update peek attribute iterator to rollback and update code logic a bit. Hoping for cleaner code

---------

Co-authored-by: Andrei Litvin <[email protected]>
Co-authored-by: Tennessee Carmel-Veilleux <[email protected]>
Co-authored-by: Boris Zbarsky <[email protected]>
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.

4 participants