We're sorry but this page doesn't work properly without JavaScript enabled. Please enable it to continue.
Feedback

Emulator development in Java

Formal Metadata

Title
Emulator development in Java
Title of Series
Number of Parts
542
Author
License
CC Attribution 2.0 Belgium:
You are free to use, adapt and copy, distribute and transmit the work or content in adapted or unchanged form for any legal purpose as long as the work is attributed to the author in the manner specified by the author or licensor.
Identifiers
Publisher
Release Date
Language

Content Metadata

Subject Area
Genre
Abstract
This talk explores my recent experience of developing an emulator in Java for two of our favourite Z80-based retro machines, the Sinclair ZX Spectrum and Sega Master System. At first glance, Java may not seem the obvious choice for emulator development: it lacks features such as unions, macros and definable primitive types (at least until recently!) that are leveraged for efficiency by emulators written in C/C++; integrating with native libraries beyond those in the standard platform can add development complexity and performance considerations; meanwhile, our program runs in a virtual machine whose JIT compiler and garbage collector have the potential to introduce latency into time-critical code. On the other hand, Java is cross-platform and includes sound, graphics, UI and concurrency APIs out of the box and its native platform integration and under-the-hood optimisations have been steadily maturing. We will explore what Java has to offer the emulator developer using “traditional” Java language and standard OpenJDK features alone, and see when and how to address some of our concerns when it comes to low-level data operations and performance.