SlideShare ist ein Scribd-Unternehmen logo
1 von 39
CRAMM: Virtual Memory Support for Garbage-Collected Applications Ting Yang, Emery Berger, Scott Kaplan † , Eliot Moss Department of Computer Science  Dept. of Math and Computer Science † University of Massachusetts  Amherst College  {tingy,emery,moss}@cs.umass.edu  [email_address]
Motivation: Heap Size Matters ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],Heap Size (120MB) Memory (100MB) JVM VM/OS Disk Heap Size ( 6 0MB) Memory (100MB)
What is the right heap size? ,[object Object],[object Object],[object Object],[object Object],CRAMM:  C ooperative  R obust  A utomatic  M emory  M anagement Goal : through cooperation with OS & GC, keep garbage-collected applications running at their sweet spot
CRAMM Overview ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Outline ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
GC : How do we choose a good  heap size?
GC: Collector-neutral model SemiSpace  (copying) a  ≈  ½ b  ≈  JVM, code + app’s live size heapUtilFactor:  constant dependent on GC algorithm Fixed overhead : Libraries, codes, copying (app’s live size)
GC: a collector-neutral WSS model SemiSpace  (copying) MS  (non-copying) a  ≈  ½ b  ≈  JVM, code + app’s live size a  ≈  1 b  ≈  JVM, code heapUtilFactor:  constant dependent on GC algorithm Fixed overhead : Libraries, codes, copying (app’s live size)
GC: Selecting new heap size GC:  heapUtilFactor (a)  &  cur_heapSize   VMM:  WSS  &  available memory Set heap size so that working set just fits  in current available memory
Heap Size vs. Execution time, WSS 1/x shape Y=0.99*X + 32.56 Linear shape
VM : How do we collect information to support heap size selection? (with low overhead) WSS, Available Memory
Calculating WSS w.r.t 5% Memory reference sequence LRU Queue Pages in Least Recently Used order Hit Histogram Fault Curve 1 14 5 1 1 14 11 4 Associated with each LRU position pages faults d e f g h i j k l m n c k l m n c b c d e f g h i j k l m n c k l m n a b a a b c d e f g h i j k l m n a b c d e f g h i j k l m n a b d e f g h i j c k l n m a b c d e f g h i j k m n l a b c d e f g h i j l m n k a b d e f g h i j k l m n c 4 n 3 2 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 m n l m n k l m n c k l m n a b c d e f g h i j k l m n c k l m n
Computing hit histogram ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Managing pages for a process Active (CLOCK) Inactive  (LRU) Evicted  (LRU)   Major  fault Evicted Refill & Adjustment Minor fault Pages protected by turning off permissions (minor fault) Pages evicted to disk. (major fault) Histogram Pages faults Header Page Des AVL node
Controlling overhead Buffer Active (CLOCK) Inactive  (LRU) Evicted  (LRU)   Pages protected by turning off permissions (minor fault) Pages evicted to disk. (major fault) Histogram Pages faults control the boundary:  1% of execution time Header Page Des AVL node
Calculating available memory ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Experimental Results
Experimental Evaluation ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Dynamic Memory Pressure (1)   stock w/o pressure 296.67 secs 1136 majflts CRAMM w/ pressure  302.53 secs 1613 majflts 98% CPU Stock w/ pressure   720.11 secs 39944 majflts 48% CPU I nitial heap size: 120MB Elapsed Time (seconds) GenMS  –  SPECjbb (Modified) w/ 160M memory s tock w/o pressure CRAMM  w/ pressure # transactions finished (thousands) S tock w/ pressure
Dynamic Memory Pressure (2)  SPECjbb (modified): Normalized Elapsed Time JRockit HotSpot CRAMM-GenMS CRAMM-MS CRAMM-SS HotSpot JRockit # transactions finished (thousands)
CRAMM VM: Efficiency   Overhead: on average, 1% - 2.5% CRAMM VM Overhead 0 0.5 1 1.5 2 2.5 3 3.5 4 SPEC2Kint SPEC2Kfp Java- GenCopy Java- SemiSpace Java- MarkSweep Java-GenMS Java- CopyMS % Overhead Additional Overhead Histogram Collection
Conclusion ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
 
