mirror of
https://github.com/Atmosphere-NX/Atmosphere
synced 2024-11-15 01:26:34 +00:00
kern: delete creation time field from KProcess
This commit is contained in:
parent
08672fd422
commit
2e7491f605
3 changed files with 11 additions and 1 deletions
|
@ -42,6 +42,11 @@
|
||||||
#define MESOSPHERE_ENABLE_PANIC_REGISTER_DUMP
|
#define MESOSPHERE_ENABLE_PANIC_REGISTER_DUMP
|
||||||
#define MESOSPHERE_ENABLE_HARDWARE_SINGLE_STEP
|
#define MESOSPHERE_ENABLE_HARDWARE_SINGLE_STEP
|
||||||
|
|
||||||
|
/* NOTE: In 16.0.0, Nintendo deleted the creation time field for KProcess, */
|
||||||
|
/* but this may be useful for some debugging applications, and so can be. */
|
||||||
|
/* re-enabled by toggling this define. */
|
||||||
|
//#define MESOSPHERE_ENABLE_PROCESS_CREATION_TIME
|
||||||
|
|
||||||
/* NOTE: This enables fast class token storage using a class member. */
|
/* NOTE: This enables fast class token storage using a class member. */
|
||||||
/* This saves a virtual call when doing KAutoObject->DynCast<>(), */
|
/* This saves a virtual call when doing KAutoObject->DynCast<>(), */
|
||||||
/* at the cost of storing class tokens inside the class object. */
|
/* at the cost of storing class tokens inside the class object. */
|
||||||
|
|
|
@ -84,7 +84,9 @@ namespace ams::kern {
|
||||||
KCapabilities m_capabilities;
|
KCapabilities m_capabilities;
|
||||||
ams::svc::ProgramId m_program_id;
|
ams::svc::ProgramId m_program_id;
|
||||||
u64 m_process_id;
|
u64 m_process_id;
|
||||||
|
#if defined(MESOSPHERE_ENABLE_PROCESS_CREATION_TIME)
|
||||||
s64 m_creation_time;
|
s64 m_creation_time;
|
||||||
|
#endif
|
||||||
KProcessAddress m_code_address;
|
KProcessAddress m_code_address;
|
||||||
size_t m_code_size;
|
size_t m_code_size;
|
||||||
size_t m_main_thread_stack_size;
|
size_t m_main_thread_stack_size;
|
||||||
|
|
|
@ -198,7 +198,6 @@ namespace ams::kern {
|
||||||
/* Set misc fields. */
|
/* Set misc fields. */
|
||||||
m_state = State_Created;
|
m_state = State_Created;
|
||||||
m_main_thread_stack_size = 0;
|
m_main_thread_stack_size = 0;
|
||||||
m_creation_time = KHardwareTimer::GetTick();
|
|
||||||
m_used_kernel_memory_size = 0;
|
m_used_kernel_memory_size = 0;
|
||||||
m_ideal_core_id = 0;
|
m_ideal_core_id = 0;
|
||||||
m_flags = params.flags;
|
m_flags = params.flags;
|
||||||
|
@ -209,6 +208,10 @@ namespace ams::kern {
|
||||||
m_is_application = (params.flags & ams::svc::CreateProcessFlag_IsApplication);
|
m_is_application = (params.flags & ams::svc::CreateProcessFlag_IsApplication);
|
||||||
m_is_jit_debug = false;
|
m_is_jit_debug = false;
|
||||||
|
|
||||||
|
#if defined(MESOSPHERE_ENABLE_PROCESS_CREATION_TIME)
|
||||||
|
m_creation_time = KHardwareTimer::GetTick();
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Set thread fields. */
|
/* Set thread fields. */
|
||||||
for (size_t i = 0; i < cpu::NumCores; i++) {
|
for (size_t i = 0; i < cpu::NumCores; i++) {
|
||||||
m_running_threads[i] = nullptr;
|
m_running_threads[i] = nullptr;
|
||||||
|
|
Loading…
Reference in a new issue