Deleted Added
sdiff udiff text old ( 7744:9e11081542e4 ) new ( 7858:ee6641d7c713 )
full compact
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

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

197 typedef GenericISA::UPCState<MachInst> Base;
198
199 enum FlagBits {
200 ThumbBit = (1 << 0),
201 JazelleBit = (1 << 1)
202 };
203 uint8_t flags;
204 uint8_t nextFlags;
205
206 public:
207 PCState() : flags(0), nextFlags(0)
208 {}
209
210 void
211 set(Addr val)
212 {
213 Base::set(val);
214 npc(val + (thumb() ? 2 : 4));
215 }
216
217 PCState(Addr val) : flags(0), nextFlags(0)
218 { set(val); }
219
220 bool
221 thumb() const
222 {
223 return flags & ThumbBit;
224 }
225

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

272 nextJazelle(bool val)
273 {
274 if (val)
275 nextFlags |= JazelleBit;
276 else
277 nextFlags &= ~JazelleBit;
278 }
279
280 void
281 advance()
282 {
283 Base::advance();
284 npc(pc() + (thumb() ? 2 : 4));
285 flags = nextFlags;
286 }
287
288 void
289 uEnd()
290 {
291 advance();
292 upc(0);
293 nupc(1);

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

361 }
362
363 void
364 serialize(std::ostream &os)
365 {
366 Base::serialize(os);
367 SERIALIZE_SCALAR(flags);
368 SERIALIZE_SCALAR(nextFlags);
369 }
370
371 void
372 unserialize(Checkpoint *cp, const std::string &section)
373 {
374 Base::unserialize(cp, section);
375 UNSERIALIZE_SCALAR(flags);
376 UNSERIALIZE_SCALAR(nextFlags);
377 }
378 };
379
380 // Shift types for ARM instructions
381 enum ArmShiftType {
382 LSL = 0,
383 LSR,
384 ASR,

--- 87 unchanged lines hidden ---