diff options
author | Alexandru Dutu <alexandru.dutu@amd.com> | 2016-09-16 12:32:36 -0400 |
---|---|---|
committer | Alexandru Dutu <alexandru.dutu@amd.com> | 2016-09-16 12:32:36 -0400 |
commit | bd65ec07441cbb19fc2d3570da32a0205dad52c2 (patch) | |
tree | 16c56549f71ae3d9e221bb96dc9a2d4abd818701 /src/gpu-compute/wavefront.hh | |
parent | e9b14d51113def040893d711cc0d5a37cf5235ae (diff) | |
download | gem5-bd65ec07441cbb19fc2d3570da32a0205dad52c2.tar.xz |
gpu-compute: Adding context serialization methods to Wavefront
This patch adds methods to serialize the context of a particular wavefront
to the simulated system memory. Context serialization is used when a wavefront
is preempeted (i.e. context switch).
Diffstat (limited to 'src/gpu-compute/wavefront.hh')
-rw-r--r-- | src/gpu-compute/wavefront.hh | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/gpu-compute/wavefront.hh b/src/gpu-compute/wavefront.hh index 8caeda91e..ef8c80989 100644 --- a/src/gpu-compute/wavefront.hh +++ b/src/gpu-compute/wavefront.hh @@ -354,6 +354,18 @@ class Wavefront : public SimObject */ uint32_t getStaticContextSize() const; + /** + * Returns the hardware context as a stream of bytes + * This method is designed for HSAIL execution + */ + void getContext(const void *out); + + /** + * Sets the hardware context fromt a stream of bytes + * This method is designed for HSAIL execution + */ + void setContext(const void *in); + private: /** * Stack containing Control Flow Graph nodes (i.e., kernel instructions) |