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

Cleanups, fixes, and speedups for the depscanner #13021

Merged

Commits on Mar 28, 2024

  1. Configuration menu
    Copy the full SHA
    458827a View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    2812b21 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    875a9b7 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    934c907 View commit details
    Browse the repository at this point in the history

Commits on Mar 29, 2024

  1. scripts/depscan: combine pickle and JSON data into a single file

    We don't need to write and pass two separate files to the depscanner,
    I've used the pickle because the pickle serializer/deserializer should
    be faster than JSON, thought I haven't tested.
    dcbaker committed Mar 29, 2024
    Configuration menu
    Copy the full SHA
    fae1363 View commit details
    Browse the repository at this point in the history
  2. scripts/depscan: pick language once, at configure time

    We already have to decide whether to scan a file at configure time, so
    we don't want to have to do it again at compile time, every time the
    depscan rule is run. We can do this by saving and passing the language
    to use in the pickle, so depscan doesn't have to re-calculate it. As an
    added bonus, this removes an import from depscan
    dcbaker committed Mar 29, 2024
    Configuration menu
    Copy the full SHA
    433117f View commit details
    Browse the repository at this point in the history
  3. scripts/depscan: remove unnecessary function

    This basically existed for an assert which we don't need, as mypy would
    catch that issue for us anyway. Removing the function entirely has some
    small performance advantages
    dcbaker committed Mar 29, 2024
    Configuration menu
    Copy the full SHA
    3e9021a View commit details
    Browse the repository at this point in the history
  4. backend/ninja: don't rewrite the pickle data if it hasn't changed

    Which prevents spurious rebuilds of dyndeps
    dcbaker committed Mar 29, 2024
    Configuration menu
    Copy the full SHA
    2f8d51c View commit details
    Browse the repository at this point in the history
  5. backend/ninja: Don't run -t cleandead when using dyndeps

    There's a known ninja bug
    (ninja-build/ninja#1952) that running this
    with dyndeps will result in Ninja deleting implicit outputs from the
    dyndeps, leading to pointless rebuilds. For reference, this is what
    CMake does as well.
    dcbaker committed Mar 29, 2024
    Configuration menu
    Copy the full SHA
    2171a01 View commit details
    Browse the repository at this point in the history