commit | 17468af6591564a752fa8eaeb5a9032569bda4c8 | [log] [tgz] |
---|---|---|
author | Googler <jhorvitz@google.com> | Thu May 25 10:37:55 2023 -0700 |
committer | Copybara-Service <copybara-worker@google.com> | Thu May 25 10:39:14 2023 -0700 |
tree | 4093cbbb352c432d59adb9864d9bb52b9d0e58fc | |
parent | 986a97f4c6c74c3dadcc17f2e92d83600c355641 [diff] |
Utilize `CustomCommandLine#addObject` to add a `Collection` without copying over its elements. This is more memory efficient if the `Collection` is retained anyway, since we spend a single array slot on a pointer instead of an array slot for each element. It works straightaway because `CustomCommandLine` already has handling for lazily "expanding" `Iterable`. This change only affects Java compilation actions, as they are the only case I found which is currently wastefully copying lists. To maximize the benefit, structure the `JavaHeaderCompileAction` builder to accept an existing `ImmutableList<String>` of Javac options instead of creating its own. PiperOrigin-RevId: 535304666 Change-Id: Id41af250916e95e87fd69bcdc1bfda1d3bc1421f
{Fast, Correct} - Choose two
Build and test software of any size, quickly and reliably.
Speed up your builds and tests: Bazel rebuilds only what is necessary. With advanced local and distributed caching, optimized dependency analysis and parallel execution, you get fast and incremental builds.
One tool, multiple languages: Build and test Java, C++, Android, iOS, Go, and a wide variety of other language platforms. Bazel runs on Windows, macOS, and Linux.
Scalable: Bazel helps you scale your organization, codebase, and continuous integration solution. It handles codebases of any size, in multiple repositories or a huge monorepo.
Extensible to your needs: Easily add support for new languages and platforms with Bazel's familiar extension language. Share and re-use language rules written by the growing Bazel community.
Follow our tutorials:
To report a security issue, please email security@bazel.build with a description of the issue, the steps you took to create the issue, affected versions, and, if known, mitigations for the issue. Our vulnerability management team will respond within 3 working days of your email. If the issue is confirmed as a vulnerability, we will open a Security Advisory. This project follows a 90 day disclosure timeline.
See CONTRIBUTING.md