Date & Time
Friday, November 19, 2021, 11:15 AM - 11:45 AM
Name
QEMU-Hexagon: A story of Emus, Bisons, and now Dragons
Description

Writing a CPU emulator for a new architecture is often a time-consuming and error-prone process. Especially if you want it to 1) run on multiple host architectures, and 2) run fast. In this talk we present our work on QEMU-Hexagon, made in collaboration with Qualcomm, where we attempt to get around these issues using Clang, LLVM, and QEMU. We have developed an automatic IR-IR translator, taking LLVM IR to QEMUs own IR known as Tiny Code. Instruction semantics can then be specified as simple C functions, which are then translated to an efficient implementation in Tiny Code, ready to be embedded in QEMU. Our approach allows us to quickly implement the thousands of instructions supported by the Qualcomm Hexagon DSP. Moving forward, we have plans to further leverage LLVM's optimizers capabilities, specifically to vectorize for-loops in the input code.

Session Type
Technical Talk