RenderScript Internals: Using a Numerical algorithm to Spike the RenderScript Compiler & Runtime

Platform Development Grand Ballroom A
Average rating: ****.
(4.00, 1 rating)

As semiconductor fabrication processes improve, discrete functionality such as CPUs, GPUs, DSPs, accelerators memory controllers etc. are being integrated into a single die or “System-on-Chip” (SoC). Consequently, these SoCs offer a huge opportunity for mobile developers to accelerate their computational workloads and enable yet to be seen user experiences. To leverage these emerging devices, Google has proposed RenderScript as an open source solution to the problems of productivity, high performance and code portability. To validate the productivity of a new programming model such as RenderScript, a deeper understanding of its features must be gained as opposed to simply comparing its obvious syntactic differences with other solutions. An understanding of the core semantics of the programming model is required along with its similarities and differences with other solutions such as Khronos’s OpenCL and NVidia’s CUDA. Additionally, metrics such as how the programming model manages complexity, its ease of use, simplicity, and express-ability must be considered. Finally, knowledge of how the programming model’s proposed productivity features impact its runtime performance characteristics must be understood.

To accomplish these presentation objectives, this presentation will use a simple numerical algorithm as the basis of a running case study executing under Android-x86 on an Intel Sandy Bridge CPU. I will start with a scalar implementation of a numerical algorithm written using C, followed by a brief code walk-through of my RenderScript implementation. Using the numerical example, I will briefly compare the features of the RenderScript Java Host API with CUDA 4.0 and OpenCL Host APIs. Next using my RenderScript based implementation of the numerical algorithm I will dissect how the open source RenderScript compiler compiles my sample program. I will illustrate how the Clang based RenderScript compiler parses the source for the sample numerical algorithm and builds an AST and then lowers it to the LLVM “bitcode” format. Next I will illustrate how the LLVM based RenderScript runtime lowers the “bitcode” format into the low-level instructions of the Sandy Bridge CPU. The goal of this presentation is to provide deep intuition and insight into the inner workings of both RenderScript programs as well as how RenderScript compiler compiles those programs to a specific target hardware architecture.

Yahya Mirza

Aurora Borealis Software

Yahya Mirza’s original background was aeronautical engineering and was initially employed by Battelle Labs in Columbus Ohio. After transitioning into the software industry, Yahya spent three years as a visiting researcher in the UIUC Smalltalk Research Group. Through his company, Aurora Borealis Software, Yahya has worked on system software projects for Microsoft, CatDaddy Games, Source Dynamics, Pixar Animation Studios and Small Machines Inc. Since 2002, Yahya has been the organizer of a number of applied workshops including the Language Runtimes workshops, held at the OOPSLA and Supercomputing Conferences, the Interactive Cinema Symposium held at Siggraph and the Multi-core / Many-core Conference. Recently Yahya has worked with the Clang / LLVM compilation system and an OS bring-up on the Tegra-2 SoC for an embedded computing system. Yahya has a deep interest in parallel compilation and runtime system technologies that leverage emerging heterogeneous SoCs.

  • HTCpro
  • Microsoft Corporation
  • Open Invention Network
  • X.commerce
  • Black Duck Software
  • BugSense
  • Dolby
  • Intel
  • Make magazine
  • Marvell
  • Meshin
  • MIPS Technologies

Sponsorship Opportunities

For information on becoming a sponsor of Android Open, contact Sharon Cordesse at

Media Partner Opportunities

For media partnerships, contact mediapartners@

Press and Media

For media-related inquiries, contact Maureen Jennings at

Contact Us

View a complete list of Android Open contacts