mirror of
https://github.com/xemu-project/nxdk_pgraph_tests.git
synced 2024-11-26 19:40:45 +00:00
Adds method to emit nop instructions to aid in nv2a trace examination.
This commit is contained in:
parent
46d8ee4d4a
commit
9954f1ee8c
@ -248,6 +248,20 @@ void TestSuite::Initialize() {
|
||||
#ifdef ENABLE_PGRAPH_REGION_DIFF
|
||||
pgraph_diff_.Capture();
|
||||
#endif
|
||||
|
||||
TagNV2ATrace(2);
|
||||
p = pb_begin();
|
||||
p = pb_push1(p, NV097_SET_FOG_ENABLE, true);
|
||||
p = pb_push1(p, NV097_SET_FOG_ENABLE, false);
|
||||
pb_end(p);
|
||||
TagNV2ATrace(4);
|
||||
}
|
||||
|
||||
void TestSuite::TagNV2ATrace(uint32_t num_nops) {
|
||||
ASSERT(num_nops < 32 && "Too many nops in TagNV2ATrace");
|
||||
auto p = pb_begin();
|
||||
for (auto i = 0; i < num_nops; ++i) p = pb_push1(p, NV097_NO_OPERATION, 0x00);
|
||||
pb_end(p);
|
||||
}
|
||||
|
||||
void TestSuite::Deinitialize() {
|
||||
|
@ -40,6 +40,9 @@ class TestSuite {
|
||||
void SetSavingAllowed(bool enable = true) { allow_saving_ = enable; }
|
||||
void SetSuspectedCrashHandlingMode(SuspectedCrashHandling mode) { suspected_crash_handling_mode_ = mode; }
|
||||
|
||||
//! Inserts a pattern of NV097_NO_OPERATION's into the pushbuffer to allow identification when viewing nv2a traces.
|
||||
static void TagNV2ATrace(uint32_t num_nops);
|
||||
|
||||
protected:
|
||||
void SetDefaultTextureFormat() const;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user