Skip to content

Conversation

@alexeagle
Copy link
Contributor

@alexeagle alexeagle commented Jun 4, 2025

Saves a bunch of time in analysis and execution when there is a cache miss on protoc, as well as avoiding a bunch of gcc logspam.

For example a recent commit on master took 3m 54s to
Run bazel run @com_github_bazelbuild_buildtools//:buildifier

https://github.com/buildbarn/bb-storage/actions/runs/15302599382/job/43046869873

and printed 256 lines of log output such as

bazel-out/k8-opt-exec-ST-d57f47055a04/bin/external/protobuf+/src/google/protobuf/io/_virtual_includes/printer/google/protobuf/io/printer.h:127:23: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
  127 |     for (int i = 0; i < path.size(); ++i) {
      |         

Nearly all the time and log output is attributed to compiling cc_binary @protobuf//:protoc

@alexeagle alexeagle force-pushed the avoid_protoc branch 2 times, most recently from d33faf3 to cd8330f Compare June 4, 2025 21:26
Saves a bunch of time in analysis and execution when there is a cache miss on protoc,
as well as avoiding a bunch of gcc logspam.
@stagnation
Copy link
Contributor

Great! We saw the expected improvements in the deployments repo, and it helped with some Windows issues we had at the time. I then forgot to add it to the other repos: buildbarn/bb-deployments#139

stagnation added a commit to buildbarn/bb-deployments that referenced this pull request Jun 9, 2025
Following discussions in buildbarn/bb-storage#248
we must register the toolchain as well. I don't know if this was always
an oversight or the behavior changed.
stagnation added a commit to buildbarn/bb-deployments that referenced this pull request Jun 9, 2025
Following discussions in buildbarn/bb-storage#248
we must register the toolchain as well. I don't know if this was always
an oversight or the behavior changed.
@EdSchouten EdSchouten merged commit 1f558fb into buildbarn:master Jun 10, 2025
1 check passed
@EdSchouten
Copy link
Member

Thanks!

stagnation added a commit to buildbarn/bb-deployments that referenced this pull request Jun 13, 2025
By calling the protoc toolchain module first its registered toolchain
wins for compiling protoc. This follows discussions in
buildbarn/bb-storage#248
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants