Stream

Vlad Ilyushchenko

Performance Libraries  - 
Inter-thread messaging is a fundamental part of any asynchronous system. It is the component responsible for transportation of data between threads. Messaging forms the infrastructure, the scaffolding of multi-threaded applic...
1
Add a comment...

Attila-Mihaly Balazs
moderator

Expert Programming  - 
 
I'm trying to put together a "how to get started in the JVM performance tuning field" presentation for the local JUG. Any feedback is very welcome:

(I realize that this is probably better as a one week workshop, but I'm trying to point people towards a couple of starting points and hope that they figure it out for themselves)

https://docs.google.com/presentation/d/1azqLjBh2U0V5_-w_SXi6vDC8uiRq6VNW1s_-2B2Kho4/edit?usp=sharing
Drive
TJUG 55 - Low level details for high level developersLow level details for high level developers Balázs Attila-Mihály
5
2
Attila-Mihaly Balazs's profile photoMartin Andersson's profile photo
3 comments
 
Are you by any chance hiring in the U.S.?
Add a comment...

Attila-Mihaly Balazs
moderator

Expert Programming  - 
 
"Intel Software Guard Extensions (SGX) by Victor Costan and Srinivas Devada (NSF)"

Besides discussing SGX, it also contains a great overview of modern hardware, well worth the read for every developer!

https://eprint.iacr.org/2016/086.pdf
1
1
Add a comment...

Vlad Ilyushchenko

Expert Programming  - 
 
It there a reason for allocating new array in Enum.values() ?
1
Vlad Ilyushchenko's profile photoAttila-Mihaly Balazs's profile photo
3 comments
 
+1 to what +Andrew Bissell said. I usually add a method like the following to my enums to avoid allocation in this particular case:

private final static MyEnum VALUES[] = values();

public static MyEnum getByOrdinal(int ordinal) { return VALUES[ordinal]; }

Add a comment...
 
I am writing inter-thread messaging for my free project. It is getting quite stable and I'd like any feedback on thread messaging you already use, likes or dislikes. My implementation is similar to disruptor as far as using ring queue and sequences.

Here is usage example: https://github.com/bluestreak01/questdb/blob/master/core/src/test/java/com/questdb/mp/ConcurrentTest.java
2
Vlad Ilyushchenko's profile photoNitsan Wakart's profile photo
5 comments
 
Please share the results, also have a look in Agrona for some post-Disruptor ideas from Mr. T
Add a comment...

Attila-Mihaly Balazs
moderator

Expert Programming  - 
Two years ago I painfully researched and built JMM Pragmatics talk and transcript, hoping it would highlight the particular dark corners of the Java Memory Models for those who cannot afford to spend years studying the formalisms, and deriving the actionable insights from them.
8
4
Nitsan Wakart's profile photo
 
Excellent material if somewhat long :)
Add a comment...

Francesco Nigro

Unrelated but interesting  - 
1
Add a comment...

About this community

This community is about learning Java beyond the basics and advanced material. It about thinking about which Java is doing in milli-seconds and at the micro-second level. It is not a general Java programming help line for questions which can be easily answered using google search. You must subscribe under your name, not as a company or group account.

Attila-Mihaly Balazs
moderator

Presentation Videos  - 
 

Grant Jenks - Python Sorted Collections - PyCon 2016: https://youtu.be/7z2Ki44Vs4E?t=16m18s

(yes, it's python but could be adopted to Java and I wager it would have a better performance than the RBTree / AVLTree / etc implemetnations since it uses contiguous memory locations - AKA arrays :-))
1
Add a comment...

Attila-Mihaly Balazs
moderator

Expert Programming  - 
 
Benchmarking the cost of primitive operations on the JVM
(when are floating point operations faster than integer ones?)

https://www.grey-panther.net/2016/08/benchmarking-the-cost-of-primitive-operations-on-the-jvm.html
2
Nitsan Wakart's profile photoAttila-Mihaly Balazs's profile photo
6 comments
 
+Nitsan Wakart btw, I too was worried that the "blackhole" mechanism would dominate the measurement, but since the results are very close to what I expected (minus some surprises which I mentioned) I think that the calibration JMH performs works pretty well to eliminate the overhead.
Add a comment...

Nitsan Wakart
moderator

Expert Programming  - 
 
 
A new post: Fixing CO in Cassandra Stress and the joys of HdrHistogram log processing
4
Attila-Mihaly Balazs's profile photo
 
Thank you for doing this!
Add a comment...

Peter Lawrey
moderator

Presentation Videos  - 
 
What are some of the performance implications of using lambdas and what strategies can be used to address these. When might be want an alternative to using a lambda and how can we design our APIs to be flexible in this regard.What are the principles of writing low latency code in Java? How do we tune and optimize our code for low latency? When don’t we optimize our code? Where does the JVM help and where does it get in our way? How does this apply to lambdas? How can we design our APIs to use lambdas and minimize garbage?

https://www.youtube.com/watch?v=vZngvuXk7PM
12
2
Attila-Mihaly Balazs's profile photoPeter Lawrey's profile photo
2 comments
 
Agreed. Lights are 50 or 60 Hz depending on where you are. Cinemas were typically 24 Hz until quite recently. 24 Hz is about 42 ms between frames.
Add a comment...

Nitsan Wakart
moderator

Expert Programming  - 
So, going on from my whingy post on safepoint bias, where does one go to get their profiling kicks? One option would be to use an OpenJDK internal API call AsyncGetCallTrace to facilitate non-safepoint collection of stack tra...
6
3
Add a comment...

Eric DeFazio

Performance Libraries  - 
 
Great Series by Adrian Colyer about "Arrakis" an OS designed for DataCenter containers to directly map hardware and minimize Linux I/O kernel overhead (62% to 82%):

"map directly to hardware mechanisms allowing applications to break out of existing OS performance and protection limitations."

https://blog.acolyer.org/2016/06/14/arrakis-the-operating-system-is-the-control-plane/

Video discussion (circa 2014) here:
https://www.usenix.org/conference/osdi14/technical-sessions/presentation/peter (audio gets better after 11:30 or so)
Also "the Morning Paper" https://blog.acolyer.org/ is a great resource.
2
Add a comment...

Attila-Mihaly Balazs
moderator

Presentation Videos  - 
 

Understanding HotSpot JVM Performance with JITWatch

Chris Newland discusses performance-boosting techniques used by the JVM’s JIT and introduces JITWatch, a tool helping to get the best JVM performance for a code.

From the Docklands.JLC.

http://www.infoq.com/presentations/jitwatch
5
3
Add a comment...

Daniel Shaya

Expert Programming  - 
 
JLBH (Java Latency Benchmarking Harness) was created to help benchmark Chronicle-FIX. Hopefully this open source harness will come in useful for other latency sensitive projects when JMH is not enough. All contributions welcome.
3
Add a comment...