8.1.1 Overview of the Generic Graphics Accelerator

This section describes the components of the Generic Graphics Accelerator, and how they perform hardware acceleration and graphics integration for Android targets.

Hardware acceleration for Android targets

The Generic Graphics Accelerator maps graphics APIs on an Android target to the graphics APIs on the host. The host renders the Android images with these APIs through its own GPU.

The target graphics APIs can be OpenGL ES or Vulkan and the host graphics APIs can be OpenGL or Vulkan.

The following figure shows the hardware rendering process:

Figure 8-1 Graphics APIs mapping between the target and host

Signals in this figure are:

  • 1 is the SWI signal.
  • 2 is the CADIMemRead signal from the Sidechannel Plugin to read from memory in the target into the write buffer.
  • 3 is the CADIMemWrite signal from the Sidechannel Plugin to write to memory in the target from the read buffer.
  • The buffer inside the target covers both the usual buffer to implement graphics APIs, and the frame buffer as the rendering target.

Components in this figure are:

Shim Layer
Plays the role of the GPU driver. Implements the OpenGL ES or Vulkan APIs used by the application running on the target, and communicates with the Sidechannel Plugin. The Shim Layer is implemented by the Shim library.
Sidechannel Plugin
Provides a communication channel for messages and data passed between the target and host.
The application that calls OpenGL ES or Vulkan APIs on the target is in a different address space from the graphics APIs running on the host. The Sidechannel Plugin communicates between these different address spaces.

Bridges the communication between the Sidechannel Plugin and the graphics APIs.

The Generic Graphics Accelerator comprises the Shim Layer and the Reconciler.

Arm® Mali™ OpenGL ES Emulator
Simulates the OpenGL ES APIs by using the OpenGL APIs of the graphics card on the host. This emulator is used only with OpenGL ES APIs.

The workflow in this figure is:

  1. An application running on the Fast Models target makes an OpenGL ES or a Vulkan API call.
  2. The Shim Layer receives this call and informs the Sidechannel Plugin that it needs to send data to the host.
  3. The Shim Layer writes the data into the Write Buffer inside the Sidechannel Plugin when a software interrupt is invoked in the Fast Model.
  4. The Reconciler wakes up after the data writing completes.
  5. For an OpenGL ES API call, the Reconciler passes the data to the Arm Mali OpenGL ES Emulator on the host and waits until the call is completed.

    For a Vulkan API call, the Reconciler passes the data to the host graphics driver and waits until the call is completed.

  6. The Reconciler writes the output back to the Read Buffer of the Sidechannel Plugin.
  7. The Shim Layer sends another software interrupt to read the data from the Read Buffer when the application needs the data returned from the API.
  8. The Sidechannel Plugin reads the data from the read buffer and returns directly from the interrupt.
  9. The application continues to run on the target.

Graphics integration for Android targets

The Generic Graphics Accelerator supports the integration of the Android target graphics software stack with the Arm® Mali™ GPU register models, Mali-G71, Mali-G72, and Mali-G51.

The integration work flow is:

  1. On the target, the application APIs (OpenGL ES and EGL) interact with both the shim libraries and the Mali graphics drivers.
  2. Shim libraries pass the API data to the Generic Graphics Accelerator on the host. Then, the Generic Graphics Accelerator works with the host GPU and Mali OpenGL ES Emulator to render this data using the host GPU.

    Images are saved in the Generic Graphics Accelerator.

  3. In parallel with rendering on the host, on the target, the Mali driver executes APIs and passes commands, addresses, and the other settings to the GPU register model.

  4. When the model receives the start command from the driver, it sends the rendering-related destination addresses, MMU settings, and other data to the Generic Graphics Accelerator.
  5. On receiving this data, the Generic Graphics Accelerator combines it with the stored rendering images, and outputs the combined result to the memory model on the target.
  6. The Generic Graphics Accelerator reports to the target GPU that it has completed rendering.
  7. The target GPU reports to the driver that rendering is complete.
Figure 8-2 Graphics integration with the GPU register model

Non-ConfidentialPDF file icon PDF version100965_1105_00_en
Copyright © 2014–2018 Arm Limited or its affiliates. All rights reserved.