dev-hsa,gpu-compute: Agent Packet handler implemented.
authorDaniel Gerzhoy <daniel.gerzhoy@gmail.com>
Wed, 4 Nov 2020 16:51:46 +0000 (11:51 -0500)
committerDaniel Gerzhoy <daniel.gerzhoy@gmail.com>
Mon, 16 Nov 2020 16:12:48 +0000 (16:12 +0000)
commit9a01d3e92765f14055756457403bbe4ecfce2d5b
treecd7149d1c35bd3a6d776ab672bbb47335aa00f7a
parenta0cff8b9458d22ab8123ab32ccc09da3d7ce0082
dev-hsa,gpu-compute: Agent Packet handler implemented.

HSA packet processor will now accept and process agent packets.

Type field in packet is command type.
For now:
        AgentCmd::Nop = 0
        AgentCmd::Steal = 1

Steal command steals the completion signal for a running kernel.
This enables a benchmark to use hsa primitives to send an agent
packet to steal the signal, then wait on that signal.

Minimal working example to be added in gem5-resources.

Change-Id: I37f8a4b7ea1780b471559aecbf4af1050353b0b1
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/37015
Reviewed-by: Matt Sinclair <mattdsinclair@gmail.com>
Reviewed-by: Matthew Poremba <matthew.poremba@amd.com>
Maintainer: Matt Sinclair <mattdsinclair@gmail.com>
Tested-by: kokoro <noreply+kokoro@google.com>
src/dev/hsa/hsa_device.hh
src/dev/hsa/hsa_packet_processor.cc
src/dev/hsa/hsa_packet_processor.hh
src/gpu-compute/SConscript
src/gpu-compute/dispatcher.cc
src/gpu-compute/gpu_command_processor.cc
src/gpu-compute/gpu_command_processor.hh
src/gpu-compute/shader.cc