Backup Slides ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Characterizing Paging Behavior Memory reference sequence LRU Queue Pages in Least Recently Used order Hit Histogram Fault Curve 1 14 5 1 1 14 11 4 12 pages 5 pages Associated with each LRU position d e f g h i j k l m n c k l m n c b c d e f g h i j k l m n c k l m n a b a a b c d e f g h i j k l m n a b c d e f g h i j k l m n a b d e f g h i j c k l n m a b c d e f g h i j k m n l a b c d e f g h i j l m n k a b d e f g h i j k l m n c 4 n 3 2 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 m n l m n k l m n c k l m n a b c d e f g h i j k l m n c k l m n
Heap Size = 240Mb Memory = 145Mb # of Faults  ≈  1000 50 seconds extreme paging substantial paging: “ looping” behavior fits into memory Fault curve: Relationship of heap size, real memory & page faults Heap size= 0.5 second
VMM design: SegQ LRU Queue Hit Histogram Active Inactive Evicted Active / Inactive Boundary CLOCK algorithm Strict LRU ,[object Object],Major fault (on disk) Minor fault (in memory) 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
VMM design: SegQ Active Inactive Evicted Active / Inactive Boundary CLOCK algorithm Strict LRU WSS What is the WSS w.r.t 5%? 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
CRAMM System: Demo JVM Memory (150MB) Other Apps Heap Size (120MB) Need  6 0MB memory Polling Memory Status GC: Memory exhausted, triggers a full collection … Collection Finished GC: Collection is finished; Memory is released VM: Calculates app’s WSS and Available memory WSS, Available Memory GC: Choose a new heap size using WSS model Heap Size ( 1 00 MB) Heap Size ( 90 MB) Heap Size ( 150 MB) VM M GC: Shrinks the heap size again Other apps finished GC: Grows the heap size to make better use of memory
CRAMM VM: Control overhead ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
CRAMM vs. Bookmarking Collector ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Static Memory Pressure optimal
Dynamic Memory Pressure (1) Initial heap size: 120MB stock w/o pressure 336.17 secs 1136 majflts CRAMM w/ pressure  386.88 secs 1179 majflts 98% CPU Stock w/ pressure   928.49 secs 47941 majflts 36% CPU
Dynamic Memory Pressure (1) Available memory Heap size Sample after every collection adaptive
Dynamic Memory Pressure (3)
Appel _213_javac 60MB real memory Too small: GC a lot Too large: page a lot Optimal Problem & Motivation Heap size  vs  Running time
Manage processes/files ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Behind the WSS model? ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],the amount of memory needed so that the time spent on page faults is lower than certain percent of total execution time. (5%)
GC gives more choices ! Non-GCed Application GCed Application W(k,t) k k W(k,t) Heap: 20MB Heap: 30MB Heap: 45MB Heap: 65MB Working Set Size  W(k, t) : at time  t , the set of all pages used  k  most recent references Memory pressure  , scan frequency  , k  , WSS  , more pages can be evicted, page faults  , running time  Larger search space. Change heap size, change WSS, avoid page faults, less impact on running time Hmm… a search problem! Search Criteria   Working Set Size: The amount of memory needed so that the time spent on page faults is lower than certain percent of total execution time. (typical  value: 5%)

Weitere ähnliche Inhalte

Was ist angesagt?

Solving Multi-tenancy and G1GC in Apache HBase
Solving Multi-tenancy and G1GC in Apache HBase Solving Multi-tenancy and G1GC in Apache HBase
Solving Multi-tenancy and G1GC in Apache HBase HBaseCon
 
Deep dive into PostgreSQL statistics.
Deep dive into PostgreSQL statistics.Deep dive into PostgreSQL statistics.
Deep dive into PostgreSQL statistics.Alexey Lesovsky
 
Java 어플리케이션 성능튜닝 Part1
Java 어플리케이션 성능튜닝 Part1Java 어플리케이션 성능튜닝 Part1
Java 어플리케이션 성능튜닝 Part1상욱 송
 
Antonios Giannopoulos Percona 2016 WiredTiger Configuration Variables
Antonios Giannopoulos Percona 2016 WiredTiger Configuration VariablesAntonios Giannopoulos Percona 2016 WiredTiger Configuration Variables
Antonios Giannopoulos Percona 2016 WiredTiger Configuration VariablesAntonios Giannopoulos
 
Mastering java in containers - MadridJUG
Mastering java in containers - MadridJUGMastering java in containers - MadridJUG
Mastering java in containers - MadridJUGJorge Morales
 
On heap cache vs off-heap cache
On heap cache vs off-heap cacheOn heap cache vs off-heap cache
On heap cache vs off-heap cachergrebski
 
Sun jdk 1.6 gc english version
Sun jdk 1.6 gc english versionSun jdk 1.6 gc english version
Sun jdk 1.6 gc english versionbluedavy lin
 
クラウド時代の半導体メモリー技術
クラウド時代の半導体メモリー技術クラウド時代の半導体メモリー技術
クラウド時代の半導体メモリー技術Ryousei Takano
 
20141219 workshop methylation sequencing analysis
20141219 workshop methylation sequencing analysis20141219 workshop methylation sequencing analysis
20141219 workshop methylation sequencing analysisYi-Feng Chang
 
On the way to low latency
On the way to low latencyOn the way to low latency
On the way to low latencyArtem Orobets
 
Scaling Apache Pulsar to 10 Petabytes/Day
Scaling Apache Pulsar to 10 Petabytes/DayScaling Apache Pulsar to 10 Petabytes/Day
Scaling Apache Pulsar to 10 Petabytes/DayScyllaDB
 
Where Did All These Cycles Go?
Where Did All These Cycles Go?Where Did All These Cycles Go?
Where Did All These Cycles Go?ScyllaDB
 
Continuous Go Profiling & Observability
Continuous Go Profiling & ObservabilityContinuous Go Profiling & Observability
Continuous Go Profiling & ObservabilityScyllaDB
 
Pick diamonds from garbage
Pick diamonds from garbagePick diamonds from garbage
Pick diamonds from garbageTier1 App
 
PostgreSQL Troubleshoot On-line, (RITfest 2015 meetup at Moscow, Russia).
PostgreSQL Troubleshoot On-line, (RITfest 2015 meetup at Moscow, Russia).PostgreSQL Troubleshoot On-line, (RITfest 2015 meetup at Moscow, Russia).
PostgreSQL Troubleshoot On-line, (RITfest 2015 meetup at Moscow, Russia).Alexey Lesovsky
 

Was ist angesagt? (20)

Solving Multi-tenancy and G1GC in Apache HBase
Solving Multi-tenancy and G1GC in Apache HBase Solving Multi-tenancy and G1GC in Apache HBase
Solving Multi-tenancy and G1GC in Apache HBase
 
Deep dive into PostgreSQL statistics.
Deep dive into PostgreSQL statistics.Deep dive into PostgreSQL statistics.
Deep dive into PostgreSQL statistics.
 
Java 어플리케이션 성능튜닝 Part1
Java 어플리케이션 성능튜닝 Part1Java 어플리케이션 성능튜닝 Part1
Java 어플리케이션 성능튜닝 Part1
 
Antonios Giannopoulos Percona 2016 WiredTiger Configuration Variables
Antonios Giannopoulos Percona 2016 WiredTiger Configuration VariablesAntonios Giannopoulos Percona 2016 WiredTiger Configuration Variables
Antonios Giannopoulos Percona 2016 WiredTiger Configuration Variables
 
Mastering java in containers - MadridJUG
Mastering java in containers - MadridJUGMastering java in containers - MadridJUG
Mastering java in containers - MadridJUG
 
On heap cache vs off-heap cache
On heap cache vs off-heap cacheOn heap cache vs off-heap cache
On heap cache vs off-heap cache
 
Sun jdk 1.6 gc english version
Sun jdk 1.6 gc english versionSun jdk 1.6 gc english version
Sun jdk 1.6 gc english version
 
Thanos - Prometheus on Scale
Thanos - Prometheus on ScaleThanos - Prometheus on Scale
Thanos - Prometheus on Scale
 
クラウド時代の半導体メモリー技術
クラウド時代の半導体メモリー技術クラウド時代の半導体メモリー技術
クラウド時代の半導体メモリー技術
 
20141219 workshop methylation sequencing analysis
20141219 workshop methylation sequencing analysis20141219 workshop methylation sequencing analysis
20141219 workshop methylation sequencing analysis
 
jvm goes to big data
jvm goes to big datajvm goes to big data
jvm goes to big data
 
On the way to low latency
On the way to low latencyOn the way to low latency
On the way to low latency
 
Scaling Apache Pulsar to 10 Petabytes/Day
Scaling Apache Pulsar to 10 Petabytes/DayScaling Apache Pulsar to 10 Petabytes/Day
Scaling Apache Pulsar to 10 Petabytes/Day
 
Where Did All These Cycles Go?
Where Did All These Cycles Go?Where Did All These Cycles Go?
Where Did All These Cycles Go?
 
Continuous Go Profiling & Observability
Continuous Go Profiling & ObservabilityContinuous Go Profiling & Observability
Continuous Go Profiling & Observability
 
Pick diamonds from garbage
Pick diamonds from garbagePick diamonds from garbage
Pick diamonds from garbage
 
Doc5
Doc5Doc5
Doc5
 
PostgreSQL Troubleshoot On-line, (RITfest 2015 meetup at Moscow, Russia).
PostgreSQL Troubleshoot On-line, (RITfest 2015 meetup at Moscow, Russia).PostgreSQL Troubleshoot On-line, (RITfest 2015 meetup at Moscow, Russia).
PostgreSQL Troubleshoot On-line, (RITfest 2015 meetup at Moscow, Russia).
 
[BGOUG] Java GC - Friend or Foe
[BGOUG] Java GC - Friend or Foe[BGOUG] Java GC - Friend or Foe
[BGOUG] Java GC - Friend or Foe
 
Pgcenter overview
Pgcenter overviewPgcenter overview
Pgcenter overview
 

Andere mochten auch

Information Systems and Technologies used in the framework of the TIR Convention
Information Systems and Technologies used in the framework of the TIR ConventionInformation Systems and Technologies used in the framework of the TIR Convention
Information Systems and Technologies used in the framework of the TIR ConventionJosé Ferreiro
 
Retos de los CIOs
Retos de los CIOsRetos de los CIOs
Retos de los CIOsMax Ugaz
 
Termostato wifi para controlar calefacción desde tu Smartphone
Termostato wifi para controlar calefacción desde tu SmartphoneTermostato wifi para controlar calefacción desde tu Smartphone
Termostato wifi para controlar calefacción desde tu SmartphoneAlberto Vázquez Garea
 
Tecnología invisible,para producir mentes activas
Tecnología invisible,para producir mentes activasTecnología invisible,para producir mentes activas
Tecnología invisible,para producir mentes activasSuham S. Reyes
 
TP
TPTP
TPJuan
 
Transistores
TransistoresTransistores
Transistoressimonvall
 
Personalisatie en synchronisatie tussen Magento webshop en Copernica
Personalisatie en synchronisatie tussen Magento webshop en CopernicaPersonalisatie en synchronisatie tussen Magento webshop en Copernica
Personalisatie en synchronisatie tussen Magento webshop en CopernicaCopernica BV
 
Annac, st. john,miller,ostertaag combined pp ccp13 ccp13
Annac, st. john,miller,ostertaag combined pp ccp13 ccp13Annac, st. john,miller,ostertaag combined pp ccp13 ccp13
Annac, st. john,miller,ostertaag combined pp ccp13 ccp13bio-link
 
Tm call free & sms free
Tm call free & sms freeTm call free & sms free
Tm call free & sms freeFadhil Bangi
 
De ciencia ficcion_a_ciencia_real_tecnologias_emergentes
De ciencia ficcion_a_ciencia_real_tecnologias_emergentesDe ciencia ficcion_a_ciencia_real_tecnologias_emergentes
De ciencia ficcion_a_ciencia_real_tecnologias_emergentesJim "Brodie" Brazell
 
Gilbs agile principles and values agilia conf keynote brno cz march 27 2013
Gilbs agile principles and values agilia conf keynote brno cz march 27 2013Gilbs agile principles and values agilia conf keynote brno cz march 27 2013
Gilbs agile principles and values agilia conf keynote brno cz march 27 2013tom gilb
 
Hirikilabs How To Make 01: Enabling the Future
Hirikilabs How To Make 01: Enabling the FutureHirikilabs How To Make 01: Enabling the Future
Hirikilabs How To Make 01: Enabling the FutureTabakaleraDonostia
 
Cultura Empresarial y Dirección.
Cultura Empresarial y Dirección.Cultura Empresarial y Dirección.
Cultura Empresarial y Dirección.Almudena Valdor
 

Andere mochten auch (20)

Information Systems and Technologies used in the framework of the TIR Convention
Information Systems and Technologies used in the framework of the TIR ConventionInformation Systems and Technologies used in the framework of the TIR Convention
Information Systems and Technologies used in the framework of the TIR Convention
 
Retos de los CIOs
Retos de los CIOsRetos de los CIOs
Retos de los CIOs
 
Termostato wifi para controlar calefacción desde tu Smartphone
Termostato wifi para controlar calefacción desde tu SmartphoneTermostato wifi para controlar calefacción desde tu Smartphone
Termostato wifi para controlar calefacción desde tu Smartphone
 
Tecnología invisible,para producir mentes activas
Tecnología invisible,para producir mentes activasTecnología invisible,para producir mentes activas
Tecnología invisible,para producir mentes activas
 
TP
TPTP
TP
 
Transistores
TransistoresTransistores
Transistores
 
Marketing de afiliación
Marketing de afiliaciónMarketing de afiliación
Marketing de afiliación
 
Personalisatie en synchronisatie tussen Magento webshop en Copernica
Personalisatie en synchronisatie tussen Magento webshop en CopernicaPersonalisatie en synchronisatie tussen Magento webshop en Copernica
Personalisatie en synchronisatie tussen Magento webshop en Copernica
 
Tesiandroid
TesiandroidTesiandroid
Tesiandroid
 
Annac, st. john,miller,ostertaag combined pp ccp13 ccp13
Annac, st. john,miller,ostertaag combined pp ccp13 ccp13Annac, st. john,miller,ostertaag combined pp ccp13 ccp13
Annac, st. john,miller,ostertaag combined pp ccp13 ccp13
 
Tm call free & sms free
Tm call free & sms freeTm call free & sms free
Tm call free & sms free
 
Sedes auca
Sedes aucaSedes auca
Sedes auca
 
De ciencia ficcion_a_ciencia_real_tecnologias_emergentes
De ciencia ficcion_a_ciencia_real_tecnologias_emergentesDe ciencia ficcion_a_ciencia_real_tecnologias_emergentes
De ciencia ficcion_a_ciencia_real_tecnologias_emergentes
 
Gilbs agile principles and values agilia conf keynote brno cz march 27 2013
Gilbs agile principles and values agilia conf keynote brno cz march 27 2013Gilbs agile principles and values agilia conf keynote brno cz march 27 2013
Gilbs agile principles and values agilia conf keynote brno cz march 27 2013
 
Chapter 3 grammar
Chapter 3 grammarChapter 3 grammar
Chapter 3 grammar
 
E tourism
E tourismE tourism
E tourism
 
Asfalttns
AsfalttnsAsfalttns
Asfalttns
 
Hirikilabs How To Make 01: Enabling the Future
Hirikilabs How To Make 01: Enabling the FutureHirikilabs How To Make 01: Enabling the Future
Hirikilabs How To Make 01: Enabling the Future
 
Cultura Empresarial y Dirección.
Cultura Empresarial y Dirección.Cultura Empresarial y Dirección.
Cultura Empresarial y Dirección.
 
Manual margarita
Manual margaritaManual margarita
Manual margarita
 

Ähnlich wie CRAMM: Virtual Memory Support for Garbage-Collected Applications

Native Code & Off-Heap Data Structures for Solr: Presented by Yonik Seeley, H...
Native Code & Off-Heap Data Structures for Solr: Presented by Yonik Seeley, H...Native Code & Off-Heap Data Structures for Solr: Presented by Yonik Seeley, H...
Native Code & Off-Heap Data Structures for Solr: Presented by Yonik Seeley, H...Lucidworks
 
Native Code, Off-Heap Data & JSON Facet API for Solr (Heliosearch)
Native Code, Off-Heap Data & JSON Facet API for Solr (Heliosearch)Native Code, Off-Heap Data & JSON Facet API for Solr (Heliosearch)
Native Code, Off-Heap Data & JSON Facet API for Solr (Heliosearch)Yonik Seeley
 
IMC Summit 2016 Breakout - Per Minoborg - Work with Multiple Hot Terabytes in...
IMC Summit 2016 Breakout - Per Minoborg - Work with Multiple Hot Terabytes in...IMC Summit 2016 Breakout - Per Minoborg - Work with Multiple Hot Terabytes in...
IMC Summit 2016 Breakout - Per Minoborg - Work with Multiple Hot Terabytes in...In-Memory Computing Summit
 
Advanced off heap ipc
Advanced off heap ipcAdvanced off heap ipc
Advanced off heap ipcPeter Lawrey
 
Performance tuning jvm
Performance tuning jvmPerformance tuning jvm
Performance tuning jvmPrem Kuppumani
 
Garbage collection in JVM
Garbage collection in JVMGarbage collection in JVM
Garbage collection in JVMaragozin
 
Jvm problem diagnostics
Jvm problem diagnosticsJvm problem diagnostics
Jvm problem diagnosticsDanijel Mitar
 
제2회난공불락 오픈소스 세미나 커널튜닝
제2회난공불락 오픈소스 세미나 커널튜닝제2회난공불락 오픈소스 세미나 커널튜닝
제2회난공불락 오픈소스 세미나 커널튜닝Tommy Lee
 
Flink Forward Berlin 2017: Robert Metzger - Keep it going - How to reliably a...
Flink Forward Berlin 2017: Robert Metzger - Keep it going - How to reliably a...Flink Forward Berlin 2017: Robert Metzger - Keep it going - How to reliably a...
Flink Forward Berlin 2017: Robert Metzger - Keep it going - How to reliably a...Flink Forward
 
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 FlamegraphsIsuru Perera
 
HotSpot JVM Tuning
HotSpot JVM TuningHotSpot JVM Tuning
HotSpot JVM TuningGilad Garon
 
Distributed caching-computing v3.8
Distributed caching-computing v3.8Distributed caching-computing v3.8
Distributed caching-computing v3.8Rahul Gupta
 
Software Profiling: Understanding Java Performance and how to profile in Java
Software Profiling: Understanding Java Performance and how to profile in JavaSoftware Profiling: Understanding Java Performance and how to profile in Java
Software Profiling: Understanding Java Performance and how to profile in JavaIsuru Perera
 
CPN302 your-linux-ami-optimization-and-performance
CPN302 your-linux-ami-optimization-and-performanceCPN302 your-linux-ami-optimization-and-performance
CPN302 your-linux-ami-optimization-and-performanceCoburn Watson
 
Virtual memory pre-final-formatting
Virtual memory pre-final-formattingVirtual memory pre-final-formatting
Virtual memory pre-final-formattingmarangburu42
 
Introduction to Java performance tuning
Introduction to Java performance tuningIntroduction to Java performance tuning
Introduction to Java performance tuningMarouane Gazanayi
 
State of Java Elasticity. Tuning Java Efficiency - GIDS.JAVA LIVE 2020
State of Java Elasticity. Tuning Java Efficiency - GIDS.JAVA LIVE 2020State of Java Elasticity. Tuning Java Efficiency - GIDS.JAVA LIVE 2020
State of Java Elasticity. Tuning Java Efficiency - GIDS.JAVA LIVE 2020Jelastic Multi-Cloud PaaS
 

Ähnlich wie CRAMM: Virtual Memory Support for Garbage-Collected Applications (20)

Native Code & Off-Heap Data Structures for Solr: Presented by Yonik Seeley, H...
Native Code & Off-Heap Data Structures for Solr: Presented by Yonik Seeley, H...Native Code & Off-Heap Data Structures for Solr: Presented by Yonik Seeley, H...
Native Code & Off-Heap Data Structures for Solr: Presented by Yonik Seeley, H...
 
Native Code, Off-Heap Data & JSON Facet API for Solr (Heliosearch)
Native Code, Off-Heap Data & JSON Facet API for Solr (Heliosearch)Native Code, Off-Heap Data & JSON Facet API for Solr (Heliosearch)
Native Code, Off-Heap Data & JSON Facet API for Solr (Heliosearch)
 
IMC Summit 2016 Breakout - Per Minoborg - Work with Multiple Hot Terabytes in...
IMC Summit 2016 Breakout - Per Minoborg - Work with Multiple Hot Terabytes in...IMC Summit 2016 Breakout - Per Minoborg - Work with Multiple Hot Terabytes in...
IMC Summit 2016 Breakout - Per Minoborg - Work with Multiple Hot Terabytes in...
 
JVM Magic
JVM MagicJVM Magic
JVM Magic
 
Advanced off heap ipc
Advanced off heap ipcAdvanced off heap ipc
Advanced off heap ipc
 
Performance tuning jvm
Performance tuning jvmPerformance tuning jvm
Performance tuning jvm
 
Garbage collection in JVM
Garbage collection in JVMGarbage collection in JVM
Garbage collection in JVM
 
Jvm problem diagnostics
Jvm problem diagnosticsJvm problem diagnostics
Jvm problem diagnostics
 
제2회난공불락 오픈소스 세미나 커널튜닝
제2회난공불락 오픈소스 세미나 커널튜닝제2회난공불락 오픈소스 세미나 커널튜닝
제2회난공불락 오픈소스 세미나 커널튜닝
 
Flink Forward Berlin 2017: Robert Metzger - Keep it going - How to reliably a...
Flink Forward Berlin 2017: Robert Metzger - Keep it going - How to reliably a...Flink Forward Berlin 2017: Robert Metzger - Keep it going - How to reliably a...
Flink Forward Berlin 2017: Robert Metzger - Keep it going - How to reliably a...
 
HBase Accelerated: In-Memory Flush and Compaction
HBase Accelerated: In-Memory Flush and CompactionHBase Accelerated: In-Memory Flush and Compaction
HBase Accelerated: In-Memory Flush and Compaction
 
