challenges and solutions for embedded java michael wortley computer integrated surgery march 1, 2001
TRANSCRIPT
![Page 1: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/1.jpg)
Challenges and Solutions for Embedded Java
Michael Wortley
Computer Integrated Surgery
March 1, 2001
![Page 2: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/2.jpg)
TINI CORBA ORB Project
• Goal: to port Java based CORBA ORB to TINI board
• Problem: Converting from JDK1.3 to TINI’s embedded Java
![Page 3: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/3.jpg)
Goals of this Presentation
• Provide background of Java’s benefits
• Show how embedded environment presents challenges to the Java platform
• Highlight available solutions
![Page 4: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/4.jpg)
Main Sources
• “Challenges to Embedded Java”– Charlie McDowell, UC Santa Cruz– 1998 PowerPoint presentation
• “Technical Overview of Embedded Java”– 4/2000, From Sun Website
![Page 5: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/5.jpg)
Other Sources
• “Java Schism?”– Rick Cook, Java Report 6/99
• “About Java Technology”– Sun Website
• TINI software information from www.iButton.com
![Page 6: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/6.jpg)
Goals of this Presentation
• Provide background of Java’s benefits
• Show how embedded environment presents challenges to the Java platform
• Highlight available solutions
![Page 7: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/7.jpg)
“Write Once, Run Anywhere.”
![Page 8: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/8.jpg)
![Page 9: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/9.jpg)
Why do Programmers like Java?
• Compiled and Interpreted
• Easy Upgrades through API
• JVM = Portability
![Page 10: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/10.jpg)
Goals of this Presentation
• Provide background of Java’s benefits
• Show how embedded environment presents challenges to the Java platform
• Highlight available solutions
![Page 11: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/11.jpg)
“Challenges to Embedded Java”
PowerPoint Presentation by Charlie McDowell, 1998.
![Page 12: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/12.jpg)
Key Points
• Java is superior to C++ in ease of development, maintenance, and portability
• Java API and JVM put too much stress on embedded processors
• Java tends to have slower execution time
![Page 13: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/13.jpg)
Key Points
• Automatic garbage collection causes problems
• Java lacks real-time support
![Page 14: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/14.jpg)
Java Memory Requirements
• Storage of Java API– up to 9 MB for JDK1.1
• JVM– between 300 and 800 KB
• Garbage Collection Overhead– copy collectors -> requires 2x max. heap
usage– conservative collectors -> memory leaks
![Page 15: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/15.jpg)
Java Execution Time
• Interpreted code runs more slowly than compiled code
• Resolving references prior to execution reduces run time
• Using final and static methods can reduce dynamic dispatch of functions
• Garbage Collection eats memory
![Page 16: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/16.jpg)
Garbage Collection
• Part of what makes Java simple
• Problematic for real-time applications
![Page 17: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/17.jpg)
Java and Real-Time Applications
• Java lacks:– reliable methods of estimating worst case– ability to measure CPU time, memory use– enforcement of time and space budgets– real-time garbage collection
• IMPROVEMENTS NEEDED!
![Page 18: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/18.jpg)
Suggested Optimizations for Embedded Java
• Reduce API to free memory
• Use final and static functions to decrease execution time
• Eliminate automatic garbage collection
• Find ways to improve real-time performance
![Page 19: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/19.jpg)
Non-Sun Embedded Java
• PERC by NewMonics– real-time garbage collection
• VxWorks– only 628 KB
• JN from UCSC– JIT from Kaffe– reduced API
![Page 20: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/20.jpg)
Goals of this Presentation
• Provide background of Java’s benefits
• Show how embedded environment presents challenges to the Java platform
• Highlight available solutions
![Page 21: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/21.jpg)
“Technical Overview of Embedded Java Technology”
Sun Microsystems
http://java.sun.com/products/embeddedjava/overview.html
![Page 22: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/22.jpg)
Improvements in Sun’s Embedded Java
• Configurable API
• Configurable JVM
• JavaFilter tool
• JavaCodeCompact
• JavaDataCompact
![Page 23: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/23.jpg)
New Programming Tools
• JavaFilter– input
• source code • Java API
– output• list of necessary API
classes and methods
![Page 24: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/24.jpg)
New Programming Tools
• JavaCodeCompact– input
• Source Code • Java API• list of necessary API
classes and methods
– output• data structures in C
code
![Page 25: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/25.jpg)
New Programming Tools
• JavaDataCompact– input
• associated data files • Java API
– output• data structures in C
code
![Page 26: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/26.jpg)
How this Relates to TINI
• TINI’s embedded Java is Sun compatible.
• Limitted API• Development Tools
– TINI API– TINIConvertor
![Page 27: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/27.jpg)
Conclusions about Embedded Java
• Increasing complexity of embedded devices will force makers to use high level language
• Java’s fast development time and portability are ideal for large manufacturers
• Competition needed to drive advancements
![Page 28: Challenges and Solutions for Embedded Java Michael Wortley Computer Integrated Surgery March 1, 2001](https://reader036.vdocuments.net/reader036/viewer/2022070412/5697bf7c1a28abf838c8418e/html5/thumbnails/28.jpg)
So long, and thanks for all the fish.