Skip to content

Commit 7efabba

Browse files
committed
Reference the correct version of the java allocation instrumenter.
It was updated in affc27f Part of #13726. Closes #13734. PiperOrigin-RevId: 386415693
1 parent 16e91d3 commit 7efabba

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

site/docs/skylark/performance.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -366,7 +366,7 @@ You must pass these two startup flags to *every* Bazel invocation:
366366

367367
```
368368
STARTUP_FLAGS=\
369-
--host_jvm_args=-javaagent:$(BAZEL)/third_party/allocation_instrumenter/java-allocation-instrumenter-3.0.1.jar \
369+
--host_jvm_args=-javaagent:$(BAZEL)/third_party/allocation_instrumenter/java-allocation-instrumenter-3.3.0.jar \
370370
--host_jvm_args=-DRULE_MEMORY_TRACKER=1
371371
```
372372
**NOTE**: The bazel repository comes with an allocation instrumenter.

site/docs/user-manual.html

+7-7
Original file line numberDiff line numberDiff line change
@@ -2613,30 +2613,30 @@ <h4 id='memory-tracking'>Memory tracking</h4>
26132613
startup flags to Bazel:
26142614
</p>
26152615
<ul>
2616-
<li><code>--host_jvm_args=-javaagent:$BAZEL/third_party/allocation_instrumenter/java-allocation-instrumenter-3.0.1.jar</code></li>
2616+
<li><code>--host_jvm_args=-javaagent:$BAZEL/third_party/allocation_instrumenter/java-allocation-instrumenter-3.3.0.jar</code></li>
26172617
<li><code>--host_jvm_args=-DRULE_MEMORY_TRACKER=1</code></li>
26182618
</ul>
26192619
<p>
2620-
The java-agent is checked into bazel at
2621-
third_party/allocation_instrumenter/java-allocation-instrumenter-3.0.1.jar, so make
2622-
sure you adjust <code>$BAZEL</code> for where you keep your bazel repository.
2620+
The java-agent is checked into Bazel at
2621+
third_party/allocation_instrumenter/java-allocation-instrumenter-3.3.0.jar, so make
2622+
sure you adjust <code>$BAZEL</code> for where you keep your Bazel repository.
26232623

26242624
Do not forget to keep passing these options to Bazel for every command or the server will
26252625
restart.
26262626
</p>
26272627
<p>Example:</p>
26282628
<pre>
2629-
% bazel --host_jvm_args=-javaagent:$BAZEL/third_party/allocation_instrumenter/java-allocation-instrumenter-3.0.1.jar \
2629+
% bazel --host_jvm_args=-javaagent:$BAZEL/third_party/allocation_instrumenter/java-allocation-instrumenter-3.3.0.jar \
26302630
--host_jvm_args=-DRULE_MEMORY_TRACKER=1 \
26312631
build --nobuild &lt;targets&gt;
26322632

26332633
# Dump rules
2634-
% bazel --host_jvm_args=-javaagent:$BAZEL/third_party/allocation_instrumenter/java-allocation-instrumenter-3.0.1.jar \
2634+
% bazel --host_jvm_args=-javaagent:$BAZEL/third_party/allocation_instrumenter/java-allocation-instrumenter-3.3.0.jar \
26352635
--host_jvm_args=-DRULE_MEMORY_TRACKER=1 \
26362636
dump --rules
26372637

26382638
# Dump Starlark heap and analyze it with pprof
2639-
% bazel --host_jvm_args=-javaagent:$BAZEL/third_party/allocation_instrumenter/java-allocation-instrumenter-3.0.1.jar \
2639+
% bazel --host_jvm_args=-javaagent:$BAZEL/third_party/allocation_instrumenter/java-allocation-instrumenter-3.3.0.jar \
26402640
--host_jvm_args=-DRULE_MEMORY_TRACKER=1 \
26412641
dump --skylark_memory=$HOME/prof.gz
26422642
% pprof -flame $HOME/prof.gz

src/main/java/com/google/devtools/build/lib/profiler/memory/AllocationTrackerModule.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
* <li>--host_jvm_args=-javaagent:(path to Google's java agent jar)
3737
* <ul>
3838
* <li>For Bazel use <a
39-
* href="https://github.com/bazelbuild/bazel/tree/master/third_party/allocation_instrumenter">java-allocation-instrumenter-3.0.1.jar</a>
39+
* href="https://github.com/bazelbuild/bazel/tree/master/third_party/allocation_instrumenter">java-allocation-instrumenter-3.3.0.jar</a>
4040
* </ul>
4141
* <li>--host_jvm_args=-DRULE_MEMORY_TRACKER=1
4242
* </ol>

0 commit comments

Comments
 (0)