Java memory compression - PowerPoint PPT Presentation

1 / 16
About This Presentation
Title:

Java memory compression

Description:

Related techniques for Java small memory footprints. Why ... (hardware de/compression, fast garbage collection: start-stop algo. Interact, hard real-time req. ... – PowerPoint PPT presentation

Number of Views:43
Avg rating:3.0/5.0
Slides: 17
Provided by: mayu9
Category:

less

Transcript and Presenter's Notes

Title: Java memory compression


1
Java memory compression
  • Mayumi KATO, PhD. student
  • Committee members
  • Dr. Chia-Tien Dan Lo , Chairperson
  • Dr. Kay A. Robbins
  • Dr. Tom Bylander
  • Dr. Dakai Zhu
  • September 29, 2005
  • Department of Computer Science,
  • The University of Texas at San Antonio

2
Outline
  • Motivation
  • Why study Java?
  • Related techniques for Java small memory
    footprints
  • Why study compressed heap?
  • Work in progress and work to be studied
  • Feasible improvements

3
Motivation
  • Power consumption
  • Main memory SPM processor (Dynamic energy,
    leakage energy)
  • Processor 10
  • Memory leakage energy consumption 61.74
  • Read-only portion 62.42
  • Energy saving 20.9
  • Overall energy saving 10
  • How about on RAM?
  • (compression? save memory? power ?)
  • Java technology is predicted to be integrated
    into
  • 74 of wireless phones in 2007
  • (how many number for all embedded devices?)
  • More and more applications are high memory
    demand, for example,
  • Mobile-commerce(64KB),
  • EmailViewer(256KB),
  • WebViewer(256KB),
  • video/audio services (64KB) to JBenchmark(Nokia,
    Motorola)
  • JBenchmark1.0 (116KB, 830KB)
  • JBenchmark2D (189KB, 865KB)
  • JBenchmark3D (627KB, 837KB)
  • http//jbenchmark.com

Offline compression runtime decompression
On-the-fly compression and decompression
4
Why study Java?
Attractive Java mobile/wireless applications
small memory embedded device.
Demand a huge amount of memory
Out of memory failure
Solutions
Increase memory capacity
Physical memory space limited
Reduce memory demands
Allow application to run
Solutions in practice
Optimized interpreter
Small memory footprints
Problems
Still much for small memory embedded systems
Need some techniques to further reduce
memory footprints
(demands)
5
  • Optimization technique for Java small memory
    footprints
  • Heap is mapped on memory
  • Heap shares characteristics of memory/cache
  • Can In-memory/cache compression technique be
    applied to Java heap?

2575 of the Jarfile 75KB120KB per second
Java classfile compression Pugh99
Java byecode compression
85 (15 saving) with speed penalty of 2 30
Offline
Factrization to instructions Calusen et al. 00
Related Work Optimization technique for Java
small memory footprints
Grammar-based compression Evans and Fraser 01
11KB of extra space for the interpreter generated
(using gcc as input) 900KB memory space saving
for bytecode
Constant pool compaction Ripper et al. 04
Runtime
Java In The Small (JITS), Constant pool could be
reduced up to 7.78
Profile-driven code unloading Zhang and Krints
04
50 code space saving with less than 1 of
overhead
Runtime decompression Chen et al. 02
A word-based approach using a dictionary
In-cache compression Wilson et al. 99
Reduce the leakage energy consumption
6
Why study compressed heap?
Domain of memory footprints problems
Permanent memory space
To run application
A Java virtual machine (interpreter)
Heap space
Permanent memory space can be optimized by
offline traditional optimization technique
(Compile, programming language optimization,
file-to-file compression)
Heap space?
Dynamic behaviors at runtime
NOT able to use offline traditional optimization
Need some optimization mechanisms for the heap
space
7
Java memory compression
  • Goals
  • To reduce on-the-fly heap memory demands for
    large Java application
  • run on mobile/wireless devices with small memory
    capacity
  • To minimize the number of active memory banks by
    turning off unused banks
  • eliminate leakage currents in memory systems
  • To minimize the overhead in speed and memory by
    hardware/software codesign

Optimization Technique Introduce a compression
technique to Java heap in Java virtual
machine Propose computation mechanisms with
hardware/software co-design (Java memory
compression)
8
Difficulty Come form dynamic behaviors of
objects that created and accessed at runtime Key
issue How to capture dynamic behaviors and how to
feed them back to memory management Contributions
Provide memory saving that has not been achieved
by offline optimization in the fields of
compiler, programming language and file-to-file
compression Can be used with any of the rich
offline optimization
Benefits Memory saving Low power
consumption Challenges To find a good balance
between speed, memory saving and power
consumption We believe Java heap compression is
a new direction of object-oriented
language
9
Work in progress and work to be
studied
  • Achievement
  • 2002 fall
  • Java, compression, garbage collection
  • 2002-2003 (CCCT03 and ISAS03)
  • Java, memory compression, power consumption
  • 2003-2004 (PPPJ04, ISICT04, IPCC04)
  • Configuration I having Java heap compression
    without garbage collection
  • Domain research
  • 2004-2005 (ITCC05, FCCM05)
  • Configuration II having Java heap compression
    with garbage collection,
  • Configuration III having hardware solution of
    Java memory/heap compression

10
Configuration IJava runtime environment with
de/compression and without garbage collection
Compression techniques Reduce memory demand as
the GC will do, but is faster than the GC
Remote object created and accessed (compressed
form)
New local object created (uncompressed form)
  • We introduce the compression techniques to Java
    heap as an alternative of the GC

Caching unit
Decompressing unit
Delayed buffer
(goal) speed-up and low power
consumption (cond.) watermark is smaller than
a memory capacity (adv.) no execution time
for garbage collection and about ½ of the
original water mark, and minimize the leakage
energy by turning off inactive banks that do not
contain any data/codes (disadv.) overhead due
to de/compression time
Compressing unit
ALB
Compressed heap
accessed
Store compressed block
stored
Local object accessed (compressed form)
11
Experiments and results
main stream
unoptimized
SpaceEfficiency Wbefore / Wafter
TimeEfficiency Tbefore / Tafter
Tafter Costbase Costde/comp, Costde/comp
?Costcase1 ?Costcast2
12
Configuration IIJava runtime environment with
de/compression and garbage collection
We redesign config 1 to have the benefit of the
garbage collection

Features The mark phase is similar to the
original GC mechanism except that mark bits are
stored in the ALB table. The sweep and
compaction phases are migrated into
de/compression modules, and delayed until an
object is accessed and/or a cache miss occurs
(goal) high memory saving (cond.)
watermark will exceed a memory capacity (adv.)
about ½ of the original watermark.
Applications are made possible to run one small
hand-set with a given memory capacities that are
less than the watermarks. (disadv.) overhead due
to de/compression time
13
Space and Time efficiency
SpaceEfficiency Wbefore / Wafter
TimeEfficiency Tbefore / Tafter
Tafter Costbase Costgc
Costde/comp, Costde/comp ?Costcase1
?Costcast2
14
Configuration IIIA set of hardware compressing
and decompressing units
Compatible to software ones in configurations I
and II
(goal) fast execution (high performance
in speed) (cond.) hardware
implementations of both configurations I and
II (adv.) fast execution (disadv.)
complex integration
Expected to extend to compressed RAMs, secure
memory, components that need high performance in
speed and power
15
Feasible improvements
  • Time complexity
  • (hardware de/compression, fast garbage
    collection start-stop algo. Interact, hard
    real-time req. prog. )
  • Space complexity
  • (high compression ratio wk 2bits, x-macth
    3-several, zero-removal 1-bit-for-1-byte, no
    performance comp. characterizing workload)
  • Power consumption
  • (intro. metrics power and energy, tool for
    analysis, auto-configuration systems)
  • Integrating network compression into memory/cache
    heap
  • (finding solutions, merge, share)
  • Hotspot technology
  • (high memory demand 4-to-8 times code space,
    far too much for battery-powered devices)

16
Publication
  • M. KATO and C.D. Lo, A HEAP DE/COMPRESSION
    MODULES FOR WIRELESS JAVA, PPPJ04 conference,
    the ACM International Conference Proceeding
    Series, June 2004
  • M. KATO and C. D. Lo, Impact of Java Compressed
    Heap on Mobile/Wireless Communication, ITCC05
    conference, IEEE Computer Society, April 2005
  • C. D. Lo and M. KATO, Hardware/Software
    Co-Design in supporting Security in Embedded Java
    (extended abstract), SCISS03 symposium, NSF and
    the UNT, April 11-12, 2003
  • C. D. Lo and M. KATO, Power Consumption
    Reduction in Java Embedded Systems, CCCT03 and
    ISAS03 conference (best section paper award),
    July-August 2003
  • M. KATO and C.D. Lo, Growing Adaptation of
    Computer Science in Bioinformatics, ISICT04
    symposium, the ACM International Conference
    Proceeding Series, June 2004
  • M. KATO and C.D. Lo, Discovering a Strategy for
    Professional Communication with New Frontier
    Through Classroom Presentation, IPCC04
    conference, IEEE Professional Communication
    Society, October 2004
  • M. KATO and C.D. Lo, Hardware solution to Java
    compressed heap
  • abstract), FCCM05 symposium , IEEE Computer
    Society, April 2005
Write a Comment
User Comments (0)
About PowerShow.com