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 OpenGL ES or Vulkan APIs on an Android target to OpenGL or Vulkan APIs on the host. The host renders Android images with these APIs using its own GPU.

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 plug-in to read from target memory into the write buffer.
  • 3 is the CADIMemWrite signal from the Sidechannel plug-in to write to target memory 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 plug-in. The Shim layer is implemented by the Shim library.
Sidechannel plug-in
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 plug-in communicates between these different address spaces.

Bridges the communication between the Sidechannel plug-in 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 plug-in that it needs to send data to the host.
  3. The Shim layer writes the data into the Write Buffer inside the Sidechannel plug-in 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 plug-in.
  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 plug-in 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_1180_00_en
Copyright © 2014–2019 Arm Limited or its affiliates. All rights reserved.