SlideShare une entreprise Scribd logo
1  sur  14
JVM and Garbage Collection


                by marcos.garcia@savoirfairelinux.com, Jan 2013
JVM?
●   Bytecode interpreter




                   http://viralpatel.net/blogs/java-virtual-machine-an-inside-story/
JVM Memory Vocabulary
●   Runtime data areas
    –   PC register:
        ●   One for each thread
        ●   Points to current execution code of each thread
    –   JVM stacks
        ●   One dedicated stack for each thread
        ●
            Holds many stack frames, one for each invoked method
             –   Every frame has 3 registers
    –   Heap
        ●   Shared among all threads
        ●   Stores Java objects.
        ●   Cleaned up by GC
    –   Method area
        ●
            Shared among all threads
        ●
            Contains method code (class implementations)
        ●
            Has a Runtime constant pool
    –   Native method stack (just for “native methods”

                             http://docs.oracle.com/javase/specs/jvms/se7/html/jvms-2.html#jvms-2.5
JVM Stack
●   Stack Frame
    –   Used to store data and partial results, as well as to
        perform dynamic linking, return values for methods, and
        dispatch exceptions.
    –   Describes all the needed information to run a method,
        including current method stack as well as other JVM
        shared spaces
●   Stack Frame registers (one per method
    being executed)
    –   Local Vars, used by current method
        invocation
    –   Frame data / Execution environment, used
        for internal stack operations
    –   Optop / Operand stack (for bytecode),
        reference to runtime constant pool
         ●   It is a LIFO stack, need push/pop operations

                                                                  http://performeister.tistory.com/38
JVM Heap
●   Two heap memory types             ●   Other memory
    –   Young Generation Memory           –   Permanent Generation
        ●   To/From Survivor spaces       –   Native memory (because of
        ●   Eden space                        native memory references,
    –   Old Generation Memory                 to the underlying OS)
Garbage collection
●   Principle: Generational collection or “weak generational hypothesis”
    –   Most allocated objects are not referenced (considered live) for long, that is,
        they die young
    –   Few references from older to younger objects exist
●   Minor GC
    –   Young generation collections occur relatively frequently and are efficient and
        fast because the young generation space is usually small and likely to
        contain a lot of objects that are no longer referenced.
●   Major GC
    –   Objects that survive some number of young generation collections are
        eventually promoted, or tenured, to the old generation




        http://www.oracle.com/technetwork/java/javase/tech/memorymanagement-whitepaper-1-150020.pdf
Young/Old Memory explained

●   Young Space
    –   Eden
        ●   Any object created inside a method or as a class variable
    –   2 survivor spaces (From/To)
        ●   Objects in use, that have survived at least one Minor GC
        ●   1 space empty, other full. Swaps on every GC pass
●   Old (Tenured)
    –   Objects referenced since a long time ago, still being used
    –   Very big objects are created directly in Old space


                            http://java-espresso.blogspot.ca/2011/05/heap-structure-in-jvm.html
GC example
●   Serial Collector (not currently used in modern JVM)




     http://www.oracle.com/technetwork/java/javase/tech/memorymanagement-whitepaper-1-150020.pdf
Parallel and CMS GC
●   CMS is the most used GC implementation
Heap fragmentation
●   We need contiguous space for memory allocation
●   GC also relocates (called compactation) objects to reduce fragmentation
G1 collector (JDK 6 & 7)
●   Garbage-First (G1) collector: server-style garbage collector, targeted for multi-processor
    machines with large memories.
●   It meets garbage collection (GC) pause time goals with a high probability, while achieving high
    throughput. Designed for applications that:
     –   Can operate concurrently with applications threads like the CMS collector.
     –   Compact free space without lengthy GC induced pause times.
     –   Need more predictable GC pause durations.
     –   Do not want to sacrifice a lot of throughput performance.
     –   Do not require a much larger Java heap.
●   G1 is planned as the long term replacement for the Concurrent Mark-Sweep Collector (CMS).
●   Better than CMS.
     –   G1 is a compacting collector. G1 compacts sufficiently to completely avoid the use of fine-grained free lists
         for allocation, and instead relies on regions. This considerably simplifies parts of the collector, and mostly
         eliminates potential fragmentation issues.
     –   G1 offers more predictable garbage collection pauses than the CMS collector, and allows users to specify
         desired pause targets.




    http://www.oracle.com/webfolder/technetwork/tutorials/obe/java/G1GettingStarted/index.html
G1 Heap Fragmentation




     Young
      GC
Heap evolution
  ●   Regular case      ●   OOM case




Tool: jconsole
Heap evolution
 ●   Regular case                   ●   OOM case




Tool: websphere resource analyzer

Contenu connexe

Tendances

Introduction to Java Programming Language
Introduction to Java Programming LanguageIntroduction to Java Programming Language
Introduction to Java Programming Language
jaimefrozr
 

Tendances (20)

GraalVM Overview Compact version
GraalVM Overview Compact versionGraalVM Overview Compact version
GraalVM Overview Compact version
 
Basics of reflection in java
Basics of reflection in javaBasics of reflection in java
Basics of reflection in java
 
Gradle
GradleGradle
Gradle
 
GraalVM
GraalVMGraalVM
GraalVM
 
Git and Github
Git and GithubGit and Github
Git and Github
 
GitLab for CI/CD process
GitLab for CI/CD processGitLab for CI/CD process
GitLab for CI/CD process
 
Introduction to GraalVM
Introduction to GraalVMIntroduction to GraalVM
Introduction to GraalVM
 
Understanding Java Garbage Collection
Understanding Java Garbage CollectionUnderstanding Java Garbage Collection
Understanding Java Garbage Collection
 
Spring Native and Spring AOT
Spring Native and Spring AOTSpring Native and Spring AOT
Spring Native and Spring AOT
 
Loom Virtual Threads in the JDK 19
Loom Virtual Threads in the JDK 19Loom Virtual Threads in the JDK 19
Loom Virtual Threads in the JDK 19
 
[KubeCon EU 2020] containerd Deep Dive
[KubeCon EU 2020] containerd Deep Dive[KubeCon EU 2020] containerd Deep Dive
[KubeCon EU 2020] containerd Deep Dive
 
Introduction to Java Programming Language
Introduction to Java Programming LanguageIntroduction to Java Programming Language
Introduction to Java Programming Language
 
Graal in GraalVM - A New JIT Compiler
Graal in GraalVM - A New JIT CompilerGraal in GraalVM - A New JIT Compiler
Graal in GraalVM - A New JIT Compiler
 
Version Control with Git
Version Control with GitVersion Control with Git
Version Control with Git
 
Gradle - the Enterprise Automation Tool
Gradle  - the Enterprise Automation ToolGradle  - the Enterprise Automation Tool
Gradle - the Enterprise Automation Tool
 
Git.pptx
Git.pptxGit.pptx
Git.pptx
 
Top 10 reasons to migrate to Gradle
Top 10 reasons to migrate to GradleTop 10 reasons to migrate to Gradle
Top 10 reasons to migrate to Gradle
 
Spring Boot 3 And Beyond
Spring Boot 3 And BeyondSpring Boot 3 And Beyond
Spring Boot 3 And Beyond
 
Advanced Git Presentation By Swawibe
Advanced Git Presentation By SwawibeAdvanced Git Presentation By Swawibe
Advanced Git Presentation By Swawibe
 
GraalVM: Run Programs Faster Everywhere
GraalVM: Run Programs Faster EverywhereGraalVM: Run Programs Faster Everywhere
GraalVM: Run Programs Faster Everywhere
 

En vedette

Introduction on Data Science
Introduction on Data ScienceIntroduction on Data Science
Introduction on Data Science
Edureka!
 
Aspek spiritual resort based management
Aspek spiritual resort based managementAspek spiritual resort based management
Aspek spiritual resort based management
Sudirman Sultan
 
Presentasi database terdistribusi new 2
Presentasi database terdistribusi new 2Presentasi database terdistribusi new 2
Presentasi database terdistribusi new 2
ichallan
 

En vedette (20)

An Introduction to JVM Internals and Garbage Collection in Java
An Introduction to JVM Internals and Garbage Collection in JavaAn Introduction to JVM Internals and Garbage Collection in Java
An Introduction to JVM Internals and Garbage Collection in Java
 
Jvm internals
Jvm internalsJvm internals
Jvm internals
 
3. jvm
3. jvm3. jvm
3. jvm
 
Jvm gc那点事
Jvm gc那点事Jvm gc那点事
Jvm gc那点事
 
Inside Android's Dalvik VM - NEJUG Nov 2011
Inside Android's Dalvik VM - NEJUG Nov 2011Inside Android's Dalvik VM - NEJUG Nov 2011
Inside Android's Dalvik VM - NEJUG Nov 2011
 
Java Virtual Machine - Internal Architecture
Java Virtual Machine - Internal ArchitectureJava Virtual Machine - Internal Architecture
Java Virtual Machine - Internal Architecture
 
CS6270 Virtual Machines - Java Virtual Machine Architecture and APIs
CS6270 Virtual Machines - Java Virtual Machine Architecture and APIsCS6270 Virtual Machines - Java Virtual Machine Architecture and APIs
CS6270 Virtual Machines - Java Virtual Machine Architecture and APIs
 
Java gc and JVM optimization
Java gc  and JVM optimizationJava gc  and JVM optimization
Java gc and JVM optimization
 
Java virtual machine
Java virtual machineJava virtual machine
Java virtual machine
 
Understanding the Dalvik Virtual Machine
Understanding the Dalvik Virtual MachineUnderstanding the Dalvik Virtual Machine
Understanding the Dalvik Virtual Machine
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Java beans
Java beansJava beans
Java beans
 
Introduction to Data Science and Analytics
Introduction to Data Science and AnalyticsIntroduction to Data Science and Analytics
Introduction to Data Science and Analytics
 
Introduction on Data Science
Introduction on Data ScienceIntroduction on Data Science
Introduction on Data Science
 
Architectural Patterns and Software Architectures: Client-Server, Multi-Tier,...
Architectural Patterns and Software Architectures: Client-Server, Multi-Tier,...Architectural Patterns and Software Architectures: Client-Server, Multi-Tier,...
Architectural Patterns and Software Architectures: Client-Server, Multi-Tier,...
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Aspek spiritual resort based management
Aspek spiritual resort based managementAspek spiritual resort based management
Aspek spiritual resort based management
 
Global summit full agenda 1 (1)
Global summit full agenda 1 (1)Global summit full agenda 1 (1)
Global summit full agenda 1 (1)
 
SLO County Hospitality Social Media Report 2012
SLO County Hospitality Social Media Report 2012SLO County Hospitality Social Media Report 2012
SLO County Hospitality Social Media Report 2012
 
Presentasi database terdistribusi new 2
Presentasi database terdistribusi new 2Presentasi database terdistribusi new 2
Presentasi database terdistribusi new 2
 

Similaire à Quick introduction to Java Garbage Collector (JVM GC)

Similaire à Quick introduction to Java Garbage Collector (JVM GC) (20)

JVM Performance Tuning
JVM Performance TuningJVM Performance Tuning
JVM Performance Tuning
 
Java and cgroups eng
Java and cgroups engJava and cgroups eng
Java and cgroups eng
 
Jvm is-your-friend
Jvm is-your-friendJvm is-your-friend
Jvm is-your-friend
 
Java programing considering performance
Java programing considering performanceJava programing considering performance
Java programing considering performance
 
Introduction of Java GC Tuning and Java Java Mission Control
Introduction of Java GC Tuning and Java Java Mission ControlIntroduction of Java GC Tuning and Java Java Mission Control
Introduction of Java GC Tuning and Java Java Mission Control
 
Java 2
Java 2Java 2
Java 2
 
Software Profiling: Java Performance, Profiling and Flamegraphs
Software Profiling: Java Performance, Profiling and FlamegraphsSoftware Profiling: Java Performance, Profiling and Flamegraphs
Software Profiling: Java Performance, Profiling and Flamegraphs
 
Java performance tuning
Java performance tuningJava performance tuning
Java performance tuning
 
Javasession10
Javasession10Javasession10
Javasession10
 
Jvm problem diagnostics
Jvm problem diagnosticsJvm problem diagnostics
Jvm problem diagnostics
 
Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...
Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...
Controlling Memory Footprint at All Layers: Linux Kernel, Applications, Libra...
 
Towards "write once - run whenever possible" with Safety Critical Java af Ben...
Towards "write once - run whenever possible" with Safety Critical Java af Ben...Towards "write once - run whenever possible" with Safety Critical Java af Ben...
Towards "write once - run whenever possible" with Safety Critical Java af Ben...
 
Modern Java Concurrency (OSCON 2012)
Modern Java Concurrency (OSCON 2012)Modern Java Concurrency (OSCON 2012)
Modern Java Concurrency (OSCON 2012)
 
Profiler Guided Java Performance Tuning
Profiler Guided Java Performance TuningProfiler Guided Java Performance Tuning
Profiler Guided Java Performance Tuning
 
Basics of JVM Tuning
Basics of JVM TuningBasics of JVM Tuning
Basics of JVM Tuning
 
Stack Frame Protection
Stack Frame ProtectionStack Frame Protection
Stack Frame Protection
 
Java and the JVM
Java and the JVMJava and the JVM
Java and the JVM
 
Looming Marvelous - Virtual Threads in Java Javaland.pdf
Looming Marvelous - Virtual Threads in Java Javaland.pdfLooming Marvelous - Virtual Threads in Java Javaland.pdf
Looming Marvelous - Virtual Threads in Java Javaland.pdf
 
A quick view about Java Virtual Machine
A quick view about Java Virtual MachineA quick view about Java Virtual Machine
A quick view about Java Virtual Machine
 
Performance optimization techniques for Java code
Performance optimization techniques for Java codePerformance optimization techniques for Java code
Performance optimization techniques for Java code
 

Plus de Marcos García (6)

Puts and calls in stock options
Puts and calls in stock optionsPuts and calls in stock options
Puts and calls in stock options
 
Cloud economics design, capacity and operational concerns
Cloud economics  design, capacity and operational concernsCloud economics  design, capacity and operational concerns
Cloud economics design, capacity and operational concerns
 
Welcome to icehouse
Welcome to icehouseWelcome to icehouse
Welcome to icehouse
 
Initial presentation of swift (for montreal user group)
Initial presentation of swift (for montreal user group)Initial presentation of swift (for montreal user group)
Initial presentation of swift (for montreal user group)
 
Initial presentation of openstack (for montreal user group)
Initial presentation of openstack (for montreal user group)Initial presentation of openstack (for montreal user group)
Initial presentation of openstack (for montreal user group)
 
Solr features
Solr featuresSolr features
Solr features
 

Dernier

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Dernier (20)

Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 

Quick introduction to Java Garbage Collector (JVM GC)

  • 1. JVM and Garbage Collection by marcos.garcia@savoirfairelinux.com, Jan 2013
  • 2. JVM? ● Bytecode interpreter http://viralpatel.net/blogs/java-virtual-machine-an-inside-story/
  • 3. JVM Memory Vocabulary ● Runtime data areas – PC register: ● One for each thread ● Points to current execution code of each thread – JVM stacks ● One dedicated stack for each thread ● Holds many stack frames, one for each invoked method – Every frame has 3 registers – Heap ● Shared among all threads ● Stores Java objects. ● Cleaned up by GC – Method area ● Shared among all threads ● Contains method code (class implementations) ● Has a Runtime constant pool – Native method stack (just for “native methods” http://docs.oracle.com/javase/specs/jvms/se7/html/jvms-2.html#jvms-2.5
  • 4. JVM Stack ● Stack Frame – Used to store data and partial results, as well as to perform dynamic linking, return values for methods, and dispatch exceptions. – Describes all the needed information to run a method, including current method stack as well as other JVM shared spaces ● Stack Frame registers (one per method being executed) – Local Vars, used by current method invocation – Frame data / Execution environment, used for internal stack operations – Optop / Operand stack (for bytecode), reference to runtime constant pool ● It is a LIFO stack, need push/pop operations http://performeister.tistory.com/38
  • 5. JVM Heap ● Two heap memory types ● Other memory – Young Generation Memory – Permanent Generation ● To/From Survivor spaces – Native memory (because of ● Eden space native memory references, – Old Generation Memory to the underlying OS)
  • 6. Garbage collection ● Principle: Generational collection or “weak generational hypothesis” – Most allocated objects are not referenced (considered live) for long, that is, they die young – Few references from older to younger objects exist ● Minor GC – Young generation collections occur relatively frequently and are efficient and fast because the young generation space is usually small and likely to contain a lot of objects that are no longer referenced. ● Major GC – Objects that survive some number of young generation collections are eventually promoted, or tenured, to the old generation http://www.oracle.com/technetwork/java/javase/tech/memorymanagement-whitepaper-1-150020.pdf
  • 7. Young/Old Memory explained ● Young Space – Eden ● Any object created inside a method or as a class variable – 2 survivor spaces (From/To) ● Objects in use, that have survived at least one Minor GC ● 1 space empty, other full. Swaps on every GC pass ● Old (Tenured) – Objects referenced since a long time ago, still being used – Very big objects are created directly in Old space http://java-espresso.blogspot.ca/2011/05/heap-structure-in-jvm.html
  • 8. GC example ● Serial Collector (not currently used in modern JVM) http://www.oracle.com/technetwork/java/javase/tech/memorymanagement-whitepaper-1-150020.pdf
  • 9. Parallel and CMS GC ● CMS is the most used GC implementation
  • 10. Heap fragmentation ● We need contiguous space for memory allocation ● GC also relocates (called compactation) objects to reduce fragmentation
  • 11. G1 collector (JDK 6 & 7) ● Garbage-First (G1) collector: server-style garbage collector, targeted for multi-processor machines with large memories. ● It meets garbage collection (GC) pause time goals with a high probability, while achieving high throughput. Designed for applications that: – Can operate concurrently with applications threads like the CMS collector. – Compact free space without lengthy GC induced pause times. – Need more predictable GC pause durations. – Do not want to sacrifice a lot of throughput performance. – Do not require a much larger Java heap. ● G1 is planned as the long term replacement for the Concurrent Mark-Sweep Collector (CMS). ● Better than CMS. – G1 is a compacting collector. G1 compacts sufficiently to completely avoid the use of fine-grained free lists for allocation, and instead relies on regions. This considerably simplifies parts of the collector, and mostly eliminates potential fragmentation issues. – G1 offers more predictable garbage collection pauses than the CMS collector, and allows users to specify desired pause targets. http://www.oracle.com/webfolder/technetwork/tutorials/obe/java/G1GettingStarted/index.html
  • 13. Heap evolution ● Regular case ● OOM case Tool: jconsole
  • 14. Heap evolution ● Regular case ● OOM case Tool: websphere resource analyzer