summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGravatar bunnei2018-03-19 10:33:21 -0400
committerGravatar GitHub2018-03-19 10:33:21 -0400
commitb2d7c92caee6f916ac9b3aa3476a5ceafc8e6e0f (patch)
tree07a410fab9206504f24b779b6631efc41e485142 /src
parentMerge pull request #193 from N00byKing/3184_2_robotic_boogaloo (diff)
parentGPU: Added the TSC registers to the Maxwell3D register structure. (diff)
downloadyuzu-b2d7c92caee6f916ac9b3aa3476a5ceafc8e6e0f.tar.gz
yuzu-b2d7c92caee6f916ac9b3aa3476a5ceafc8e6e0f.tar.xz
yuzu-b2d7c92caee6f916ac9b3aa3476a5ceafc8e6e0f.zip
Merge pull request #251 from Subv/tic_tsc
GPU: Added TIC and TSC registers to the Maxwell3D register structure.
Diffstat (limited to 'src')
-rw-r--r--src/video_core/engines/maxwell_3d.h31
1 files changed, 30 insertions, 1 deletions
diff --git a/src/video_core/engines/maxwell_3d.h b/src/video_core/engines/maxwell_3d.h
index 5d9b0043b..096679162 100644
--- a/src/video_core/engines/maxwell_3d.h
+++ b/src/video_core/engines/maxwell_3d.h
@@ -62,7 +62,34 @@ public:
62 62
63 union { 63 union {
64 struct { 64 struct {
65 INSERT_PADDING_WORDS(0x582); 65 INSERT_PADDING_WORDS(0x557);
66
67 struct {
68 u32 tsc_address_high;
69 u32 tsc_address_low;
70 u32 tsc_limit;
71
72 GPUVAddr TSCAddress() const {
73 return static_cast<GPUVAddr>(
74 (static_cast<GPUVAddr>(tsc_address_high) << 32) | tsc_address_low);
75 }
76 } tsc;
77
78 INSERT_PADDING_WORDS(0x3);
79
80 struct {
81 u32 tic_address_high;
82 u32 tic_address_low;
83 u32 tic_limit;
84
85 GPUVAddr TICAddress() const {
86 return static_cast<GPUVAddr>(
87 (static_cast<GPUVAddr>(tic_address_high) << 32) | tic_address_low);
88 }
89 } tic;
90
91 INSERT_PADDING_WORDS(0x22);
92
66 struct { 93 struct {
67 u32 code_address_high; 94 u32 code_address_high;
68 u32 code_address_low; 95 u32 code_address_low;
@@ -264,6 +291,8 @@ private:
264 static_assert(offsetof(Maxwell3D::Regs, field_name) == position * 4, \ 291 static_assert(offsetof(Maxwell3D::Regs, field_name) == position * 4, \
265 "Field " #field_name " has invalid position") 292 "Field " #field_name " has invalid position")
266 293
294ASSERT_REG_POSITION(tsc, 0x557);
295ASSERT_REG_POSITION(tic, 0x55D);
267ASSERT_REG_POSITION(code_address, 0x582); 296ASSERT_REG_POSITION(code_address, 0x582);
268ASSERT_REG_POSITION(draw, 0x585); 297ASSERT_REG_POSITION(draw, 0x585);
269ASSERT_REG_POSITION(query, 0x6C0); 298ASSERT_REG_POSITION(query, 0x6C0);