vfp.isa (10184:bbfa3152bdea) vfp.isa (10205:3ca67d0e0e7e)
1// -*- mode:c++ -*-
2
3// Copyright (c) 2010-2013 ARM Limited
4// All rights reserved
5//
6// The license below extends only to copyright in the software and shall
7// not be construed as granting a license to any other intellectual
8// property including but not limited to intellectual property relating

--- 35 unchanged lines hidden (view full) ---

44 uint32_t seq;
45 if (!vfpNeonEnabled(seq,Hcptr, Nsacr, Cpacr, Cpsr, issEnCheck,
46 trapEnCheck, xc->tcBase(), Fpexc))
47 {return disabledFault();}
48 if (trapEnCheck) {
49 CPSR cpsrEnCheck = Cpsr;
50 if (cpsrEnCheck.mode == MODE_HYP) {
51 return new UndefinedInstruction(machInst, issEnCheck,
1// -*- mode:c++ -*-
2
3// Copyright (c) 2010-2013 ARM Limited
4// All rights reserved
5//
6// The license below extends only to copyright in the software and shall
7// not be construed as granting a license to any other intellectual
8// property including but not limited to intellectual property relating

--- 35 unchanged lines hidden (view full) ---

44 uint32_t seq;
45 if (!vfpNeonEnabled(seq,Hcptr, Nsacr, Cpacr, Cpsr, issEnCheck,
46 trapEnCheck, xc->tcBase(), Fpexc))
47 {return disabledFault();}
48 if (trapEnCheck) {
49 CPSR cpsrEnCheck = Cpsr;
50 if (cpsrEnCheck.mode == MODE_HYP) {
51 return new UndefinedInstruction(machInst, issEnCheck,
52 EC_TRAPPED_HCPTR);
52 EC_TRAPPED_HCPTR, mnemonic);
53 } else {
54 if (!inSecureState(Scr, Cpsr)) {
55 return new HypervisorTrap(machInst, issEnCheck,
56 EC_TRAPPED_HCPTR);
57 }
58 }
59 }
60 '''

--- 30 unchanged lines hidden (view full) ---

91 {return disabledFault();}
92 if (!inPrivilegedMode(Cpsr))
93 if (dest != (int)MISCREG_FPSCR)
94 return disabledFault();
95 if (trapEnCheck) {
96 CPSR cpsrEnCheck = Cpsr;
97 if (cpsrEnCheck.mode == MODE_HYP) {
98 return new UndefinedInstruction(machInst, issEnCheck,
53 } else {
54 if (!inSecureState(Scr, Cpsr)) {
55 return new HypervisorTrap(machInst, issEnCheck,
56 EC_TRAPPED_HCPTR);
57 }
58 }
59 }
60 '''

--- 30 unchanged lines hidden (view full) ---

91 {return disabledFault();}
92 if (!inPrivilegedMode(Cpsr))
93 if (dest != (int)MISCREG_FPSCR)
94 return disabledFault();
95 if (trapEnCheck) {
96 CPSR cpsrEnCheck = Cpsr;
97 if (cpsrEnCheck.mode == MODE_HYP) {
98 return new UndefinedInstruction(machInst, issEnCheck,
99 EC_TRAPPED_HCPTR);
99 EC_TRAPPED_HCPTR, mnemonic);
100 } else {
101 if (!inSecureState(Scr, Cpsr)) {
102 return new HypervisorTrap(machInst, issEnCheck,
103 EC_TRAPPED_HCPTR);
104 }
105 }
106 }
107 '''

--- 9 unchanged lines hidden (view full) ---

117 {return disabledFault();}
118 if (!inPrivilegedMode(Cpsr))
119 if (op1 != (int)MISCREG_FPSCR)
120 return disabledFault();
121 if (trapEnCheck) {
122 CPSR cpsrEnCheck = Cpsr;
123 if (cpsrEnCheck.mode == MODE_HYP) {
124 return new UndefinedInstruction(machInst, issEnCheck,
100 } else {
101 if (!inSecureState(Scr, Cpsr)) {
102 return new HypervisorTrap(machInst, issEnCheck,
103 EC_TRAPPED_HCPTR);
104 }
105 }
106 }
107 '''

--- 9 unchanged lines hidden (view full) ---

117 {return disabledFault();}
118 if (!inPrivilegedMode(Cpsr))
119 if (op1 != (int)MISCREG_FPSCR)
120 return disabledFault();
121 if (trapEnCheck) {
122 CPSR cpsrEnCheck = Cpsr;
123 if (cpsrEnCheck.mode == MODE_HYP) {
124 return new UndefinedInstruction(machInst, issEnCheck,
125 EC_TRAPPED_HCPTR);
125 EC_TRAPPED_HCPTR, mnemonic);
126 } else {
127 if (!inSecureState(Scr, Cpsr)) {
128 return new HypervisorTrap(machInst, issEnCheck,
129 EC_TRAPPED_HCPTR);
130 }
131 }
132 }
133 '''
134 vmrsApsrEnabledCheckCode = '''
135 uint32_t issEnCheck;
136 bool trapEnCheck;
137 uint32_t seq;
138 if (!vfpNeonEnabled(seq,Hcptr, Nsacr, Cpacr, Cpsr, issEnCheck,
139 trapEnCheck, xc->tcBase()))
140 {return disabledFault();}
141 if (trapEnCheck) {
142 CPSR cpsrEnCheck = Cpsr;
143 if (cpsrEnCheck.mode == MODE_HYP) {
144 return new UndefinedInstruction(machInst, issEnCheck,
126 } else {
127 if (!inSecureState(Scr, Cpsr)) {
128 return new HypervisorTrap(machInst, issEnCheck,
129 EC_TRAPPED_HCPTR);
130 }
131 }
132 }
133 '''
134 vmrsApsrEnabledCheckCode = '''
135 uint32_t issEnCheck;
136 bool trapEnCheck;
137 uint32_t seq;
138 if (!vfpNeonEnabled(seq,Hcptr, Nsacr, Cpacr, Cpsr, issEnCheck,
139 trapEnCheck, xc->tcBase()))
140 {return disabledFault();}
141 if (trapEnCheck) {
142 CPSR cpsrEnCheck = Cpsr;
143 if (cpsrEnCheck.mode == MODE_HYP) {
144 return new UndefinedInstruction(machInst, issEnCheck,
145 EC_TRAPPED_HCPTR);
145 EC_TRAPPED_HCPTR, mnemonic);
146 } else {
147 if (!inSecureState(Scr, Cpsr)) {
148 return new HypervisorTrap(machInst, issEnCheck,
149 EC_TRAPPED_HCPTR);
150 }
151 }
152 }
153 '''

--- 115 unchanged lines hidden ---
146 } else {
147 if (!inSecureState(Scr, Cpsr)) {
148 return new HypervisorTrap(machInst, issEnCheck,
149 EC_TRAPPED_HCPTR);
150 }
151 }
152 }
153 '''

--- 115 unchanged lines hidden ---