isa.cc revision 10035
17405SAli.Saidi@ARM.com/* 212667Schuan.zhu@arm.com * Copyright (c) 2010-2013 ARM Limited 37405SAli.Saidi@ARM.com * All rights reserved 47405SAli.Saidi@ARM.com * 57405SAli.Saidi@ARM.com * The license below extends only to copyright in the software and shall 67405SAli.Saidi@ARM.com * not be construed as granting a license to any other intellectual 77405SAli.Saidi@ARM.com * property including but not limited to intellectual property relating 87405SAli.Saidi@ARM.com * to a hardware implementation of the functionality of the software 97405SAli.Saidi@ARM.com * licensed hereunder. You may use the software subject to the license 107405SAli.Saidi@ARM.com * terms below provided that you ensure that this notice is replicated 117405SAli.Saidi@ARM.com * unmodified and in its entirety in all distributions of the software, 127405SAli.Saidi@ARM.com * modified or unmodified, in source code or in binary form. 137405SAli.Saidi@ARM.com * 147405SAli.Saidi@ARM.com * Redistribution and use in source and binary forms, with or without 157405SAli.Saidi@ARM.com * modification, are permitted provided that the following conditions are 167405SAli.Saidi@ARM.com * met: redistributions of source code must retain the above copyright 177405SAli.Saidi@ARM.com * notice, this list of conditions and the following disclaimer; 187405SAli.Saidi@ARM.com * redistributions in binary form must reproduce the above copyright 197405SAli.Saidi@ARM.com * notice, this list of conditions and the following disclaimer in the 207405SAli.Saidi@ARM.com * documentation and/or other materials provided with the distribution; 217405SAli.Saidi@ARM.com * neither the name of the copyright holders nor the names of its 227405SAli.Saidi@ARM.com * contributors may be used to endorse or promote products derived from 237405SAli.Saidi@ARM.com * this software without specific prior written permission. 247405SAli.Saidi@ARM.com * 257405SAli.Saidi@ARM.com * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 267405SAli.Saidi@ARM.com * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 277405SAli.Saidi@ARM.com * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 287405SAli.Saidi@ARM.com * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 297405SAli.Saidi@ARM.com * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 307405SAli.Saidi@ARM.com * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 317405SAli.Saidi@ARM.com * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 327405SAli.Saidi@ARM.com * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 337405SAli.Saidi@ARM.com * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 347405SAli.Saidi@ARM.com * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 357405SAli.Saidi@ARM.com * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 367405SAli.Saidi@ARM.com * 377405SAli.Saidi@ARM.com * Authors: Gabe Black 387405SAli.Saidi@ARM.com * Ali Saidi 397405SAli.Saidi@ARM.com */ 407405SAli.Saidi@ARM.com 417405SAli.Saidi@ARM.com#include "arch/arm/isa.hh" 4210461SAndreas.Sandberg@ARM.com#include "arch/arm/system.hh" 439050Schander.sudanthi@arm.com#include "cpu/checker/cpu.hh" 4412406Sgabeblack@google.com#include "debug/Arm.hh" 4512605Sgiacomo.travaglini@arm.com#include "debug/MiscRegs.hh" 4611793Sbrandon.potter@amd.com#include "params/ArmISA.hh" 478887Sgeoffrey.blake@arm.com#include "sim/faults.hh" 488232Snate@binkert.org#include "sim/stat_control.hh" 498232Snate@binkert.org#include "sim/system.hh" 5010844Sandreas.sandberg@arm.com 519384SAndreas.Sandberg@arm.comnamespace ArmISA 527678Sgblack@eecs.umich.edu{ 538059SAli.Saidi@ARM.com 548284SAli.Saidi@ARM.comISA::ISA(Params *p) 557405SAli.Saidi@ARM.com : SimObject(p) 567405SAli.Saidi@ARM.com{ 577405SAli.Saidi@ARM.com SCTLR sctlr; 587405SAli.Saidi@ARM.com sctlr = 0; 599384SAndreas.Sandberg@arm.com miscRegs[MISCREG_SCTLR_RST] = sctlr; 6010461SAndreas.Sandberg@ARM.com clear(); 6110461SAndreas.Sandberg@ARM.com} 6211165SRekai.GonzalezAlberquilla@arm.com 6312109SRekai.GonzalezAlberquilla@arm.comconst ArmISAParams * 6412714Sgiacomo.travaglini@arm.comISA::params() const 6512714Sgiacomo.travaglini@arm.com{ 669384SAndreas.Sandberg@arm.com return dynamic_cast<const Params *>(_params); 6711770SCurtis.Dunham@arm.com} 6810037SARM gem5 Developers 6910461SAndreas.Sandberg@ARM.comvoid 7010461SAndreas.Sandberg@ARM.comISA::clear() 7110461SAndreas.Sandberg@ARM.com{ 7210461SAndreas.Sandberg@ARM.com const Params *p(params()); 7310461SAndreas.Sandberg@ARM.com 7410461SAndreas.Sandberg@ARM.com SCTLR sctlr_rst = miscRegs[MISCREG_SCTLR_RST]; 7510609Sandreas.sandberg@arm.com memset(miscRegs, 0, sizeof(miscRegs)); 7610609Sandreas.sandberg@arm.com CPSR cpsr = 0; 7710609Sandreas.sandberg@arm.com cpsr.mode = MODE_USER; 7810037SARM gem5 Developers miscRegs[MISCREG_CPSR] = cpsr; 7910037SARM gem5 Developers updateRegMap(cpsr); 8010037SARM gem5 Developers 8110037SARM gem5 Developers SCTLR sctlr = 0; 8211771SCurtis.Dunham@arm.com sctlr.te = (bool)sctlr_rst.te; 8310037SARM gem5 Developers sctlr.nmfi = (bool)sctlr_rst.nmfi; 8410037SARM gem5 Developers sctlr.v = (bool)sctlr_rst.v; 8510037SARM gem5 Developers sctlr.u = 1; 8610037SARM gem5 Developers sctlr.xp = 1; 8713114Sgiacomo.travaglini@arm.com sctlr.rao2 = 1; 8810037SARM gem5 Developers sctlr.rao3 = 1; 8911771SCurtis.Dunham@arm.com sctlr.rao4 = 1; 9010037SARM gem5 Developers miscRegs[MISCREG_SCTLR] = sctlr; 9110037SARM gem5 Developers miscRegs[MISCREG_SCTLR_RST] = sctlr_rst; 9213114Sgiacomo.travaglini@arm.com 9310037SARM gem5 Developers /* Start with an event in the mailbox */ 9410037SARM gem5 Developers miscRegs[MISCREG_SEV_MAILBOX] = 1; 9512477SCurtis.Dunham@arm.com 9610037SARM gem5 Developers // Separate Instruction and Data TLBs. 9710037SARM gem5 Developers miscRegs[MISCREG_TLBTR] = 1; 989384SAndreas.Sandberg@arm.com 999384SAndreas.Sandberg@arm.com MVFR0 mvfr0 = 0; 1009384SAndreas.Sandberg@arm.com mvfr0.advSimdRegisters = 2; 10112479SCurtis.Dunham@arm.com mvfr0.singlePrecision = 2; 10212479SCurtis.Dunham@arm.com mvfr0.doublePrecision = 2; 1039384SAndreas.Sandberg@arm.com mvfr0.vfpExceptionTrapping = 0; 1049384SAndreas.Sandberg@arm.com mvfr0.divide = 1; 1059384SAndreas.Sandberg@arm.com mvfr0.squareRoot = 1; 1069384SAndreas.Sandberg@arm.com mvfr0.shortVectors = 1; 1079384SAndreas.Sandberg@arm.com mvfr0.roundingModes = 1; 1089384SAndreas.Sandberg@arm.com miscRegs[MISCREG_MVFR0] = mvfr0; 1097427Sgblack@eecs.umich.edu 1107427Sgblack@eecs.umich.edu MVFR1 mvfr1 = 0; 1117427Sgblack@eecs.umich.edu mvfr1.flushToZero = 1; 1129385SAndreas.Sandberg@arm.com mvfr1.defaultNaN = 1; 1139385SAndreas.Sandberg@arm.com mvfr1.advSimdLoadStore = 1; 1147427Sgblack@eecs.umich.edu mvfr1.advSimdInteger = 1; 1157427Sgblack@eecs.umich.edu mvfr1.advSimdSinglePrecision = 1; 11610037SARM gem5 Developers mvfr1.advSimdHalfPrecision = 1; 11713114Sgiacomo.travaglini@arm.com mvfr1.vfpHalfPrecision = 1; 11810037SARM gem5 Developers miscRegs[MISCREG_MVFR1] = mvfr1; 11913114Sgiacomo.travaglini@arm.com 12013114Sgiacomo.travaglini@arm.com // Reset values of PRRR and NMRR are implementation dependent 12113114Sgiacomo.travaglini@arm.com 12213114Sgiacomo.travaglini@arm.com miscRegs[MISCREG_PRRR] = 12313114Sgiacomo.travaglini@arm.com (1 << 19) | // 19 12412690Sgiacomo.travaglini@arm.com (0 << 18) | // 18 12510037SARM gem5 Developers (0 << 17) | // 17 12610037SARM gem5 Developers (1 << 16) | // 16 12710037SARM gem5 Developers (2 << 14) | // 15:14 12810037SARM gem5 Developers (0 << 12) | // 13:12 12910037SARM gem5 Developers (2 << 10) | // 11:10 13010037SARM gem5 Developers (2 << 8) | // 9:8 13110037SARM gem5 Developers (2 << 6) | // 7:6 13210037SARM gem5 Developers (2 << 4) | // 5:4 1337427Sgblack@eecs.umich.edu (1 << 2) | // 3:2 1347427Sgblack@eecs.umich.edu 0; // 1:0 1357427Sgblack@eecs.umich.edu miscRegs[MISCREG_NMRR] = 1367427Sgblack@eecs.umich.edu (1 << 30) | // 31:30 1377427Sgblack@eecs.umich.edu (0 << 26) | // 27:26 1387427Sgblack@eecs.umich.edu (0 << 24) | // 25:24 13910037SARM gem5 Developers (3 << 22) | // 23:22 14010037SARM gem5 Developers (2 << 20) | // 21:20 14110037SARM gem5 Developers (0 << 18) | // 19:18 14210037SARM gem5 Developers (0 << 16) | // 17:16 1437427Sgblack@eecs.umich.edu (1 << 14) | // 15:14 1447427Sgblack@eecs.umich.edu (0 << 12) | // 13:12 1457427Sgblack@eecs.umich.edu (2 << 10) | // 11:10 14610037SARM gem5 Developers (0 << 8) | // 9:8 14710204SAli.Saidi@ARM.com (3 << 6) | // 7:6 14810204SAli.Saidi@ARM.com (2 << 4) | // 5:4 14910037SARM gem5 Developers (0 << 2) | // 3:2 1507427Sgblack@eecs.umich.edu 0; // 1:0 15110037SARM gem5 Developers 1527427Sgblack@eecs.umich.edu miscRegs[MISCREG_CPACR] = 0; 15310037SARM gem5 Developers 1547427Sgblack@eecs.umich.edu // Initialize configurable default values 1557427Sgblack@eecs.umich.edu miscRegs[MISCREG_MIDR] = p->midr; 15610037SARM gem5 Developers 1577427Sgblack@eecs.umich.edu miscRegs[MISCREG_ID_PFR0] = p->id_pfr0; 1587427Sgblack@eecs.umich.edu miscRegs[MISCREG_ID_PFR1] = p->id_pfr1; 1597427Sgblack@eecs.umich.edu 1607427Sgblack@eecs.umich.edu miscRegs[MISCREG_ID_MMFR0] = p->id_mmfr0; 1617427Sgblack@eecs.umich.edu miscRegs[MISCREG_ID_MMFR1] = p->id_mmfr1; 1627427Sgblack@eecs.umich.edu miscRegs[MISCREG_ID_MMFR2] = p->id_mmfr2; 1637427Sgblack@eecs.umich.edu miscRegs[MISCREG_ID_MMFR3] = p->id_mmfr3; 1647427Sgblack@eecs.umich.edu 1657427Sgblack@eecs.umich.edu miscRegs[MISCREG_ID_ISAR0] = p->id_isar0; 1667427Sgblack@eecs.umich.edu miscRegs[MISCREG_ID_ISAR1] = p->id_isar1; 1677427Sgblack@eecs.umich.edu miscRegs[MISCREG_ID_ISAR2] = p->id_isar2; 1687427Sgblack@eecs.umich.edu miscRegs[MISCREG_ID_ISAR3] = p->id_isar3; 1697427Sgblack@eecs.umich.edu miscRegs[MISCREG_ID_ISAR4] = p->id_isar4; 1707427Sgblack@eecs.umich.edu miscRegs[MISCREG_ID_ISAR5] = p->id_isar5; 1717427Sgblack@eecs.umich.edu 1727427Sgblack@eecs.umich.edu 1737427Sgblack@eecs.umich.edu miscRegs[MISCREG_FPSID] = p->fpsid; 1747427Sgblack@eecs.umich.edu 1757427Sgblack@eecs.umich.edu 1767427Sgblack@eecs.umich.edu //XXX We need to initialize the rest of the state. 1777427Sgblack@eecs.umich.edu} 1787427Sgblack@eecs.umich.edu 1797427Sgblack@eecs.umich.eduMiscReg 1807436Sdam.sunwoo@arm.comISA::readMiscRegNoEffect(int misc_reg) const 1817436Sdam.sunwoo@arm.com{ 18210037SARM gem5 Developers assert(misc_reg < NumMiscRegs); 18310037SARM gem5 Developers 1847436Sdam.sunwoo@arm.com int flat_idx; 1857436Sdam.sunwoo@arm.com if (misc_reg == MISCREG_SPSR) 1867436Sdam.sunwoo@arm.com flat_idx = flattenMiscIndex(misc_reg); 1877436Sdam.sunwoo@arm.com else 1887436Sdam.sunwoo@arm.com flat_idx = misc_reg; 1897436Sdam.sunwoo@arm.com MiscReg val = miscRegs[flat_idx]; 1907436Sdam.sunwoo@arm.com 1917436Sdam.sunwoo@arm.com DPRINTF(MiscRegs, "Reading From misc reg %d (%d) : %#x\n", 1927436Sdam.sunwoo@arm.com misc_reg, flat_idx, val); 1937436Sdam.sunwoo@arm.com return val; 1947436Sdam.sunwoo@arm.com} 1957436Sdam.sunwoo@arm.com 19610037SARM gem5 Developers 1977436Sdam.sunwoo@arm.comMiscReg 1987436Sdam.sunwoo@arm.comISA::readMiscReg(int misc_reg, ThreadContext *tc) 1997436Sdam.sunwoo@arm.com{ 2007436Sdam.sunwoo@arm.com ArmSystem *arm_sys; 2017436Sdam.sunwoo@arm.com 2027436Sdam.sunwoo@arm.com if (misc_reg == MISCREG_CPSR) { 2037436Sdam.sunwoo@arm.com CPSR cpsr = miscRegs[misc_reg]; 2047436Sdam.sunwoo@arm.com PCState pc = tc->pcState(); 2057436Sdam.sunwoo@arm.com cpsr.j = pc.jazelle() ? 1 : 0; 2067436Sdam.sunwoo@arm.com cpsr.t = pc.thumb() ? 1 : 0; 2077436Sdam.sunwoo@arm.com return cpsr; 2087436Sdam.sunwoo@arm.com } 2097436Sdam.sunwoo@arm.com if (misc_reg >= MISCREG_CP15_UNIMP_START) 2107436Sdam.sunwoo@arm.com panic("Unimplemented CP15 register %s read.\n", 2117436Sdam.sunwoo@arm.com miscRegName[misc_reg]); 2127436Sdam.sunwoo@arm.com 2137644Sali.saidi@arm.com switch (misc_reg) { 2148147SAli.Saidi@ARM.com case MISCREG_MPIDR: 2159385SAndreas.Sandberg@arm.com arm_sys = dynamic_cast<ArmSystem*>(tc->getSystemPtr()); 2169385SAndreas.Sandberg@arm.com assert(arm_sys); 21710037SARM gem5 Developers 21810037SARM gem5 Developers if (arm_sys->multiProc) { 21910037SARM gem5 Developers return 0x80000000 | // multiprocessor extensions available 22010037SARM gem5 Developers tc->cpuId(); 22110037SARM gem5 Developers } else { 22210037SARM gem5 Developers return 0x80000000 | // multiprocessor extensions available 22310037SARM gem5 Developers 0x40000000 | // in up system 22410037SARM gem5 Developers tc->cpuId(); 22510037SARM gem5 Developers } 22610037SARM gem5 Developers break; 22710037SARM gem5 Developers case MISCREG_CLIDR: 22810037SARM gem5 Developers warn_once("The clidr register always reports 0 caches.\n"); 22910037SARM gem5 Developers warn_once("clidr LoUIS field of 0b001 to match current " 23010037SARM gem5 Developers "ARM implementations.\n"); 23110037SARM gem5 Developers return 0x00200000; 23210037SARM gem5 Developers case MISCREG_CCSIDR: 2338147SAli.Saidi@ARM.com warn_once("The ccsidr register isn't implemented and " 2347427Sgblack@eecs.umich.edu "always reads as 0.\n"); 2357427Sgblack@eecs.umich.edu break; 2367427Sgblack@eecs.umich.edu case MISCREG_CTR: 23710037SARM gem5 Developers { 23810037SARM gem5 Developers //all caches have the same line size in gem5 23910037SARM gem5 Developers //4 byte words in ARM 24010037SARM gem5 Developers unsigned lineSizeWords = 24110037SARM gem5 Developers tc->getSystemPtr()->cacheLineSize() / 4; 24210037SARM gem5 Developers unsigned log2LineSizeWords = 0; 24310037SARM gem5 Developers 24410037SARM gem5 Developers while (lineSizeWords >>= 1) { 24510037SARM gem5 Developers ++log2LineSizeWords; 24610037SARM gem5 Developers } 24710037SARM gem5 Developers 24810037SARM gem5 Developers CTR ctr = 0; 24910037SARM gem5 Developers //log2 of minimun i-cache line size (words) 25010037SARM gem5 Developers ctr.iCacheLineSize = log2LineSizeWords; 25110037SARM gem5 Developers //b11 - gem5 uses pipt 25210037SARM gem5 Developers ctr.l1IndexPolicy = 0x3; 25310037SARM gem5 Developers //log2 of minimum d-cache line size (words) 25410037SARM gem5 Developers ctr.dCacheLineSize = log2LineSizeWords; 25510037SARM gem5 Developers //log2 of max reservation size (words) 25610037SARM gem5 Developers ctr.erg = log2LineSizeWords; 25710037SARM gem5 Developers //log2 of max writeback size (words) 25810037SARM gem5 Developers ctr.cwg = log2LineSizeWords; 25910037SARM gem5 Developers //b100 - gem5 format is ARMv7 26010037SARM gem5 Developers ctr.format = 0x4; 26110037SARM gem5 Developers 26210037SARM gem5 Developers return ctr; 26310037SARM gem5 Developers } 26410037SARM gem5 Developers case MISCREG_ACTLR: 26510037SARM gem5 Developers warn("Not doing anything for miscreg ACTLR\n"); 26610037SARM gem5 Developers break; 26710037SARM gem5 Developers case MISCREG_PMCR: 26810037SARM gem5 Developers case MISCREG_PMCCNTR: 26910037SARM gem5 Developers case MISCREG_PMSELR: 27010037SARM gem5 Developers warn("Not doing anything for read to miscreg %s\n", 27110037SARM gem5 Developers miscRegName[misc_reg]); 27210037SARM gem5 Developers break; 27311770SCurtis.Dunham@arm.com case MISCREG_CPSR_Q: 27410037SARM gem5 Developers panic("shouldn't be reading this register seperately\n"); 27511574SCurtis.Dunham@arm.com case MISCREG_FPSCR_QC: 27611770SCurtis.Dunham@arm.com return readMiscRegNoEffect(MISCREG_FPSCR) & ~FpscrQcMask; 27711770SCurtis.Dunham@arm.com case MISCREG_FPSCR_EXC: 27810037SARM gem5 Developers return readMiscRegNoEffect(MISCREG_FPSCR) & ~FpscrExcMask; 27911770SCurtis.Dunham@arm.com case MISCREG_L2CTLR: 28011770SCurtis.Dunham@arm.com { 28110037SARM gem5 Developers // mostly unimplemented, just set NumCPUs field from sim and return 28210037SARM gem5 Developers L2CTLR l2ctlr = 0; 28310037SARM gem5 Developers // b00:1CPU to b11:4CPUs 28413114Sgiacomo.travaglini@arm.com l2ctlr.numCPUs = tc->getSystemPtr()->numContexts() - 1; 28510037SARM gem5 Developers return l2ctlr; 28613114Sgiacomo.travaglini@arm.com } 28713114Sgiacomo.travaglini@arm.com case MISCREG_DBGDIDR: 28813114Sgiacomo.travaglini@arm.com /* For now just implement the version number. 28913114Sgiacomo.travaglini@arm.com * Return 0 as we don't support debug architecture yet. 29013114Sgiacomo.travaglini@arm.com */ 29113114Sgiacomo.travaglini@arm.com return 0; 29213114Sgiacomo.travaglini@arm.com case MISCREG_DBGDSCR_INT: 29313114Sgiacomo.travaglini@arm.com return 0; 29413114Sgiacomo.travaglini@arm.com } 29513114Sgiacomo.travaglini@arm.com return readMiscRegNoEffect(misc_reg); 29613114Sgiacomo.travaglini@arm.com} 29713114Sgiacomo.travaglini@arm.com 29813114Sgiacomo.travaglini@arm.comvoid 29913114Sgiacomo.travaglini@arm.comISA::setMiscRegNoEffect(int misc_reg, const MiscReg &val) 30013114Sgiacomo.travaglini@arm.com{ 30113114Sgiacomo.travaglini@arm.com assert(misc_reg < NumMiscRegs); 30213114Sgiacomo.travaglini@arm.com 30313114Sgiacomo.travaglini@arm.com int flat_idx; 30413114Sgiacomo.travaglini@arm.com if (misc_reg == MISCREG_SPSR) 30513114Sgiacomo.travaglini@arm.com flat_idx = flattenMiscIndex(misc_reg); 30613114Sgiacomo.travaglini@arm.com else 30713114Sgiacomo.travaglini@arm.com flat_idx = misc_reg; 30813114Sgiacomo.travaglini@arm.com miscRegs[flat_idx] = val; 30913114Sgiacomo.travaglini@arm.com 31010037SARM gem5 Developers DPRINTF(MiscRegs, "Writing to misc reg %d (%d) : %#x\n", misc_reg, 31110037SARM gem5 Developers flat_idx, val); 31210037SARM gem5 Developers} 31310461SAndreas.Sandberg@ARM.com 31410461SAndreas.Sandberg@ARM.comvoid 31510461SAndreas.Sandberg@ARM.comISA::setMiscReg(int misc_reg, const MiscReg &val, ThreadContext *tc) 31610461SAndreas.Sandberg@ARM.com{ 31710037SARM gem5 Developers 31810037SARM gem5 Developers MiscReg newVal = val; 31910037SARM gem5 Developers int x; 32010037SARM gem5 Developers System *sys; 32110037SARM gem5 Developers ThreadContext *oc; 32213116Sgiacomo.travaglini@arm.com 32310037SARM gem5 Developers if (misc_reg == MISCREG_CPSR) { 32410461SAndreas.Sandberg@ARM.com updateRegMap(val); 32510461SAndreas.Sandberg@ARM.com 32610461SAndreas.Sandberg@ARM.com 32710461SAndreas.Sandberg@ARM.com CPSR old_cpsr = miscRegs[MISCREG_CPSR]; 32810461SAndreas.Sandberg@ARM.com int old_mode = old_cpsr.mode; 32910037SARM gem5 Developers CPSR cpsr = val; 33010037SARM gem5 Developers if (old_mode != cpsr.mode) { 33110037SARM gem5 Developers tc->getITBPtr()->invalidateMiscReg(); 33210037SARM gem5 Developers tc->getDTBPtr()->invalidateMiscReg(); 33310037SARM gem5 Developers } 33411574SCurtis.Dunham@arm.com 33510037SARM gem5 Developers DPRINTF(Arm, "Updating CPSR from %#x to %#x f:%d i:%d a:%d mode:%#x\n", 33610037SARM gem5 Developers miscRegs[misc_reg], cpsr, cpsr.f, cpsr.i, cpsr.a, cpsr.mode); 33710037SARM gem5 Developers PCState pc = tc->pcState(); 33811574SCurtis.Dunham@arm.com pc.nextThumb(cpsr.t); 33910037SARM gem5 Developers pc.nextJazelle(cpsr.j); 34010037SARM gem5 Developers 34110037SARM gem5 Developers // Follow slightly different semantics if a CheckerCPU object 34210037SARM gem5 Developers // is connected 34310037SARM gem5 Developers CheckerCPU *checker = tc->getCheckerCpuPtr(); 34410037SARM gem5 Developers if (checker) { 34510037SARM gem5 Developers tc->pcStateNoRecord(pc); 34613114Sgiacomo.travaglini@arm.com } else { 34710037SARM gem5 Developers tc->pcState(pc); 34810037SARM gem5 Developers } 34912972Sandreas.sandberg@arm.com } else if (misc_reg >= MISCREG_CP15_UNIMP_START && 35012972Sandreas.sandberg@arm.com misc_reg < MISCREG_CP15_END) { 35112972Sandreas.sandberg@arm.com panic("Unimplemented CP15 register %s wrote with %#x.\n", 35212972Sandreas.sandberg@arm.com miscRegName[misc_reg], val); 35312972Sandreas.sandberg@arm.com } else { 35412972Sandreas.sandberg@arm.com switch (misc_reg) { 35512972Sandreas.sandberg@arm.com case MISCREG_CPACR: 35612972Sandreas.sandberg@arm.com { 3577405SAli.Saidi@ARM.com 35810035Sandreas.hansson@arm.com const uint32_t ones = (uint32_t)(-1); 3597405SAli.Saidi@ARM.com CPACR cpacrMask = 0; 3607405SAli.Saidi@ARM.com // Only cp10, cp11, and ase are implemented, nothing else should 3617614Sminkyu.jeong@arm.com // be writable 36212478SCurtis.Dunham@arm.com cpacrMask.cp10 = ones; 36312478SCurtis.Dunham@arm.com cpacrMask.cp11 = ones; 36412478SCurtis.Dunham@arm.com cpacrMask.asedis = ones; 36512478SCurtis.Dunham@arm.com newVal &= cpacrMask; 36612478SCurtis.Dunham@arm.com DPRINTF(MiscRegs, "Writing misc reg %s: %#x\n", 36712478SCurtis.Dunham@arm.com miscRegName[misc_reg], newVal); 36812478SCurtis.Dunham@arm.com } 36912478SCurtis.Dunham@arm.com break; 37012478SCurtis.Dunham@arm.com case MISCREG_CSSELR: 37112478SCurtis.Dunham@arm.com warn_once("The csselr register isn't implemented.\n"); 37212478SCurtis.Dunham@arm.com return; 37312478SCurtis.Dunham@arm.com case MISCREG_FPSCR: 37412478SCurtis.Dunham@arm.com { 37512478SCurtis.Dunham@arm.com const uint32_t ones = (uint32_t)(-1); 37612478SCurtis.Dunham@arm.com FPSCR fpscrMask = 0; 37712478SCurtis.Dunham@arm.com fpscrMask.ioc = ones; 3787405SAli.Saidi@ARM.com fpscrMask.dzc = ones; 3797405SAli.Saidi@ARM.com fpscrMask.ofc = ones; 3807405SAli.Saidi@ARM.com fpscrMask.ufc = ones; 3817405SAli.Saidi@ARM.com fpscrMask.ixc = ones; 3827405SAli.Saidi@ARM.com fpscrMask.idc = ones; 3837405SAli.Saidi@ARM.com fpscrMask.len = ones; 38410037SARM gem5 Developers fpscrMask.stride = ones; 38510037SARM gem5 Developers fpscrMask.rMode = ones; 38610037SARM gem5 Developers fpscrMask.fz = ones; 3879050Schander.sudanthi@arm.com fpscrMask.dn = ones; 3887405SAli.Saidi@ARM.com fpscrMask.ahp = ones; 38910037SARM gem5 Developers fpscrMask.qc = ones; 39010037SARM gem5 Developers fpscrMask.v = ones; 3917720Sgblack@eecs.umich.edu fpscrMask.c = ones; 3927720Sgblack@eecs.umich.edu fpscrMask.z = ones; 3937405SAli.Saidi@ARM.com fpscrMask.n = ones; 3947405SAli.Saidi@ARM.com newVal = (newVal & (uint32_t)fpscrMask) | 3957757SAli.Saidi@ARM.com (miscRegs[MISCREG_FPSCR] & ~(uint32_t)fpscrMask); 39610037SARM gem5 Developers tc->getDecoderPtr()->setContext(newVal); 39710037SARM gem5 Developers } 39810037SARM gem5 Developers break; 39910037SARM gem5 Developers case MISCREG_CPSR_Q: 40010037SARM gem5 Developers { 40110037SARM gem5 Developers assert(!(newVal & ~CpsrMaskQ)); 40210037SARM gem5 Developers newVal = miscRegs[MISCREG_CPSR] | newVal; 40310037SARM gem5 Developers misc_reg = MISCREG_CPSR; 40410037SARM gem5 Developers } 40510037SARM gem5 Developers break; 40610037SARM gem5 Developers case MISCREG_FPSCR_QC: 40710037SARM gem5 Developers { 40810037SARM gem5 Developers newVal = miscRegs[MISCREG_FPSCR] | (newVal & FpscrQcMask); 40910037SARM gem5 Developers misc_reg = MISCREG_FPSCR; 41010037SARM gem5 Developers } 41110037SARM gem5 Developers break; 41210037SARM gem5 Developers case MISCREG_FPSCR_EXC: 41310037SARM gem5 Developers { 41410037SARM gem5 Developers newVal = miscRegs[MISCREG_FPSCR] | (newVal & FpscrExcMask); 41510037SARM gem5 Developers misc_reg = MISCREG_FPSCR; 41610037SARM gem5 Developers } 41710037SARM gem5 Developers break; 41810037SARM gem5 Developers case MISCREG_FPEXC: 41910037SARM gem5 Developers { 42010037SARM gem5 Developers // vfpv3 architecture, section B.6.1 of DDI04068 42110037SARM gem5 Developers // bit 29 - valid only if fpexc[31] is 0 42210037SARM gem5 Developers const uint32_t fpexcMask = 0x60000000; 42310037SARM gem5 Developers newVal = (newVal & fpexcMask) | 42410037SARM gem5 Developers (miscRegs[MISCREG_FPEXC] & ~fpexcMask); 42510037SARM gem5 Developers } 42610037SARM gem5 Developers break; 42710037SARM gem5 Developers case MISCREG_SCTLR: 42810037SARM gem5 Developers { 42912667Schuan.zhu@arm.com DPRINTF(MiscRegs, "Writing SCTLR: %#x\n", newVal); 43010037SARM gem5 Developers SCTLR sctlr = miscRegs[MISCREG_SCTLR]; 43110037SARM gem5 Developers SCTLR new_sctlr = newVal; 43210037SARM gem5 Developers new_sctlr.nmfi = (bool)sctlr.nmfi; 43310037SARM gem5 Developers miscRegs[MISCREG_SCTLR] = (MiscReg)new_sctlr; 43410037SARM gem5 Developers tc->getITBPtr()->invalidateMiscReg(); 43510037SARM gem5 Developers tc->getDTBPtr()->invalidateMiscReg(); 43610037SARM gem5 Developers 43710037SARM gem5 Developers // Check if all CPUs are booted with caches enabled 43810037SARM gem5 Developers // so we can stop enforcing coherency of some kernel 43910037SARM gem5 Developers // structures manually. 44010037SARM gem5 Developers sys = tc->getSystemPtr(); 44110037SARM gem5 Developers for (x = 0; x < sys->numContexts(); x++) { 4428284SAli.Saidi@ARM.com oc = sys->getThreadContext(x); 44310037SARM gem5 Developers SCTLR other_sctlr = oc->readMiscRegNoEffect(MISCREG_SCTLR); 44410037SARM gem5 Developers if (!other_sctlr.c && oc->status() != ThreadContext::Halted) 44510037SARM gem5 Developers return; 44610037SARM gem5 Developers } 4479050Schander.sudanthi@arm.com 44810037SARM gem5 Developers for (x = 0; x < sys->numContexts(); x++) { 44910037SARM gem5 Developers oc = sys->getThreadContext(x); 45010037SARM gem5 Developers oc->getDTBPtr()->allCpusCaching(); 45110037SARM gem5 Developers oc->getITBPtr()->allCpusCaching(); 45210037SARM gem5 Developers 45310037SARM gem5 Developers // If CheckerCPU is connected, need to notify it. 45410037SARM gem5 Developers CheckerCPU *checker = oc->getCheckerCpuPtr(); 45510037SARM gem5 Developers if (checker) { 45610037SARM gem5 Developers checker->getDTBPtr()->allCpusCaching(); 45710037SARM gem5 Developers checker->getITBPtr()->allCpusCaching(); 45810037SARM gem5 Developers } 45910037SARM gem5 Developers } 46010037SARM gem5 Developers return; 46110037SARM gem5 Developers } 46210037SARM gem5 Developers 46310037SARM gem5 Developers case MISCREG_MIDR: 46410037SARM gem5 Developers case MISCREG_ID_PFR0: 46510037SARM gem5 Developers case MISCREG_ID_PFR1: 4669050Schander.sudanthi@arm.com case MISCREG_ID_MMFR0: 4678284SAli.Saidi@ARM.com case MISCREG_ID_MMFR1: 46810037SARM gem5 Developers case MISCREG_ID_MMFR2: 46910037SARM gem5 Developers case MISCREG_ID_MMFR3: 47010037SARM gem5 Developers case MISCREG_ID_ISAR0: 47110037SARM gem5 Developers case MISCREG_ID_ISAR1: 47210037SARM gem5 Developers case MISCREG_ID_ISAR2: 47310037SARM gem5 Developers case MISCREG_ID_ISAR3: 47410037SARM gem5 Developers case MISCREG_ID_ISAR4: 4757405SAli.Saidi@ARM.com case MISCREG_ID_ISAR5: 4767731SAli.Saidi@ARM.com 4778468Swade.walker@arm.com case MISCREG_MPIDR: 4788468Swade.walker@arm.com case MISCREG_FPSID: 4798468Swade.walker@arm.com case MISCREG_TLBTR: 4807405SAli.Saidi@ARM.com case MISCREG_MVFR0: 4817731SAli.Saidi@ARM.com case MISCREG_MVFR1: 4827405SAli.Saidi@ARM.com // ID registers are constants. 4837405SAli.Saidi@ARM.com return; 48411809Sbaz21@cam.ac.uk 48511809Sbaz21@cam.ac.uk case MISCREG_TLBIALLIS: 4869130Satgutier@umich.edu case MISCREG_TLBIALL: 4879130Satgutier@umich.edu sys = tc->getSystemPtr(); 4889130Satgutier@umich.edu for (x = 0; x < sys->numContexts(); x++) { 4899130Satgutier@umich.edu oc = sys->getThreadContext(x); 4909814Sandreas.hansson@arm.com assert(oc->getITBPtr() && oc->getDTBPtr()); 4919130Satgutier@umich.edu oc->getITBPtr()->flushAll(); 4929130Satgutier@umich.edu oc->getDTBPtr()->flushAll(); 4939130Satgutier@umich.edu 4949130Satgutier@umich.edu // If CheckerCPU is connected, need to notify it of a flush 4959130Satgutier@umich.edu CheckerCPU *checker = oc->getCheckerCpuPtr(); 4969130Satgutier@umich.edu if (checker) { 4979130Satgutier@umich.edu checker->getITBPtr()->flushAll(); 4989130Satgutier@umich.edu checker->getDTBPtr()->flushAll(); 4999130Satgutier@umich.edu } 5009130Satgutier@umich.edu } 5019130Satgutier@umich.edu return; 5029130Satgutier@umich.edu case MISCREG_ITLBIALL: 5039130Satgutier@umich.edu tc->getITBPtr()->flushAll(); 5049130Satgutier@umich.edu return; 5059130Satgutier@umich.edu case MISCREG_DTLBIALL: 5069130Satgutier@umich.edu tc->getDTBPtr()->flushAll(); 5079130Satgutier@umich.edu return; 5089130Satgutier@umich.edu case MISCREG_TLBIMVAIS: 5099130Satgutier@umich.edu case MISCREG_TLBIMVA: 5109130Satgutier@umich.edu sys = tc->getSystemPtr(); 5119130Satgutier@umich.edu for (x = 0; x < sys->numContexts(); x++) { 5129130Satgutier@umich.edu oc = sys->getThreadContext(x); 5137583SAli.Saidi@arm.com assert(oc->getITBPtr() && oc->getDTBPtr()); 5147583SAli.Saidi@arm.com oc->getITBPtr()->flushMvaAsid(mbits(newVal, 31, 12), 5157583SAli.Saidi@arm.com bits(newVal, 7,0)); 51610461SAndreas.Sandberg@ARM.com oc->getDTBPtr()->flushMvaAsid(mbits(newVal, 31, 12), 51710461SAndreas.Sandberg@ARM.com bits(newVal, 7,0)); 51810461SAndreas.Sandberg@ARM.com 51910461SAndreas.Sandberg@ARM.com CheckerCPU *checker = oc->getCheckerCpuPtr(); 52010461SAndreas.Sandberg@ARM.com if (checker) { 52110461SAndreas.Sandberg@ARM.com checker->getITBPtr()->flushMvaAsid(mbits(newVal, 31, 12), 52210461SAndreas.Sandberg@ARM.com bits(newVal, 7,0)); 5238302SAli.Saidi@ARM.com checker->getDTBPtr()->flushMvaAsid(mbits(newVal, 31, 12), 5248302SAli.Saidi@ARM.com bits(newVal, 7,0)); 5257783SGiacomo.Gabrielli@arm.com } 5267783SGiacomo.Gabrielli@arm.com } 5277783SGiacomo.Gabrielli@arm.com return; 5287783SGiacomo.Gabrielli@arm.com case MISCREG_TLBIASIDIS: 52910037SARM gem5 Developers case MISCREG_TLBIASID: 53010037SARM gem5 Developers sys = tc->getSystemPtr(); 53110037SARM gem5 Developers for (x = 0; x < sys->numContexts(); x++) { 53210037SARM gem5 Developers oc = sys->getThreadContext(x); 53310037SARM gem5 Developers assert(oc->getITBPtr() && oc->getDTBPtr()); 53410037SARM gem5 Developers oc->getITBPtr()->flushAsid(bits(newVal, 7,0)); 53510037SARM gem5 Developers oc->getDTBPtr()->flushAsid(bits(newVal, 7,0)); 53610037SARM gem5 Developers CheckerCPU *checker = oc->getCheckerCpuPtr(); 53710037SARM gem5 Developers if (checker) { 53810037SARM gem5 Developers checker->getITBPtr()->flushAsid(bits(newVal, 7,0)); 53910037SARM gem5 Developers checker->getDTBPtr()->flushAsid(bits(newVal, 7,0)); 54010037SARM gem5 Developers } 54110037SARM gem5 Developers } 54210037SARM gem5 Developers return; 54310037SARM gem5 Developers case MISCREG_TLBIMVAAIS: 54410037SARM gem5 Developers case MISCREG_TLBIMVAA: 54510037SARM gem5 Developers sys = tc->getSystemPtr(); 54610037SARM gem5 Developers for (x = 0; x < sys->numContexts(); x++) { 54710037SARM gem5 Developers oc = sys->getThreadContext(x); 54810037SARM gem5 Developers assert(oc->getITBPtr() && oc->getDTBPtr()); 54910037SARM gem5 Developers oc->getITBPtr()->flushMva(mbits(newVal, 31,12)); 55010037SARM gem5 Developers oc->getDTBPtr()->flushMva(mbits(newVal, 31,12)); 55110037SARM gem5 Developers 55210037SARM gem5 Developers CheckerCPU *checker = oc->getCheckerCpuPtr(); 55310037SARM gem5 Developers if (checker) { 55410037SARM gem5 Developers checker->getITBPtr()->flushMva(mbits(newVal, 31,12)); 55510037SARM gem5 Developers checker->getDTBPtr()->flushMva(mbits(newVal, 31,12)); 55610037SARM gem5 Developers } 55710037SARM gem5 Developers } 55810037SARM gem5 Developers return; 55910037SARM gem5 Developers case MISCREG_ITLBIMVA: 56010037SARM gem5 Developers tc->getITBPtr()->flushMvaAsid(mbits(newVal, 31, 12), 56110338SCurtis.Dunham@arm.com bits(newVal, 7,0)); 56210338SCurtis.Dunham@arm.com return; 56310338SCurtis.Dunham@arm.com case MISCREG_DTLBIMVA: 56410037SARM gem5 Developers tc->getDTBPtr()->flushMvaAsid(mbits(newVal, 31, 12), 56510037SARM gem5 Developers bits(newVal, 7,0)); 56610037SARM gem5 Developers return; 56710037SARM gem5 Developers case MISCREG_ITLBIASID: 56810037SARM gem5 Developers tc->getITBPtr()->flushAsid(bits(newVal, 7,0)); 56910037SARM gem5 Developers return; 57010037SARM gem5 Developers case MISCREG_DTLBIASID: 57110037SARM gem5 Developers tc->getDTBPtr()->flushAsid(bits(newVal, 7,0)); 57210037SARM gem5 Developers return; 57310037SARM gem5 Developers case MISCREG_ACTLR: 57410037SARM gem5 Developers warn("Not doing anything for write of miscreg ACTLR\n"); 57510037SARM gem5 Developers break; 57610037SARM gem5 Developers case MISCREG_PMCR: 57710037SARM gem5 Developers { 57810037SARM gem5 Developers // Performance counters not implemented. Instead, interpret 57910037SARM gem5 Developers // a reset command to this register to reset the simulator 58010037SARM gem5 Developers // statistics. 58110037SARM gem5 Developers // PMCR_E | PMCR_P | PMCR_C 58210037SARM gem5 Developers const int ResetAndEnableCounters = 0x7; 58310037SARM gem5 Developers if (newVal == ResetAndEnableCounters) { 58410037SARM gem5 Developers inform("Resetting all simobject stats\n"); 58510037SARM gem5 Developers Stats::schedStatEvent(false, true); 58610037SARM gem5 Developers break; 58710037SARM gem5 Developers } 58810037SARM gem5 Developers } 58910037SARM gem5 Developers case MISCREG_PMCCNTR: 59010037SARM gem5 Developers case MISCREG_PMSELR: 59110037SARM gem5 Developers warn("Not doing anything for write to miscreg %s\n", 5928549Sdaniel.johnson@arm.com miscRegName[misc_reg]); 5938868SMatt.Horsnell@arm.com break; 5948868SMatt.Horsnell@arm.com case MISCREG_V2PCWPR: 5958868SMatt.Horsnell@arm.com case MISCREG_V2PCWPW: 5968868SMatt.Horsnell@arm.com case MISCREG_V2PCWUR: 5978868SMatt.Horsnell@arm.com case MISCREG_V2PCWUW: 5988868SMatt.Horsnell@arm.com case MISCREG_V2POWPR: 5998868SMatt.Horsnell@arm.com case MISCREG_V2POWPW: 6008868SMatt.Horsnell@arm.com case MISCREG_V2POWUR: 6018868SMatt.Horsnell@arm.com case MISCREG_V2POWUW: 60210461SAndreas.Sandberg@ARM.com { 6038868SMatt.Horsnell@arm.com RequestPtr req = new Request; 60410461SAndreas.Sandberg@ARM.com unsigned flags; 60510037SARM gem5 Developers BaseTLB::Mode mode; 6068868SMatt.Horsnell@arm.com Fault fault; 60710037SARM gem5 Developers switch(misc_reg) { 60811150Smitch.hayenga@arm.com case MISCREG_V2PCWPR: 60910037SARM gem5 Developers flags = TLB::MustBeOne; 61010037SARM gem5 Developers mode = BaseTLB::Read; 61110037SARM gem5 Developers break; 61210037SARM gem5 Developers case MISCREG_V2PCWPW: 61311150Smitch.hayenga@arm.com flags = TLB::MustBeOne; 61410037SARM gem5 Developers mode = BaseTLB::Write; 61510037SARM gem5 Developers break; 61610037SARM gem5 Developers case MISCREG_V2PCWUR: 61710037SARM gem5 Developers flags = TLB::MustBeOne | TLB::UserMode; 61810037SARM gem5 Developers mode = BaseTLB::Read; 61910037SARM gem5 Developers break; 62010037SARM gem5 Developers case MISCREG_V2PCWUW: 62110037SARM gem5 Developers flags = TLB::MustBeOne | TLB::UserMode; 62210037SARM gem5 Developers mode = BaseTLB::Write; 62310037SARM gem5 Developers break; 62410037SARM gem5 Developers default: 62510037SARM gem5 Developers panic("Security Extensions not implemented!"); 62610037SARM gem5 Developers } 62710037SARM gem5 Developers warn("Translating via MISCREG in atomic mode! Fix Me!\n"); 62810037SARM gem5 Developers req->setVirt(0, val, 1, flags, tc->pcState().pc(), 62910037SARM gem5 Developers Request::funcMasterId); 63010037SARM gem5 Developers fault = tc->getDTBPtr()->translateAtomic(req, tc, mode); 63110037SARM gem5 Developers if (fault == NoFault) { 63210037SARM gem5 Developers miscRegs[MISCREG_PAR] = 63310037SARM gem5 Developers (req->getPaddr() & 0xfffff000) | 63410037SARM gem5 Developers (tc->getDTBPtr()->getAttr() ); 63510037SARM gem5 Developers DPRINTF(MiscRegs, 63610037SARM gem5 Developers "MISCREG: Translated addr 0x%08x: PAR: 0x%08x\n", 63710037SARM gem5 Developers val, miscRegs[MISCREG_PAR]); 63810037SARM gem5 Developers } 63910037SARM gem5 Developers else { 64010037SARM gem5 Developers // Set fault bit and FSR 64110037SARM gem5 Developers FSR fsr = miscRegs[MISCREG_DFSR]; 64210037SARM gem5 Developers miscRegs[MISCREG_PAR] = 64311769SCurtis.Dunham@arm.com (fsr.ext << 6) | 64411769SCurtis.Dunham@arm.com (fsr.fsHigh << 5) | 64510037SARM gem5 Developers (fsr.fsLow << 1) | 64611770SCurtis.Dunham@arm.com 0x1; // F bit 64711770SCurtis.Dunham@arm.com } 64810037SARM gem5 Developers return; 64911770SCurtis.Dunham@arm.com } 65011769SCurtis.Dunham@arm.com case MISCREG_CONTEXTIDR: 65110844Sandreas.sandberg@arm.com case MISCREG_PRRR: 65211772SCurtis.Dunham@arm.com case MISCREG_NMRR: 65311772SCurtis.Dunham@arm.com case MISCREG_DACR: 65411772SCurtis.Dunham@arm.com tc->getITBPtr()->invalidateMiscReg(); 65511772SCurtis.Dunham@arm.com tc->getDTBPtr()->invalidateMiscReg(); 65611774SCurtis.Dunham@arm.com break; 65711774SCurtis.Dunham@arm.com case MISCREG_L2CTLR: 65811774SCurtis.Dunham@arm.com warn("miscreg L2CTLR (%s) written with %#x. ignored...\n", 65911774SCurtis.Dunham@arm.com miscRegName[misc_reg], uint32_t(val)); 66011774SCurtis.Dunham@arm.com } 66111774SCurtis.Dunham@arm.com } 66211774SCurtis.Dunham@arm.com setMiscRegNoEffect(misc_reg, newVal); 66311773SCurtis.Dunham@arm.com} 66411773SCurtis.Dunham@arm.com 66511773SCurtis.Dunham@arm.com} 66611773SCurtis.Dunham@arm.com 66711773SCurtis.Dunham@arm.comArmISA::ISA * 66811773SCurtis.Dunham@arm.comArmISAParams::create() 66911773SCurtis.Dunham@arm.com{ 67011772SCurtis.Dunham@arm.com return new ArmISA::ISA(this); 67110037SARM gem5 Developers} 67212816Sgiacomo.travaglini@arm.com