-
Notifications
You must be signed in to change notification settings - Fork 52
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
CI: Add workflow to calculate build size diff before & after PR/commit. #262
Conversation
Build diffBase commit: 6c1433e877e570f9958c1edab77062d4ed9220fd
|
Okay, so now I'll force push without the test C++ code and the bot should add another comment after this, indicating the build size for this PR hasn't changed vs the base commit. https://github.com/lancaster-university/codal-microbit-v2/compare/971d6c59b66015612f17f3f7a69c1f217eed3325..7843574ae2a196029527eb79cfb004d23e0be385 |
971d6c5
to
7843574
Compare
7843574
to
dd547c7
Compare
dd547c7
to
dacb004
Compare
Build diffBase commit: fd3bde3c71e381ce2f6fd732433bdba5c528782e
|
df93ed7
to
93771a4
Compare
93771a4
to
32de180
Compare
32de180
to
04ba398
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've tweaked a bit the order of the workflow steps and how the codal.json file is modified and this PR is now ready to be merged 🎉
This PR uses Google's Bloaty McBloatface to analyse the MICROBIT elf file for memory consumption.
It also builds the PR base commit, or the commit parent, to do a diff and see the additional memory consumed or saved.
In the case of being a PR from a branch in this repository (not forks) it will post the diff as a comment as well.
To show an example diff in this PR (instead of an output just showing "no change in size"), the initial commit will contain a bit of code in MicroBit.cpp to create a 4000 byte array and a loop to write some data into it. So, the first bot comment will show the PR as increasing the
.bss
and.text
sections.I will then force push an update removing this code and the bot will post another comment showing a zero size increase.
Both bloaty analysis outputs are added to to the Action work summary, so even PRs from forks will have this info (even if they don't get a PR comment):