@ -1220,10 +1220,10 @@ static ResultCode CreateThread(Handle* out_handle, VAddr entry_point, u64 arg, V
auto * const current_process = Core : : CurrentProcess ( ) ;
if ( processor_id = = THREADPROCESSORID_ DEF AU LT ) {
// Set the target CPU to the one specified in the process' exheader .
processor_id = current_process - > Get DefaultProcessorID ( ) ;
ASSERT ( processor_id ! = THREADPROCESSORID_ DEF AU LT ) ;
if ( processor_id = = THREADPROCESSORID_ I DEAL) {
// Set the target CPU to the one specified by the process .
processor_id = current_process - > Get IdealCore ( ) ;
ASSERT ( processor_id ! = THREADPROCESSORID_ I DEAL) ;
}
switch ( processor_id ) {
@ -1632,13 +1632,13 @@ static ResultCode SetThreadCoreMask(Handle thread_handle, u32 core, u64 mask) {
return ERR_INVALID_HANDLE ;
}
if ( core = = static_cast < u32 > ( THREADPROCESSORID_ DEF AU LT ) ) {
const u8 default_processor_id = thread - > GetOwnerProcess ( ) - > Get DefaultProcessorID ( ) ;
if ( core = = static_cast < u32 > ( THREADPROCESSORID_ I DEAL) ) {
const u8 ideal_cpu_core = thread - > GetOwnerProcess ( ) - > Get IdealCore ( ) ;
ASSERT ( default_processor_id ! = static_cast < u8 > ( THREADPROCESSORID_ DEF AU LT ) ) ;
ASSERT ( ideal_cpu_core ! = static_cast < u8 > ( THREADPROCESSORID_ I DEAL) ) ;
// Set the target CPU to the one specified in the process' exheader .
core = default_processor_id ;
// Set the target CPU to the ideal core specified by the process .
core = ideal_cpu_core ;
mask = 1ULL < < core ;
}