MCPcopy Create free account
hub / github.com/doldecomp/mkdd / enter

Method enter

libs/JSystem/JKernel/JKRThread.cpp:152–170  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

150}
151
152JKRThread *JKRThreadSwitch::enter(JKRThread *thread, int id)
153{
154 if (thread == nullptr)
155 {
156 return nullptr;
157 }
158 else
159 {
160 JKRThread *nextThread = JKRThread::searchThread(thread->getThreadRecord());
161 if (nextThread != nullptr)
162 thread = nextThread;
163
164 JKRThread::TLoad *loadInfo = thread->getLoadInfo();
165 loadInfo->clear();
166 loadInfo->setValid(true);
167 loadInfo->setId(id);
168 }
169 return thread;
170}
171
172void JKRThreadSwitch::callback(OSThread *current, OSThread *next)
173{

Callers 1

initJASystemMethod · 0.45

Calls 5

getThreadRecordMethod · 0.80
getLoadInfoMethod · 0.80
setValidMethod · 0.80
setIdMethod · 0.80
clearMethod · 0.45

Tested by

no test coverage detected