macromem.cc (7343:26c00092d9f3) macromem.cc (7395:9386d82f2c0b)
1/*
2 * Copyright (c) 2010 ARM Limited
3 * All rights reserved
4 *
5 * The license below extends only to copyright in the software and shall
6 * not be construed as granting a license to any other intellectual
7 * property including but not limited to intellectual property relating
8 * to a hardware implementation of the functionality of the software

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

156 writeback = true;
157 }
158 if (count > NumFloatArchRegs)
159 count = NumFloatArchRegs;
160
161 numMicroops = count * (single ? 1 : 2) + (writeback ? 1 : 0);
162 microOps = new StaticInstPtr[numMicroops];
163
1/*
2 * Copyright (c) 2010 ARM Limited
3 * All rights reserved
4 *
5 * The license below extends only to copyright in the software and shall
6 * not be construed as granting a license to any other intellectual
7 * property including but not limited to intellectual property relating
8 * to a hardware implementation of the functionality of the software

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

156 writeback = true;
157 }
158 if (count > NumFloatArchRegs)
159 count = NumFloatArchRegs;
160
161 numMicroops = count * (single ? 1 : 2) + (writeback ? 1 : 0);
162 microOps = new StaticInstPtr[numMicroops];
163
164 uint32_t addr = 0;
164 int64_t addr = 0;
165
166 if (!up)
167 addr = 4 * offset;
168
169 bool tempUp = up;
170 for (int j = 0; j < count; j++) {
171 if (load) {
172 microOps[i++] = new MicroLdrFpUop(machInst, vd++, rn,
173 tempUp, addr);
174 if (!single)
165
166 if (!up)
167 addr = 4 * offset;
168
169 bool tempUp = up;
170 for (int j = 0; j < count; j++) {
171 if (load) {
172 microOps[i++] = new MicroLdrFpUop(machInst, vd++, rn,
173 tempUp, addr);
174 if (!single)
175 microOps[i++] = new MicroLdrFpUop(machInst, vd++, rn,
176 tempUp, addr + 4);
175 microOps[i++] = new MicroLdrFpUop(machInst, vd++, rn, tempUp,
176 addr + (up ? 4 : -4));
177 } else {
178 microOps[i++] = new MicroStrFpUop(machInst, vd++, rn,
179 tempUp, addr);
180 if (!single)
177 } else {
178 microOps[i++] = new MicroStrFpUop(machInst, vd++, rn,
179 tempUp, addr);
180 if (!single)
181 microOps[i++] = new MicroStrFpUop(machInst, vd++, rn,
182 tempUp, addr + 4);
181 microOps[i++] = new MicroStrFpUop(machInst, vd++, rn, tempUp,
182 addr + (up ? 4 : -4));
183 }
184 if (!tempUp) {
185 addr -= (single ? 4 : 8);
186 // The microops don't handle negative displacement, so turn if we
187 // hit zero, flip polarity and start adding.
183 }
184 if (!tempUp) {
185 addr -= (single ? 4 : 8);
186 // The microops don't handle negative displacement, so turn if we
187 // hit zero, flip polarity and start adding.
188 if (addr == 0) {
188 if (addr <= 0) {
189 tempUp = true;
189 tempUp = true;
190 addr = -addr;
190 }
191 } else {
192 addr += (single ? 4 : 8);
193 }
194 }
195
196 if (writeback) {
197 if (up) {

--- 20 unchanged lines hidden ---
191 }
192 } else {
193 addr += (single ? 4 : 8);
194 }
195 }
196
197 if (writeback) {
198 if (up) {

--- 20 unchanged lines hidden ---