Andreas Sandberg has submitted this change and it was merged. (
https://gem5-review.googlesource.com/c/public/gem5/+/15437 )
Change subject: arch-arm, sim-se: Add support for TLS in clone
......................................................................
arch-arm, sim-se: Add support for TLS in clone
Change-Id: I1f78dce05a48a2e3adfaf027cd38ab55507b9611
Signed-off-by: Andreas Sandberg <[email protected]>
Cc: Giacomo Travaglini <[email protected]>
Cc: Javier Setoain <[email protected]>
Cc: Brandon Potter <[email protected]>
Reviewed-on: https://gem5-review.googlesource.com/c/15437
Reviewed-by: Jason Lowe-Power <[email protected]>
Maintainer: Brandon Potter <[email protected]>
---
M src/arch/arm/linux/linux.hh
1 file changed, 6 insertions(+), 0 deletions(-)
Approvals:
Jason Lowe-Power: Looks good to me, approved
Brandon Potter: Looks good to me, approved
diff --git a/src/arch/arm/linux/linux.hh b/src/arch/arm/linux/linux.hh
index e1f27a7..cff1e47 100644
--- a/src/arch/arm/linux/linux.hh
+++ b/src/arch/arm/linux/linux.hh
@@ -58,6 +58,12 @@
uint64_t stack, uint64_t tls)
{
ArmISA::copyRegs(ptc, ctc);
+
+ if (flags & TGT_CLONE_SETTLS) {
+ /* TPIDR_EL0 is architecturally mapped to TPIDRURW, so
+ * this works for both aarch32 and aarch64. */
+ ctc->setMiscReg(ArmISA::MISCREG_TPIDR_EL0, tls);
+ }
}
};
--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/15437
To unsubscribe, or for help writing mail filters, visit
https://gem5-review.googlesource.com/settings
Gerrit-Project: public/gem5
Gerrit-Branch: master
Gerrit-Change-Id: I1f78dce05a48a2e3adfaf027cd38ab55507b9611
Gerrit-Change-Number: 15437
Gerrit-PatchSet: 3
Gerrit-Owner: Andreas Sandberg <[email protected]>
Gerrit-Reviewer: Andreas Sandberg <[email protected]>
Gerrit-Reviewer: Brandon Potter <[email protected]>
Gerrit-Reviewer: Jason Lowe-Power <[email protected]>
Gerrit-CC: Giacomo Travaglini <[email protected]>
Gerrit-MessageType: merged
_______________________________________________
gem5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/gem5-dev