Deleted Added
sdiff udiff text old ( 12749:223c83ed9979 ) new ( 12766:1c347e60c7fd )
full compact
1/*
2 * Copyright (c) 2012-2013,2017 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

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

440 accessDelta(0), depth(0)
441 {
442 setVirt(asid, vaddr, size, flags, mid, pc);
443 setContext(cid);
444 }
445
446 Request(int asid, Addr vaddr, unsigned size, Flags flags, MasterID mid,
447 Addr pc, ContextID cid, AtomicOpFunctor *atomic_op)
448 {
449 setVirt(asid, vaddr, size, flags, mid, pc, atomic_op);
450 setContext(cid);
451 }
452
453 Request(const Request& other)
454 : _paddr(other._paddr), _size(other._size),
455 _masterId(other._masterId),
456 _flags(other._flags),
457 _memSpaceConfigFlags(other._memSpaceConfigFlags),
458 privateFlags(other.privateFlags),
459 _time(other._time),
460 _taskId(other._taskId), _asid(other._asid), _vaddr(other._vaddr),
461 _extraData(other._extraData), _contextId(other._contextId),
462 _pc(other._pc), _reqInstSeqNum(other._reqInstSeqNum),
463 translateDelta(other.translateDelta),
464 accessDelta(other.accessDelta), depth(other.depth)
465 {
466 if (other.atomicOpFunctor)
467 atomicOpFunctor = (other.atomicOpFunctor)->clone();
468 else
469 atomicOpFunctor = nullptr;
470 }
471
472 ~Request()
473 {
474 if (hasAtomicOpFunctor()) {
475 delete atomicOpFunctor;
476 }
477 }
478
479 /**

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

487 }
488
489 /**
490 * Set up a virtual (e.g., CPU) request in a previously
491 * allocated Request object.
492 */
493 void
494 setVirt(int asid, Addr vaddr, unsigned size, Flags flags, MasterID mid,
495 Addr pc, AtomicOpFunctor *amo_op = nullptr)
496 {
497 _asid = asid;
498 _vaddr = vaddr;
499 _size = size;
500 _masterId = mid;
501 _pc = pc;
502 _time = curTick();
503
504 _flags.clear(~STICKY_FLAGS);
505 _flags.set(flags);
506 privateFlags.clear(~STICKY_PRIVATE_FLAGS);
507 privateFlags.set(VALID_VADDR|VALID_SIZE|VALID_PC);
508 depth = 0;
509 accessDelta = 0;
510 translateDelta = 0;
511 atomicOpFunctor = amo_op;
512 }
513
514 /**
515 * Set just the physical address. This usually used to record the
516 * result of a translation. However, when using virtualized CPUs
517 * setPhys() is sometimes called to finalize a physical address
518 * without a virtual address, so we can't check if the virtual
519 * address is valid.

--- 418 unchanged lines hidden ---