Hi everyone,
I am trying to configure SMT in GEMS2.1. I checked mfacet.py and
GEMS/opal/system/system.C but the code for SMT looks kind of strange
to me. Please help to correct my understanding. Thanks a lot.
in system.C:
"m_numSMTProcs = numProcs / CONFIG_LOGICAL_PER_PHY_PROC;"
so the number of SMT processor is equal the number of processors
initiated by simics over the number of config_logical on each SMT
processor. And CONFIG_LOGICAL_PER_PHY_PROC should be at least 2 in
order to make use of SMT (2 threads can issue
instructions simutaneously), am I right?
Next in system.C
"ASSERT( (cpuNumber >= 0) && (cpuNumber < system_t::inst->m_numProcs) );
int32 seq_index = cpuNumber;
ASSERT(seq_index >= 0 && seq_index < system_t::inst->m_numSMTProcs);"
As seq_index is equal to cpuNumber, if numProcs = 4, then seq_index can
be 0, 1, 2, 3. But if i set CONFIG_LOGICAL_PER_PHY_PROC = 2, the
seq_index can only be 0, 1 to satisfy the second assert. It is kind of
conflict, isn't it?
Please help me to understand how is SMT implemented. Thank you!
Best regards,
Xuan Qi
|