HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
openjdk
jmh
Java2021–2026
openjdk / jmh

jmh

https://openjdk.org/projects/code-tools/jmh

6Distinct people
7Mentions
0Explicit recommenders
2.7KGitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

https://openjdk.org/projects/code-tools/jmh

GitHub

Where it is used

No documented product use has been verified yet.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

No other repository is repeatedly linked in the same discussions.

This week on Hacker News

Nov 9–Nov 16 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/16/2026, 12:01:57 AM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by year7 dated mentions

Observed mentions: 2021-01-16 06:27:14 UTC to 2026-10-06 16:34:47 UTC.

0122021-01-01 00:00:00 UTC to 2022-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments20212022-01-01 00:00:00 UTC to 2023-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2023-01-01 00:00:00 UTC to 2024-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments20232024-01-01 00:00:00 UTC to 2025-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments2025-01-01 00:00:00 UTC to 2026-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments2026-01-01 00:00:00 UTC to 2027-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments. Incomplete calendar period.2026*

* An incomplete calendar period is marked with an outlined bar. Its count is not directly comparable with a full period.

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
20212021-01-01 00:00:00 UTC2022-01-01 00:00:00 UTC101
20222022-01-01 00:00:00 UTC2023-01-01 00:00:00 UTC000
20232023-01-01 00:00:00 UTC2024-01-01 00:00:00 UTC000
20242024-01-01 00:00:00 UTC2025-01-01 00:00:00 UTC202
20252025-01-01 00:00:00 UTC2026-01-01 00:00:00 UTC202
2026 (partial)2026-01-01 00:00:00 UTC2027-01-01 00:00:00 UTC202

What Hacker News says

2 sources
For benchmarks it is generally recommended to use JMH [1] instead of coding your own warm-up, timing & GC profiling implementation. Playing around with a quick JMH set-up [2], there are a few new findings though: | Benchmark | Count | Preallocate | Time (ns/op) | Allocation (B/op) | Allocation (op) | |-----------+-------+-------------+--------------+-------------------+---------------------| | OnHeap | 10^6 | true | 6231838 | 16000020 | ~ 1 | | OffHeap | 10^6 | true | 6819142 | 54 | Should also be ~ 1 | | OnHeap | 10^6 | false | 9719988 | 33554598 | ~ 17 | | OffHeap | 10^6 | false | 19450448 | 773 | Should also be ~ 17 | 1. The difference between on/off-heap Python-like impl
Read the rest
ementation is less significant (~ 10%) provided that we preallocate things correctly. 2. The off-heap (MemorySegment) implementation slows down as the number of allocation increasing. EDIT: Profiling with JMH (using -prof async) shows that the off-heap implementation spent quite some time on jdk.internal.misc.Unsafe.getIntUnaligned in its resizeIfNeeded method, which should be the culprit here - Java array are guaranteed to be aligned (at least in HotSpot JVM), and aligned operations are much more efficient than unaligned ones, which should be able to explain the performance hit. --- 55482970432 ns (18.53%), 5548 samples [ 0] jdk.internal.misc.Unsafe.getIntUnaligned [ 1] jdk.internal.misc.ScopedMemoryAccess.getIntUnalignedInternal [ 2] jdk.internal.misc.ScopedMemoryAccess.getIntUnaligned [ 3] java.lang.invoke.VarHandleSegmentAsInts.get [ 4] java.lang.invoke.VarHandleGuards.guard_LJ_I [ 5] jdk.internal.foreign.AbstractMemorySegmentImpl.get [ 6] gc_less.python_like.IntHashtableOffHeap.resizeIfNeeded [ 7] gc_less.python_like.IntHashtableOffHeap.put [ 8] gc_less.benchmarks.OffHeapBenchmark.testPutOffHeap [1] https://github.com/openjdk/jmh [2] https://github.com/gudzpoz/gc_less/commit/17dcc3eb57b89f2642...
In Experimenting with GC-less (heap-less) Java

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.