Ayaz Akram has uploaded this change for review. ( https://gem5-review.googlesource.com/c/public/gem5/+/35837 )

Change subject: arch-x86: Append thread number to APIC id
......................................................................

arch-x86: Append thread number to APIC id

This change appends the smt thread number to APIC id to enable
smt support for x86

Change-Id: I3e7034b358623577c5ad4be3e51f08e48291ce49
---
M src/arch/x86/interrupts.cc
1 file changed, 2 insertions(+), 1 deletion(-)



diff --git a/src/arch/x86/interrupts.cc b/src/arch/x86/interrupts.cc
index 7767c80..c955f67 100644
--- a/src/arch/x86/interrupts.cc
+++ b/src/arch/x86/interrupts.cc
@@ -279,7 +279,8 @@

     BaseInterrupts::setThreadContext(_tc);

-    initialApicId = tc->cpuId();
+    //Update APIC id to consider SMT threads
+    initialApicId = (tc->cpuId() << sys->threads.size()) + _tc->threadId();
     regs[APIC_ID] = (initialApicId << 24);
     pioAddr = x86LocalAPICAddress(initialApicId, 0);
 }

--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/35837
To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: I3e7034b358623577c5ad4be3e51f08e48291ce49
Gerrit-Change-Number: 35837
Gerrit-PatchSet: 1
Gerrit-Owner: Ayaz Akram <yazak...@ucdavis.edu>
Gerrit-MessageType: newchange
_______________________________________________
gem5-dev mailing list -- gem5-dev@gem5.org
To unsubscribe send an email to gem5-dev-le...@gem5.org
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

Reply via email to