mu_basecore icon indicating copy to clipboard operation
mu_basecore copied to clipboard

Cache Basetools Random Stack Cookie Values to Improve Incremental Build Times

Open TaylorBeebe opened this issue 1 year ago • 1 comments

Description

If the stack cookie value is randomized in the AutoGen.h file each build, the build system will determine the module/library must be rebuilt causing effectively a clean build every time. This PR updates the logic which creates the STACK_COOKIE_VALUE #define to cache the stack cookie values in a .txt file in Conf/.cache so incremental builds use the same value and clean builds generate the value.

  • [x] Impacts functionality?
    • Functionality - Does the change ultimately impact how firmware functions?
    • Examples: Add a new library, publish a new PPI, update an algorithm, ...
  • [x] Impacts security?
    • Security - Does the change have a direct security impact on an application, flow, or firmware?
    • Examples: Crypto algorithm change, buffer overflow fix, parameter validation improvement, ...
  • [ ] Breaking change?
    • Breaking change - Will anyone consuming this change experience a break in build or boot behavior?
    • Examples: Add a new library class, move a module to a different repo, call a function in a new library class in a pre-existing module, ...
  • [ ] Includes tests?
    • Tests - Does the change include any explicit test code?
    • Examples: Unit tests, integration tests, robot tests, ...
  • [ ] Includes documentation?
    • Documentation - Does the change contain explicit documentation additions outside direct code modifications (and comments)?
    • Examples: Update readme file, add feature readme file, link to documentation on an a separate Web page, ...

How This Was Tested

Tested by building and confirming the reduced build time for debug builds after the initial build.

Integration Instructions

N/A

TaylorBeebe avatar Mar 19 '24 23:03 TaylorBeebe

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 1.23%. Comparing base (c8f9883) to head (8c587da). Report is 182 commits behind head on release/202311.

Additional details and impacted files
@@               Coverage Diff               @@
##           release/202311     #773   +/-   ##
===============================================
  Coverage            1.23%    1.23%           
===============================================
  Files                1302     1302           
  Lines              332084   332084           
  Branches             6683     6683           
===============================================
  Hits                 4117     4117           
  Misses             327891   327891           
  Partials               76       76           
Flag Coverage Δ
MdeModulePkg 0.69% <ø> (ø)
MdePkg 5.37% <ø> (ø)
NetworkPkg 0.00% <ø> (∅)
PolicyServicePkg 30.41% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

codecov-commenter avatar Mar 19 '24 23:03 codecov-commenter