Skip to content

Commit

Permalink
expose thread id and tile id on OSX
Browse files Browse the repository at this point in the history
  • Loading branch information
opcm committed Dec 13, 2023
1 parent 9c82bf6 commit 0e9c814
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/MacMSRDriver/PcmMsr/PcmMsr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ void cpuWriteMSR(void* pIDatas){

void cpuGetTopoData(void* pTopos){
TopologyEntry* entries = (TopologyEntry*)pTopos;
int cpu = cpu_number();
const int cpu = cpu_number();

TopologyEntry & entry = entries[cpu];
entry.os_id = cpu;
Expand Down Expand Up @@ -190,8 +190,10 @@ IOReturn PcmMsrDriverClassName::buildTopology(TopologyEntry* odata, uint32_t inp

for(uint32_t i = 0; i < num_cores && i < input_num_cores; i++)
{
odata[i].core_id = topologies[i].core_id;
odata[i].os_id = topologies[i].os_id;
odata[i].thread_id = topologies[i].thread_id;
odata[i].core_id = topologies[i].core_id;
odata[i].tile_id = topologies[i].tile_id;
odata[i].socket = topologies[i].socket;
}

Expand Down

0 comments on commit 0e9c814

Please sign in to comment.