Basics of JVM Tuning
Basics of JVM TuningBasics of JVM Tuning
Basics of JVM Tuning
 
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
 
HotSpot JVM Tuning
HotSpot JVM TuningHotSpot JVM Tuning
HotSpot JVM Tuning
 
Distributed caching-computing v3.8
Distributed caching-computing v3.8Distributed caching-computing v3.8
Distributed caching-computing v3.8
 
Software Profiling: Understanding Java Performance and how to profile in Java
Software Profiling: Understanding Java Performance and how to profile in JavaSoftware Profiling: Understanding Java Performance and how to profile in Java
Software Profiling: Understanding Java Performance and how to profile in Java
 
CPN302 your-linux-ami-optimization-and-performance
CPN302 your-linux-ami-optimization-and-performanceCPN302 your-linux-ami-optimization-and-performance
CPN302 your-linux-ami-optimization-and-performance
 
Virtual memory pre-final-formatting
Virtual memory pre-final-formattingVirtual memory pre-final-formatting
Virtual memory pre-final-formatting
 
Introduction to Java performance tuning
Introduction to Java performance tuningIntroduction to Java performance tuning
Introduction to Java performance tuning
 
State of Java Elasticity. Tuning Java Efficiency - GIDS.JAVA LIVE 2020
State of Java Elasticity. Tuning Java Efficiency - GIDS.JAVA LIVE 2020State of Java Elasticity. Tuning Java Efficiency - GIDS.JAVA LIVE 2020
State of Java Elasticity. Tuning Java Efficiency - GIDS.JAVA LIVE 2020
 

Mehr von Emery Berger

Doppio: Breaking the Browser Language Barrier
Doppio: Breaking the Browser Language BarrierDoppio: Breaking the Browser Language Barrier
Doppio: Breaking the Browser Language BarrierEmery Berger
 
Dthreads: Efficient Deterministic Multithreading
Dthreads: Efficient Deterministic MultithreadingDthreads: Efficient Deterministic Multithreading
Dthreads: Efficient Deterministic MultithreadingEmery Berger
 
Programming with People
Programming with PeopleProgramming with People
Programming with PeopleEmery Berger
 
Stabilizer: Statistically Sound Performance Evaluation
Stabilizer: Statistically Sound Performance EvaluationStabilizer: Statistically Sound Performance Evaluation
Stabilizer: Statistically Sound Performance EvaluationEmery Berger
 
DieHarder (CCS 2010, WOOT 2011)
DieHarder (CCS 2010, WOOT 2011)DieHarder (CCS 2010, WOOT 2011)
DieHarder (CCS 2010, WOOT 2011)Emery Berger
 
Operating Systems - Advanced File Systems
Operating Systems - Advanced File SystemsOperating Systems - Advanced File Systems
Operating Systems - Advanced File SystemsEmery Berger
 
Operating Systems - File Systems
Operating Systems - File SystemsOperating Systems - File Systems
Operating Systems - File SystemsEmery Berger
 
Operating Systems - Networks
Operating Systems - NetworksOperating Systems - Networks
Operating Systems - NetworksEmery Berger
 
Operating Systems - Queuing Systems
Operating Systems - Queuing SystemsOperating Systems - Queuing Systems
Operating Systems - Queuing SystemsEmery Berger
 
Operating Systems - Distributed Parallel Computing
Operating Systems - Distributed Parallel ComputingOperating Systems - Distributed Parallel Computing
Operating Systems - Distributed Parallel ComputingEmery Berger
 
Operating Systems - Concurrency
Operating Systems - ConcurrencyOperating Systems - Concurrency
Operating Systems - ConcurrencyEmery Berger
 
Operating Systems - Advanced Synchronization
Operating Systems - Advanced SynchronizationOperating Systems - Advanced Synchronization
Operating Systems - Advanced SynchronizationEmery Berger
 
Operating Systems - Synchronization
Operating Systems - SynchronizationOperating Systems - Synchronization
Operating Systems - SynchronizationEmery Berger
 
Processes and Threads
Processes and ThreadsProcesses and Threads
Processes and ThreadsEmery Berger
 
Virtual Memory and Paging
Virtual Memory and PagingVirtual Memory and Paging
Virtual Memory and PagingEmery Berger
 
Operating Systems - Virtual Memory
Operating Systems - Virtual MemoryOperating Systems - Virtual Memory
Operating Systems - Virtual MemoryEmery Berger
 
MC2: High-Performance Garbage Collection for Memory-Constrained Environments
MC2: High-Performance Garbage Collection for Memory-Constrained EnvironmentsMC2: High-Performance Garbage Collection for Memory-Constrained Environments
MC2: High-Performance Garbage Collection for Memory-Constrained EnvironmentsEmery Berger
 
Vam: A Locality-Improving Dynamic Memory Allocator
Vam: A Locality-Improving Dynamic Memory AllocatorVam: A Locality-Improving Dynamic Memory Allocator
Vam: A Locality-Improving Dynamic Memory AllocatorEmery Berger
 
Quantifying the Performance of Garbage Collection vs. Explicit Memory Management
Quantifying the Performance of Garbage Collection vs. Explicit Memory ManagementQuantifying the Performance of Garbage Collection vs. Explicit Memory Management
Quantifying the Performance of Garbage Collection vs. Explicit Memory ManagementEmery Berger
 
