| 1 |
/* |
| 2 |
* Copyright (C) 2022-2026 Intel Corporation |
| 3 |
* |
| 4 |
* SPDX-License-Identifier: MIT |
| 5 |
* |
| 6 |
*/ |
| 7 |
|
| 8 |
#pragma once |
| 9 |
#include "level_zero/tools/source/debug/eu_thread.h" |
| 10 |
|
| 11 |
namespace NEO { |
| 12 |
class MockDevice; |
| 13 |
} |
| 14 |
|
| 15 |
namespace L0 { |
| 16 |
namespace ult { |
| 17 |
struct MockDeviceImp; |
| 18 |
struct MockDebugSession; |
| 19 |
|
| 20 |
struct DebugSessionRegistersAccess { |
| 21 |
DebugSessionRegistersAccess(); |
| 22 |
~DebugSessionRegistersAccess(); |
| 23 |
virtual void setUp(); |
| 24 |
|
| 25 |
void tearDown(); |
| 26 |
|
| 27 |
void dumpRegisterState(); |
| 28 |
|
| 29 |
ze_device_thread_t stoppedThread = {0, 0, 0, 0}; |
| 30 |
EuThread::ThreadId stoppedThreadId{0, stoppedThread}; |
| 31 |
std::unique_ptr<MockDebugSession> session; |
| 32 |
std::unique_ptr<MockDeviceImp> mockDevice; |
| 33 |
NEO::MockDevice *neoDevice = nullptr; |
| 34 |
}; |
| 35 |
|
| 36 |
struct DebugSessionRegistersAccessV3 : public DebugSessionRegistersAccess { |
| 37 |
void setUp() override; |
| 38 |
}; |
| 39 |
|
| 40 |
struct DebugSessionRegistersAccessScratch : public DebugSessionRegistersAccess { |
| 41 |
void setUp() override; |
| 42 |
}; |
| 43 |
|
| 44 |
struct DebugSessionRegistersAccessScratchV3 : public DebugSessionRegistersAccessV3 { |
| 45 |
void setUp() override; |
| 46 |
}; |
| 47 |
|
| 48 |
void setIsScratchInGrf(NEO::MockDevice *neoDevice, bool value); |
| 49 |
|
| 50 |
} // namespace ult |
| 51 |
} // namespace L0 |