-
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
Move ClusterWriteMapping.java to be generated from matter.idl #25773
Merged
andy31415
merged 32 commits into
project-chip:master
from
andy31415:move_cluster_write_mapping_to_jinja
Mar 22, 2023
Merged
Move ClusterWriteMapping.java to be generated from matter.idl #25773
andy31415
merged 32 commits into
project-chip:master
from
andy31415:move_cluster_write_mapping_to_jinja
Mar 22, 2023
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
…ween cpp and java files
pullapprove
bot
requested review from
amitnj,
anush-apple,
arkq and
bzbarsky-apple
March 21, 2023 21:49
pullapprove
bot
requested review from
xylophone21,
younghak-hwang,
yufengwangca and
yunhanw-google
March 21, 2023 21:49
pullapprove
bot
added
review - pending
scripts
controller
gn
and removed
scripts
controller
gn
labels
Mar 21, 2023
PR #25773: Size comparison from 2a9fa2a to 80baf11 Full report (1 build for cc32xx)
|
PR #25773: Size comparison from 2a9fa2a to a9e2f2b Decreases (1 build for cc32xx)
Full report (1 build for cc32xx)
|
…viously identical
PR #25773: Size comparison from 2a9fa2a to ad4aa7c Full report (1 build for cc32xx)
|
yunhanw-google
approved these changes
Mar 22, 2023
PR #25773: Size comparison from 2a9fa2a to 46380e3 Decreases (1 build for qpg)
Full report (4 builds for cc32xx, mbed, qpg)
|
PR #25773: Size comparison from 2a9fa2a to 6fc9632 Increases (1 build for cc32xx)
Decreases (1 build for cc32xx)
Full report (1 build for cc32xx)
|
fast track: java only change without generally affecting other library functionality |
lecndav
pushed a commit
to lecndav/connectedhomeip
that referenced
this pull request
Mar 22, 2023
…t-chip#25773) * Some initial changes * Parser support for timed writes * Small doc update * Matter idl support for timed write * Fix indent and codegen all * Remove extra line from readme * Some fixes * Fix conditional in requires_timed_write * Most codegen looks ok. Java boxing logic is suspect still * More updates, output idential EXCEPT types for boxing * Increase 1000 to 10000 to match original template * Fix byte count comparison when long starts to take effect * Fix length of underlying bitmap type sizing * Fixed files, they are IDENTICAL * Integrate java-jni and java-class since build rules are different between cpp and java files * Fix python syntax * Switch default to not have underscore * Add java codegen via jinja to zap_regen_all * Restyle, fix restyle logic * Fix duplicated generation target * Do not attempt to zap-generate Cluster write mapping * Add golden image unit test for java codegen * Add prettyfy for java output ... makes the input/output files more obviously identical * Remove unused variable * Fix upper/lowercase of acronyms, to be fully backwards compatible * Add license blurb since we checkin generated file (and maybe jinja files should also have licenses * Restyle * Fix unit test --------- 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.
We had code generation incompatibilities in java because source of truth between matter id and zap templates may use different content. In this case the error shows up in #25737: just chaing
.matter
idl to contain all possible attributes on client clusters is insufficient since zap code still relies on enabling flags. #25693 is looking to fix some of these, however updating all helpers is reasonably painful and it is likely easier to get out of sync using 2 generation methods.Start moving some more files than strictly required due to OOM to have a single source of truth for codegen. Unfortunately we have a lot of java-specific codegen (14 templates), so this has to be done incrementally.
Changes:
java-jni
(c++) andjava-class
(java files) code generationrestyle
requirement for this fileI was unable to make the java files be generated at compile-time since our current android/java library did not have file generation support and
build/chip/java/write_build_config.py
also seems to make dependency assuptions. So for now similar codegen logic as before for just, just different generator/template.