# Java Level 14: Performance

> Level 14: Performance of the LoWisa Java course: Profiling, Memory and Concurrency Performance, JVM Tuning Fundamentals. 3 lessons and 9 ideas, each explained in one line.

Performance is level 14 of 16 of the [LoWisa Java course](/courses/java/). It has 3 lessons and 9 ideas. Below is every lesson and what it teaches, in one line each.

## Profiling

- **Profile first.** A **profiler**: flight recorder, async-profiler: shows real hotspots; guessing optimises the wrong method.
- **Benchmarks honestly.** Microbenchmarks need **JMH**: warmup, forks and statistics: or the JIT makes your numbers fiction.
- **Allocation profiling.** Allocation **pressure** drives GC cost: profilers show which call sites create the garbage.

## Memory and Concurrency Performance

- **Escape analysis.** The JIT can stack-allocate objects that never **escape**: clean small methods help it prove that.
- **False sharing.** Threads hammering neighbouring fields share a cache **line**: padding hot counters apart restores speed.
- **Contention.** Lock **contention** serialises your parallel code: shrink critical sections or shard the state.

## JVM Tuning Fundamentals

- **Heap sizing.** Size the **heap** from measured live-set, not folklore: too small thrashes GC, too big wastes the host.
- **Collector choice.** Pick the **collector** by goal: throughput batch jobs and low-latency services want different ones.
- **Measure in production.** Tuning is empirical: change one flag, watch real **latency** percentiles, keep or revert.

## Before and after this level

- **Before:** [Level 13: Modern Java](/courses/java/level-13-modern-java/): Records and Pattern Matching, Modern Language Features, Writing Idiomatic Current Java.
- **Next:** [Level 15: Production Java](/courses/java/level-15-production-java/): Modules, Builds and Dependencies, Logging, Configuration and Reliability, Production Application Design.

In the app each of these ideas is taught and then asked back, and the level ends with a checkpoint and flashcards. See [Checkpoints and flashcards](/help/checkpoints-and-flashcards/).

## Frequently asked questions

### What does Java Level 14: Performance cover?

Profiling, Memory and Concurrency Performance, JVM Tuning Fundamentals: 3 lessons and 9 ideas.

### What should I know before this level?

The level before it, Level 13: Modern Java, which covers Records and Pattern Matching, Modern Language Features, Writing Idiomatic Current Java.

## Learn Java on your phone

The first level is free. LoWisa is on Google Play and the App Store.

---

Source: https://lowisa.dev/courses/java/level-14-performance/ · Updated 2026-11-16
