-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Decouple InteractionModelEngine from TimedHandler #32076
Merged
mergify
merged 10 commits into
project-chip:master
from
andy31415:decouple_timed_handler
Feb 15, 2024
Merged
Decouple InteractionModelEngine from TimedHandler #32076
mergify
merged 10 commits into
project-chip:master
from
andy31415:decouple_timed_handler
Feb 15, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pullapprove
bot
requested review from
andyg-apple,
anush-apple,
arkq,
bzbarsky-apple,
carol-apple,
cecille,
chrisdecenzo,
chshu,
chulspro,
cliffamzn,
Damian-Nordic,
dhrishi,
harsha-rajendran,
hawk248,
hicklin,
jepenven-silabs,
jmartinez-silabs,
jmeg-sfy,
joonhaengHeo,
jtung-apple,
kkasperczyk-no,
kpschoedel,
ksperling-apple,
lazarkov,
lpbeliveau-silabs,
LuDuda and
mhazley
February 12, 2024 14:23
pullapprove
bot
requested review from
turon,
vivien-apple,
wiba-nordic,
woody-apple,
younghak-hwang,
yufengwangca and
yunhanw-google
February 12, 2024 14:23
PR #32076: Size comparison from 8398491 to decbf5b Increases (9 builds for cc32xx, mbed, nrfconnect, qpg, stm32)
Full report (9 builds for cc32xx, mbed, nrfconnect, qpg, stm32)
|
PR #32076: Size comparison from 8398491 to b602460 Increases (72 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, k32w, linux, mbed, nrfconnect, psoc6, qpg, stm32, telink)
Decreases (18 builds for linux, psoc6)
Full report (73 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, k32w, linux, mbed, nrfconnect, psoc6, qpg, stm32, telink)
|
I do not understand the large increase in sizes for boufallolab builds ... the other platforms seem more reasonable/expected. |
PR #32076: Size comparison from 4fef04b to c10c747 Increases above 0.2%:
Increases (2 builds for linux)
Decreases (1 build for linux)
Full report (2 builds for linux)
|
PR #32076: Size comparison from 4fef04b to 9cb1130 Increases above 0.2%:
Increases (72 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, k32w, linux, mbed, nrfconnect, psoc6, qpg, stm32, telink)
Decreases (17 builds for linux, psoc6)
Full report (73 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, k32w, linux, mbed, nrfconnect, psoc6, qpg, stm32, telink)
|
bzbarsky-apple
approved these changes
Feb 14, 2024
tehampson
approved these changes
Feb 15, 2024
raul-marquez-csa
pushed a commit
to raul-marquez-csa/connectedhomeip
that referenced
this pull request
Feb 16, 2024
* Decouple TimedHandler.h/cpp from InteractionModelEngine * Restyle * Use override instead of virtual * Update comment - re-add a variant of the previous comment explaining why mTimeLimit is last * Pull in the IM pointers support, to make less RAM/BSS usage for embedded * Fix typo and kick restyler * Restyle * Previous align was better * fix name for handler --------- Co-authored-by: Andrei Litvin <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Before this change, IM includes TimedHandler.h, and TimedHandler.cpp includes IM, which creates a very strong coupling between the two clases.
Split the TimedHandler needs into a separate interface. IM already has a vtable so the cost of this is adding a delegate pointer to TimedHandler. The gain is less coupling and more testability.
Generally trying to not use InteractionModelEngine::GetInstance in many places should be very beneficial as it would allow us to have in-process testing (e.g. one client and one server running in parallel as different IM engines). This brings us closer to that.
Before this looked like:
After this looks like:
Regarding C++ sizes, this is what I got on linux with
-Xclang -fdump-record-layouts
With globals:
With pointer usage:
for NRF packing seems to happen as we expect: