DIGITALIS

ARM64-to-x86_64 binary translation for Android

Architecture

Berberis is AOSP's binary translation framework, part of Android's NativeBridge system. It provides the core infrastructure for translating guest architecture instructions to host machine code at runtime — including a JIT compiler, an interpreter, an instruction decoder, syscall emulation, and proxy libraries. Berberis currently supports RISC-V-to-x86_64 translation in upstream AOSP.

Berberis (upstream AOSP)
RISC-V APK
NativeBridge
JIT / Interpreter
x86_64 Host

Digitalis extends Berberis with an ARM64 backend, enabling ARM64-only Android apps to run on x86_64 emulators. It reuses Berberis's translation infrastructure while adding ARM64 instruction decoding, JIT code generation, and interpreter support.

Digitalis (this project)
ARM64 APK
NativeBridge
JIT / Interpreter
x86_64 Host

JIT Compiler (Lite Translator)

Translates ARM64 regions to native x86_64 machine code. Handles ~98% of instructions. Translated regions are cached for reuse.

~98% coverage

Interpreter

Per-instruction fallback for syscalls, complex SIMD operations, and edge cases the JIT can't handle.

fallback path

Features

JIT Compiler

Lite Translator converts ARM64 to native x86_64 machine code. Translated regions are cached for reuse, delivering near-native performance.

Interpreter Fallback

Per-instruction execution for syscalls, complex SIMD, and anything the JIT can't handle. Ensures complete ARM64 coverage.

Proxy Libraries

Vulkan, libc, libm forwarded to host APIs. GPU-accelerated rendering via GFXStream VkDecoder for full Vulkan support.

21 Sample Apps

Ported NDK samples prove end-to-end translation: Vulkan, OpenGL ES, audio, camera, sensors, and more.

Getting Started

# Clone
$ mkdir digitalis && cd digitalis
$ repo init -b android-latest-release -u git@github.com:DigitalisX64/manifest.git
$ repo sync -c -d --no-tags --force-sync
 
# Build
$ source build/envsetup.sh
$ lunch sdk_phone64_x86_64_digitalis-trunk_staging-userdebug
$ m
 
# Run emulator
$ emulator -memory 4096 -writable-system -partition-size 65536 -qemu -cpu host &
 
# Install and test
$ cd sample/hellodigitalis && ./gradlew assembleDebug
$ adb install hello-vulkan/build/outputs/apk/debug/hello-vulkan-debug.apk
$ adb shell am start -n com.example.hellodigitalis/android.app.NativeActivity

Sample Apps

ARM64-only APKs running on an x86_64 emulator via NativeBridge translation.

# Build all sample modules (ARM64-only APKs)
$ cd sample/hellodigitalis && ./gradlew assembleDebug
 
# Install and run
$ adb install hello-vulkan/build/outputs/apk/debug/hello-vulkan-debug.apk
$ adb shell am start -n com.example.hellodigitalis/android.app.NativeActivity
✓ Vulkan triangle rendered via NativeBridge translation
hello-vulkan
hello-gl2
gles3jni
teapots-classic
teapots-more
teapots-textured
native-activity
native-audio
native-codec
native-midi
hello-jni
hello-jniCallback
endless-tunnel
bitmap-plasma
camera-basic
camera-texture-view
sensor-graph
sanitizers
vectorization
orderfile
exceptions