Book description
No matter what language they're programming in, developers always wish things would run faster! Especially when writing mission-critical applications, no one wants to be limited by the programming environment. Java Performance Tuning provides all the details you need to know to "performance tune" any type of Java program and make Java code run significantly faster. Java Performance Tuning contains step-by-step instructions on all aspects of the performance tuning process, right from such early considerations as setting goals, measuring performance, and choosing a compiler. Extensive examples for tuning many parts of an application are described in detail, and any pitfalls are identified. The book also provides performance tuning checklists that enable developers to make their tuning as comprehensive as possible. Java Performance Tuning is a book to help you "roll up your sleeves" and examine your code in detail in order to apply different tuning techniques to produce the best possible result. The book shows you how to:
Create and plan a tuning strategy
Avoid performance penalties from inefficient code
Minimize the number of objects a program creates
Improve the behavior of loops and switches
Use threads effectively
Table of contents
-
Java Performance Tuning
- Preface
- 1. Introduction
- 2. Profiling Tools
-
3. Underlying JDK Improvements
- Garbage Collection
- Replacing JDK Classes
- Faster VMs
-
Better Optimizing Compilers
- What Optimizing Compilers Cannot Do
-
What Optimizing Compilers Can Do
- Remove unused methods and classes
- Increase statically bound calls
- Cut dead code and unnecessary instructions, including checks for null
- Use computationally cheaper alternatives (strength reduction)
- Replace runtime computations with compiled results
- Remove unused fields
- Remove unnecessary parts of compiled files
- Reduce necessary parts of compiled files
- Alter access control to speed up invocations
- Inline calls
- Remove dynamic type checks
- Unroll loops
- Code motion
- Eliminate common subexpressions
- Eliminate unnecessary assignments
- Rename classes, fields, and methods
- Reorder or change bytecodes
- Generate information to help a VM
- Managing Compilers
- Sun’s Compiler and Runtime Optimizations
- Compile to Native Machine Code
- Native Method Calls
- Uncompressed ZIP/JAR Files
- Performance Checklist
- 4. Object Creation
- 5. Strings
- 6. Exceptions, Casts, and Variables
- 7. Loops and Switches
- 8. I/O, Logging, and Console Output
- 9. Sorting
- 10. Threading
- 11. Appropriate Data Structures and Algorithms
- 12. Distributed Computing
-
13. When to Optimize
- When Not to Optimize
- Tuning Class Libraries and Beans
- Analysis
-
Design and Architecture
- Shared Resources
- Scaling
- Distributed Applications
- Object Design
-
Techniques for Predicting Performance
- Factor in comparative performance of operations
- Consider the relative costs of different types of accesses and updates
- Use simulations and benchmarks
- Consider the total work done and the design overhead
- Focus on shared resources
- Predict the effects of parallelism
- Assess the costs of data conversions
- Determine whether batch processing is faster
- Tuning After Deployment
- More Factors That Affect Performance
- Performance Checklist
- 14. Underlying Operating System and Network Improvements
- 15. Further Resources
- Index
- Colophon
Product information
- Title: Java Performance Tuning
- Author(s):
- Release date: September 2000
- Publisher(s): O'Reilly Media, Inc.
- ISBN: 9780596000158
You might also like
book
Java Performance: The Definitive Guide
Coding and testing are often considered separate areas of expertise. In this comprehensive guide, author and …
book
Java Threads and the Concurrency Utilities
This concise book empowers all Java developers to master the complexity of the Java thread APIs …
video
Advanced Java Performance: Hotspot GC Tuning LiveLessons
2+ Hours of Video Instruction Overview Advanced Java Performance: HotSpot GC Tuning LiveLessons covers the common …
book
Hands-On High Performance with Spring 5
A hands-on guide to creating, monitoring, and tuning a high performance Spring web applicationAbout This Book …