Garbage Collection without Paging
Garbage Collection without PagingGarbage Collection without Paging
Garbage Collection without PagingEmery Berger
 

Mehr von Emery Berger (20)

Doppio: Breaking the Browser Language Barrier
Doppio: Breaking the Browser Language BarrierDoppio: Breaking the Browser Language Barrier
Doppio: Breaking the Browser Language Barrier
 
Dthreads: Efficient Deterministic Multithreading
Dthreads: Efficient Deterministic MultithreadingDthreads: Efficient Deterministic Multithreading
Dthreads: Efficient Deterministic Multithreading
 
Programming with People
Programming with PeopleProgramming with People
Programming with People
 
Stabilizer: Statistically Sound Performance Evaluation
Stabilizer: Statistically Sound Performance EvaluationStabilizer: Statistically Sound Performance Evaluation
Stabilizer: Statistically Sound Performance Evaluation
 
DieHarder (CCS 2010, WOOT 2011)
DieHarder (CCS 2010, WOOT 2011)DieHarder (CCS 2010, WOOT 2011)
DieHarder (CCS 2010, WOOT 2011)
 
Operating Systems - Advanced File Systems
Operating Systems - Advanced File SystemsOperating Systems - Advanced File Systems
Operating Systems - Advanced File Systems
 
Operating Systems - File Systems
Operating Systems - File SystemsOperating Systems - File Systems
Operating Systems - File Systems
 
Operating Systems - Networks
Operating Systems - NetworksOperating Systems - Networks
Operating Systems - Networks
 
Operating Systems - Queuing Systems
Operating Systems - Queuing SystemsOperating Systems - Queuing Systems
Operating Systems - Queuing Systems
 
Operating Systems - Distributed Parallel Computing
Operating Systems - Distributed Parallel ComputingOperating Systems - Distributed Parallel Computing
Operating Systems - Distributed Parallel Computing
 
Operating Systems - Concurrency
Operating Systems - ConcurrencyOperating Systems - Concurrency
Operating Systems - Concurrency
 
Operating Systems - Advanced Synchronization
Operating Systems - Advanced SynchronizationOperating Systems - Advanced Synchronization
Operating Systems - Advanced Synchronization
 
Operating Systems - Synchronization
Operating Systems - SynchronizationOperating Systems - Synchronization
Operating Systems - Synchronization
 
Processes and Threads
Processes and ThreadsProcesses and Threads
Processes and Threads
 
Virtual Memory and Paging
Virtual Memory and PagingVirtual Memory and Paging
Virtual Memory and Paging
 
Operating Systems - Virtual Memory
Operating Systems - Virtual MemoryOperating Systems - Virtual Memory
Operating Systems - Virtual Memory
 
MC2: High-Performance Garbage Collection for Memory-Constrained Environments
MC2: High-Performance Garbage Collection for Memory-Constrained EnvironmentsMC2: High-Performance Garbage Collection for Memory-Constrained Environments
MC2: High-Performance Garbage Collection for Memory-Constrained Environments
 
Vam: A Locality-Improving Dynamic Memory Allocator
Vam: A Locality-Improving Dynamic Memory AllocatorVam: A Locality-Improving Dynamic Memory Allocator
Vam: A Locality-Improving Dynamic Memory Allocator
 
Quantifying the Performance of Garbage Collection vs. Explicit Memory Management
Quantifying the Performance of Garbage Collection vs. Explicit Memory ManagementQuantifying the Performance of Garbage Collection vs. Explicit Memory Management
Quantifying the Performance of Garbage Collection vs. Explicit Memory Management
 
Garbage Collection without Paging
Garbage Collection without PagingGarbage Collection without Paging
Garbage Collection without Paging
 

Kürzlich hochgeladen

Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024The Digital Insurer
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024The Digital Insurer
 
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 StreamsRoshan Dwivedi
 
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 organizationRadu Cotescu
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
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)wesley chun
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
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...Martijn de Jong
 
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 Takeoffsammart93
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MIND CTI
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024SynarionITSolutions
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 

Kürzlich hochgeladen (20)

Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
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
 
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
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
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)
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
+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...
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
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...
 
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
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 

