-
Notifications
You must be signed in to change notification settings - Fork 0
/
libSceFiber.c
138 lines (120 loc) · 5.84 KB
/
libSceFiber.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
/*
This file was generated by genstub.py, do not edit manually!
*/
int sprx_dlsym(unsigned int handle, const char *nid, void *addr);
int sprx_dlopen(const char* libname, unsigned short *handle);
int sprx_dlclose(unsigned int handle);
static __attribute__ ((used)) void* __ptr__sceFiberAttachContextAndRun;
asm(".intel_syntax noprefix\n"
".global _sceFiberAttachContextAndRun\n"
".type _sceFiberAttachContextAndRun @function\n"
"_sceFiberAttachContextAndRun:\n"
"jmp qword ptr [rip + __ptr__sceFiberAttachContextAndRun]\n");
static __attribute__ ((used)) void* __ptr__sceFiberAttachContextAndSwitch;
asm(".intel_syntax noprefix\n"
".global _sceFiberAttachContextAndSwitch\n"
".type _sceFiberAttachContextAndSwitch @function\n"
"_sceFiberAttachContextAndSwitch:\n"
"jmp qword ptr [rip + __ptr__sceFiberAttachContextAndSwitch]\n");
static __attribute__ ((used)) void* __ptr__sceFiberGetThreadFramePointerAddress;
asm(".intel_syntax noprefix\n"
".global _sceFiberGetThreadFramePointerAddress\n"
".type _sceFiberGetThreadFramePointerAddress @function\n"
"_sceFiberGetThreadFramePointerAddress:\n"
"jmp qword ptr [rip + __ptr__sceFiberGetThreadFramePointerAddress]\n");
static __attribute__ ((used)) void* __ptr__sceFiberInitializeImpl;
asm(".intel_syntax noprefix\n"
".global _sceFiberInitializeImpl\n"
".type _sceFiberInitializeImpl @function\n"
"_sceFiberInitializeImpl:\n"
"jmp qword ptr [rip + __ptr__sceFiberInitializeImpl]\n");
static __attribute__ ((used)) void* __ptr__sceFiberInitializeWithInternalOptionImpl;
asm(".intel_syntax noprefix\n"
".global _sceFiberInitializeWithInternalOptionImpl\n"
".type _sceFiberInitializeWithInternalOptionImpl @function\n"
"_sceFiberInitializeWithInternalOptionImpl:\n"
"jmp qword ptr [rip + __ptr__sceFiberInitializeWithInternalOptionImpl]\n");
static __attribute__ ((used)) void* __ptr_sceFiberFinalize;
asm(".intel_syntax noprefix\n"
".global sceFiberFinalize\n"
".type sceFiberFinalize @function\n"
"sceFiberFinalize:\n"
"jmp qword ptr [rip + __ptr_sceFiberFinalize]\n");
static __attribute__ ((used)) void* __ptr_sceFiberGetInfo;
asm(".intel_syntax noprefix\n"
".global sceFiberGetInfo\n"
".type sceFiberGetInfo @function\n"
"sceFiberGetInfo:\n"
"jmp qword ptr [rip + __ptr_sceFiberGetInfo]\n");
static __attribute__ ((used)) void* __ptr_sceFiberGetSelf;
asm(".intel_syntax noprefix\n"
".global sceFiberGetSelf\n"
".type sceFiberGetSelf @function\n"
"sceFiberGetSelf:\n"
"jmp qword ptr [rip + __ptr_sceFiberGetSelf]\n");
static __attribute__ ((used)) void* __ptr_sceFiberOptParamInitialize;
asm(".intel_syntax noprefix\n"
".global sceFiberOptParamInitialize\n"
".type sceFiberOptParamInitialize @function\n"
"sceFiberOptParamInitialize:\n"
"jmp qword ptr [rip + __ptr_sceFiberOptParamInitialize]\n");
static __attribute__ ((used)) void* __ptr_sceFiberRename;
asm(".intel_syntax noprefix\n"
".global sceFiberRename\n"
".type sceFiberRename @function\n"
"sceFiberRename:\n"
"jmp qword ptr [rip + __ptr_sceFiberRename]\n");
static __attribute__ ((used)) void* __ptr_sceFiberReturnToThread;
asm(".intel_syntax noprefix\n"
".global sceFiberReturnToThread\n"
".type sceFiberReturnToThread @function\n"
"sceFiberReturnToThread:\n"
"jmp qword ptr [rip + __ptr_sceFiberReturnToThread]\n");
static __attribute__ ((used)) void* __ptr_sceFiberRun;
asm(".intel_syntax noprefix\n"
".global sceFiberRun\n"
".type sceFiberRun @function\n"
"sceFiberRun:\n"
"jmp qword ptr [rip + __ptr_sceFiberRun]\n");
static __attribute__ ((used)) void* __ptr_sceFiberStartContextSizeCheck;
asm(".intel_syntax noprefix\n"
".global sceFiberStartContextSizeCheck\n"
".type sceFiberStartContextSizeCheck @function\n"
"sceFiberStartContextSizeCheck:\n"
"jmp qword ptr [rip + __ptr_sceFiberStartContextSizeCheck]\n");
static __attribute__ ((used)) void* __ptr_sceFiberStopContextSizeCheck;
asm(".intel_syntax noprefix\n"
".global sceFiberStopContextSizeCheck\n"
".type sceFiberStopContextSizeCheck @function\n"
"sceFiberStopContextSizeCheck:\n"
"jmp qword ptr [rip + __ptr_sceFiberStopContextSizeCheck]\n");
static __attribute__ ((used)) void* __ptr_sceFiberSwitch;
asm(".intel_syntax noprefix\n"
".global sceFiberSwitch\n"
".type sceFiberSwitch @function\n"
"sceFiberSwitch:\n"
"jmp qword ptr [rip + __ptr_sceFiberSwitch]\n");
static unsigned short __handle = 0;
static void __attribute__((constructor(104)))
__constructor(void) {
if(sprx_dlopen("libSceFiber", &__handle)) return;
if(sprx_dlsym(__handle, "avfGJ94g36Q", &__ptr__sceFiberAttachContextAndRun)) return;
if(sprx_dlsym(__handle, "ZqhZFuzKT6U", &__ptr__sceFiberAttachContextAndSwitch)) return;
if(sprx_dlsym(__handle, "0dy4JtMUcMQ", &__ptr__sceFiberGetThreadFramePointerAddress)) return;
if(sprx_dlsym(__handle, "hVYD7Ou2pCQ", &__ptr__sceFiberInitializeImpl)) return;
if(sprx_dlsym(__handle, "7+OJIpko9RY", &__ptr__sceFiberInitializeWithInternalOptionImpl)) return;
if(sprx_dlsym(__handle, "JeNX5F-NzQU", &__ptr_sceFiberFinalize)) return;
if(sprx_dlsym(__handle, "uq2Y5BFz0PE", &__ptr_sceFiberGetInfo)) return;
if(sprx_dlsym(__handle, "p+zLIOg27zU", &__ptr_sceFiberGetSelf)) return;
if(sprx_dlsym(__handle, "asjUJJ+aa8s", &__ptr_sceFiberOptParamInitialize)) return;
if(sprx_dlsym(__handle, "JzyT91ucGDc", &__ptr_sceFiberRename)) return;
if(sprx_dlsym(__handle, "B0ZX2hx9DMw", &__ptr_sceFiberReturnToThread)) return;
if(sprx_dlsym(__handle, "a0LLrZWac0M", &__ptr_sceFiberRun)) return;
if(sprx_dlsym(__handle, "Lcqty+QNWFc", &__ptr_sceFiberStartContextSizeCheck)) return;
if(sprx_dlsym(__handle, "Kj4nXMpnM8Y", &__ptr_sceFiberStopContextSizeCheck)) return;
if(sprx_dlsym(__handle, "PFT2S-tJ7Uk", &__ptr_sceFiberSwitch)) return;
}
static void __attribute__((destructor(104)))
__destructor(void) {
sprx_dlclose(__handle);
}