Skip to main content

LUP Student Papers

LUND UNIVERSITY LIBRARIES

Integration of a Cycle-approximate Model Into a Cycle-accurate Environment

Hansson, Andreas LU (2021) EDAM05 20202
Department of Computer Science
Abstract
Software models can simulate hardware components to varying degrees of ac- curacy. On the extreme ends, there are purely functional models which have no concept of time and execute requests right away, and cycle-accurate models which capture all the implementation details and clock the time they take. In this thesis we study a model of an Arm Mali GPU which is a cycle-approximate model, meaning it is somewhere between the two. The model has some time- keeping abilities, but still accesses data in a functional untimed way. This creates compatibility issues if we want to connect it with cycle-accurate models which expect timed memory requests. To bridge this gap, we implement a scheme to convert untimed requests into timed when needed by... (More)
Software models can simulate hardware components to varying degrees of ac- curacy. On the extreme ends, there are purely functional models which have no concept of time and execute requests right away, and cycle-accurate models which capture all the implementation details and clock the time they take. In this thesis we study a model of an Arm Mali GPU which is a cycle-approximate model, meaning it is somewhere between the two. The model has some time- keeping abilities, but still accesses data in a functional untimed way. This creates compatibility issues if we want to connect it with cycle-accurate models which expect timed memory requests. To bridge this gap, we implement a scheme to convert untimed requests into timed when needed by employing a scheme of coroutines to switch context until timing requirements can be satisfied. We find that our scheme enables the model to work correctly in an environment that de- mands timed requests, but at the cost of accuracy loss in the model’s performance estimations. (Less)
Popular Abstract
Software models are used to aid the development of hardware components. To simulate systems with multiple components, multiple models can be connected together. In our project we show how mistimed communication can complicate such setups, and how this can be handled.

Over a billion phones are sold each year. The phone market is very competitive, with customers expecting constant improvements. As companies compete to satisfy these demands there is a need for optimised development processes. To speed up the development of chips, software models that mimic hardware behaviour are used. By hav- ing virtual versions of the chips being designed, designers and developers can try a lot of differ- ent changes without having to rebuild the actual... (More)
Software models are used to aid the development of hardware components. To simulate systems with multiple components, multiple models can be connected together. In our project we show how mistimed communication can complicate such setups, and how this can be handled.

Over a billion phones are sold each year. The phone market is very competitive, with customers expecting constant improvements. As companies compete to satisfy these demands there is a need for optimised development processes. To speed up the development of chips, software models that mimic hardware behaviour are used. By hav- ing virtual versions of the chips being designed, designers and developers can try a lot of differ- ent changes without having to rebuild the actual parts. Different testing needs have led to the existence of a lot of different types of models, and the degree to which they stay true to the hardware behaviour varies.

In this investigation, we have looked at a model simulating an Arm Mali GPU – a popular chip used to handle graphics in many phone models. When a graphics processing unit (GPU) runs, it frequently needs to use data that is located in a memory chip that is external to the GPU itself. Transferring between these takes a bit of time, so the GPU has to plan accordingly when it wants to fetch data. However, this simulation model has been implemented under the assumption that it can instantly access the data when needed. This makes a lot of testing easier, but makes the model incompatible with memory models that only work with timed communication channels and do not allow for such instant access.

In order to enable compatibility our project has looked at the different ways the GPU model tries to access data before it has been fully transferred. To address these we have created a mechanism that tracks all transfers taking place and success- fully identifies the incorrect data access attempts. When we discover an incorrect attempt we send out for the needed transfers and wait for these to be handled before we continue with the computation. This ensures that the GPU model never makes use of any different data than intended, which is necessary for the result of the computation to be correct. As we successfully identify and handle all the incorrect attempts taking place, we can now connect the GPU model to simulated systems that require timed transfers - enabling new test cases. (Less)
Please use this url to cite or link to this publication:
author
Hansson, Andreas LU
supervisor
organization
course
EDAM05 20202
year
type
H2 - Master's Degree (Two Years)
subject
keywords
C++, Modelling, Memory requests, Coroutines, GPU, AXI
report number
202108
language
English
id
9043431
date added to LUP
2021-07-01 10:56:47
date last changed
2021-07-01 10:56:47
@misc{9043431,
  abstract     = {{Software models can simulate hardware components to varying degrees of ac- curacy. On the extreme ends, there are purely functional models which have no concept of time and execute requests right away, and cycle-accurate models which capture all the implementation details and clock the time they take. In this thesis we study a model of an Arm Mali GPU which is a cycle-approximate model, meaning it is somewhere between the two. The model has some time- keeping abilities, but still accesses data in a functional untimed way. This creates compatibility issues if we want to connect it with cycle-accurate models which expect timed memory requests. To bridge this gap, we implement a scheme to convert untimed requests into timed when needed by employing a scheme of coroutines to switch context until timing requirements can be satisfied. We find that our scheme enables the model to work correctly in an environment that de- mands timed requests, but at the cost of accuracy loss in the model’s performance estimations.}},
  author       = {{Hansson, Andreas}},
  language     = {{eng}},
  note         = {{Student Paper}},
  title        = {{Integration of a Cycle-approximate Model Into a Cycle-accurate Environment}},
  year         = {{2021}},
}