Nugget
Loading...
Searching...
No Matches
common
kernel
threads.h
Go to the documentation of this file.
1
/*
2
3
MIT License
4
5
Copyright (c) 2024 PCSX-Redux authors
6
7
Permission is hereby granted, free of charge, to any person obtaining a copy
8
of this software and associated documentation files (the "Software"), to deal
9
in the Software without restriction, including without limitation the rights
10
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11
copies of the Software, and to permit persons to whom the Software is
12
furnished to do so, subject to the following conditions:
13
14
The above copyright notice and this permission notice shall be included in all
15
copies or substantial portions of the Software.
16
17
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
20
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
22
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
23
SOFTWARE.
24
25
*/
26
27
#pragma once
28
29
#include <stdint.h>
30
31
struct
Registers
{
32
union
{
33
struct
{
34
uint32_t
r0
,
at
,
v0
,
v1
,
a0
,
a1
,
a2
,
a3
;
35
uint32_t
t0
,
t1
,
t2
,
t3
,
t4
,
t5
,
t6
,
t7
;
36
uint32_t
s0
,
s1
,
s2
,
s3
,
s4
,
s5
,
s6
,
s7
;
37
uint32_t
t8
,
t9
,
k0
,
k1
,
gp
,
sp
,
fp
,
ra
;
38
}
n
;
39
uint32_t
r
[32];
40
}
GPR
;
41
uint32_t
returnPC
;
42
uint32_t
hi
,
lo
;
43
uint32_t
SR
;
44
uint32_t
Cause
;
45
};
46
47
struct
Thread
{
48
uint32_t
flags
,
flags2
;
49
struct
Registers
registers
;
50
uint32_t
unknown
[9];
51
};
52
53
struct
Process
{
54
struct
Thread
*
thread
;
55
};
Process
Definition
threads.h:53
Process::thread
struct Thread * thread
Definition
threads.h:54
Registers
Definition
threads.h:31
Registers::s0
uint32_t s0
Definition
threads.h:36
Registers::SR
uint32_t SR
Definition
threads.h:43
Registers::t3
uint32_t t3
Definition
threads.h:35
Registers::t9
uint32_t t9
Definition
threads.h:37
Registers::t0
uint32_t t0
Definition
threads.h:35
Registers::s4
uint32_t s4
Definition
threads.h:36
Registers::Cause
uint32_t Cause
Definition
threads.h:44
Registers::k1
uint32_t k1
Definition
threads.h:37
Registers::k0
uint32_t k0
Definition
threads.h:37
Registers::fp
uint32_t fp
Definition
threads.h:37
Registers::gp
uint32_t gp
Definition
threads.h:37
Registers::GPR
union Registers::@4 GPR
Registers::r0
uint32_t r0
Definition
threads.h:34
Registers::at
uint32_t at
Definition
threads.h:34
Registers::lo
uint32_t lo
Definition
threads.h:42
Registers::n
struct Registers::@4::@5 n
Registers::hi
uint32_t hi
Definition
threads.h:42
Registers::t5
uint32_t t5
Definition
threads.h:35
Registers::sp
uint32_t sp
Definition
threads.h:37
Registers::t2
uint32_t t2
Definition
threads.h:35
Registers::s2
uint32_t s2
Definition
threads.h:36
Registers::a3
uint32_t a3
Definition
threads.h:34
Registers::s5
uint32_t s5
Definition
threads.h:36
Registers::returnPC
uint32_t returnPC
Definition
threads.h:41
Registers::t1
uint32_t t1
Definition
threads.h:35
Registers::ra
uint32_t ra
Definition
threads.h:37
Registers::t7
uint32_t t7
Definition
threads.h:35
Registers::s1
uint32_t s1
Definition
threads.h:36
Registers::s7
uint32_t s7
Definition
threads.h:36
Registers::t6
uint32_t t6
Definition
threads.h:35
Registers::s3
uint32_t s3
Definition
threads.h:36
Registers::t8
uint32_t t8
Definition
threads.h:37
Registers::t4
uint32_t t4
Definition
threads.h:35
Registers::a1
uint32_t a1
Definition
threads.h:34
Registers::a2
uint32_t a2
Definition
threads.h:34
Registers::r
uint32_t r[32]
Definition
threads.h:39
Registers::s6
uint32_t s6
Definition
threads.h:36
Registers::v1
uint32_t v1
Definition
threads.h:34
Registers::v0
uint32_t v0
Definition
threads.h:34
Registers::a0
uint32_t a0
Definition
threads.h:34
Thread
Definition
threads.h:47
Thread::registers
struct Registers registers
Definition
threads.h:49
Thread::flags
uint32_t flags
Definition
threads.h:48
Thread::unknown
uint32_t unknown[9]
Definition
threads.h:50
Thread::flags2
uint32_t flags2
Definition
threads.h:48
uint32_t
void uint32_t(classId, spec)
Generated by
1.9.8