CRAMM: Virtual Memory Support for Garbage-Collected Applications

  • 1. CRAMM: Virtual Memory Support for Garbage-Collected Applications Ting Yang, Emery Berger, Scott Kaplan † , Eliot Moss Department of Computer Science Dept. of Math and Computer Science † University of Massachusetts Amherst College {tingy,emery,moss}@cs.umass.edu [email_address]
  • 2.
  • 3.
  • 4.
  • 5.
  • 6. GC : How do we choose a good heap size?
  • 7. GC: Collector-neutral model SemiSpace (copying) a ≈ ½ b ≈ JVM, code + app’s live size heapUtilFactor: constant dependent on GC algorithm Fixed overhead : Libraries, codes, copying (app’s live size)
  • 8. GC: a collector-neutral WSS model SemiSpace (copying) MS (non-copying) a ≈ ½ b ≈ JVM, code + app’s live size a ≈ 1 b ≈ JVM, code heapUtilFactor: constant dependent on GC algorithm Fixed overhead : Libraries, codes, copying (app’s live size)
  • 9. GC: Selecting new heap size GC: heapUtilFactor (a) & cur_heapSize VMM: WSS & available memory Set heap size so that working set just fits in current available memory
  • 10. Heap Size vs. Execution time, WSS 1/x shape Y=0.99*X + 32.56 Linear shape
  • 11. VM : How do we collect information to support heap size selection? (with low overhead) WSS, Available Memory
  • 12. Calculating WSS w.r.t 5% Memory reference sequence LRU Queue Pages in Least Recently Used order Hit Histogram Fault Curve 1 14 5 1 1 14 11 4 Associated with each LRU position pages faults d e f g h i j k l m n c k l m n c b c d e f g h i j k l m n c k l m n a b a a b c d e f g h i j k l m n a b c d e f g h i j k l m n a b d e f g h i j c k l n m a b c d e f g h i j k m n l a b c d e f g h i j l m n k a b d e f g h i j k l m n c 4 n 3 2 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 m n l m n k l m n c k l m n a b c d e f g h i j k l m n c k l m n
  • 13.
  • 14. Managing pages for a process Active (CLOCK) Inactive (LRU) Evicted (LRU) Major fault Evicted Refill & Adjustment Minor fault Pages protected by turning off permissions (minor fault) Pages evicted to disk. (major fault) Histogram Pages faults Header Page Des AVL node
  • 15. Controlling overhead Buffer Active (CLOCK) Inactive (LRU) Evicted (LRU) Pages protected by turning off permissions (minor fault) Pages evicted to disk. (major fault) Histogram Pages faults control the boundary: 1% of execution time Header Page Des AVL node
  • 16.
  • 18.
  • 19. Dynamic Memory Pressure (1) stock w/o pressure 296.67 secs 1136 majflts CRAMM w/ pressure 302.53 secs 1613 majflts 98% CPU Stock w/ pressure 720.11 secs 39944 majflts 48% CPU I nitial heap size: 120MB Elapsed Time (seconds) GenMS – SPECjbb (Modified) w/ 160M memory s tock w/o pressure CRAMM w/ pressure # transactions finished (thousands) S tock w/ pressure
  • 20. Dynamic Memory Pressure (2) SPECjbb (modified): Normalized Elapsed Time JRockit HotSpot CRAMM-GenMS CRAMM-MS CRAMM-SS HotSpot JRockit # transactions finished (thousands)
  • 21. CRAMM VM: Efficiency Overhead: on average, 1% - 2.5% CRAMM VM Overhead 0 0.5 1 1.5 2 2.5 3 3.5 4 SPEC2Kint SPEC2Kfp Java- GenCopy Java- SemiSpace Java- MarkSweep Java-GenMS Java- CopyMS % Overhead Additional Overhead Histogram Collection
  • 22.
  • 23.  
  • 24.
  • 25. Characterizing Paging Behavior Memory reference sequence LRU Queue Pages in Least Recently Used order Hit Histogram Fault Curve 1 14 5 1 1 14 11 4 12 pages 5 pages Associated with each LRU position d e f g h i j k l m n c k l m n c b c d e f g h i j k l m n c k l m n a b a a b c d e f g h i j k l m n a b c d e f g h i j k l m n a b d e f g h i j c k l n m a b c d e f g h i j k m n l a b c d e f g h i j l m n k a b d e f g h i j k l m n c 4 n 3 2 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 m n l m n k l m n c k l m n a b c d e f g h i j k l m n c k l m n
  • 26. Heap Size = 240Mb Memory = 145Mb # of Faults ≈ 1000 50 seconds extreme paging substantial paging: “ looping” behavior fits into memory Fault curve: Relationship of heap size, real memory & page faults Heap size= 0.5 second
  • 27.
  • 28. VMM design: SegQ Active Inactive Evicted Active / Inactive Boundary CLOCK algorithm Strict LRU WSS What is the WSS w.r.t 5%? 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
  • 29. CRAMM System: Demo JVM Memory (150MB) Other Apps Heap Size (120MB) Need 6 0MB memory Polling Memory Status GC: Memory exhausted, triggers a full collection … Collection Finished GC: Collection is finished; Memory is released VM: Calculates app’s WSS and Available memory WSS, Available Memory GC: Choose a new heap size using WSS model Heap Size ( 1 00 MB) Heap Size ( 90 MB) Heap Size ( 150 MB) VM M GC: Shrinks the heap size again Other apps finished GC: Grows the heap size to make better use of memory
  • 30.
  • 31.
  • 33. Dynamic Memory Pressure (1) Initial heap size: 120MB stock w/o pressure 336.17 secs 1136 majflts CRAMM w/ pressure 386.88 secs 1179 majflts 98% CPU Stock w/ pressure 928.49 secs 47941 majflts 36% CPU
  • 34. Dynamic Memory Pressure (1) Available memory Heap size Sample after every collection adaptive
  • 36. Appel _213_javac 60MB real memory Too small: GC a lot Too large: page a lot Optimal Problem & Motivation Heap size vs Running time
  • 37.
  • 38.
  • 39. GC gives more choices ! Non-GCed Application GCed Application W(k,t) k k W(k,t) Heap: 20MB Heap: 30MB Heap: 45MB Heap: 65MB Working Set Size W(k, t) : at time t , the set of all pages used k most recent references Memory pressure , scan frequency , k , WSS , more pages can be evicted, page faults , running time Larger search space. Change heap size, change WSS, avoid page faults, less impact on running time Hmm… a search problem! Search Criteria Working Set Size: The amount of memory needed so that the time spent on page faults is lower than certain percent of total execution time. (typical value: 5%)