gem5 v24.0.0.0
|
Classes | |
class | BackdoorManagerTest |
Functions | |
TEST_F (BackdoorManagerTest, BasicRemapTest) | |
TEST_F (BackdoorManagerTest, ShrinkTest) | |
TEST_F (BackdoorManagerTest, ReuseTest) | |
Variables | |
const std::vector< AddrRange > | kOriginalRange ({AddrRange(0x0, 0x1000)}) |
const std::vector< AddrRange > | kRemappedRange ({AddrRange(0x1000, 0x2000)}) |
gem5::backdoor_manager_test::TEST_F | ( | BackdoorManagerTest | , |
BasicRemapTest | ) |
The backdoor range is remappedRanges[0], and should be reverted into originalRanges[0].
After the target backdoor is invalidated, the new created backdoor should be freed and removed from the backdoor list.
Definition at line 51 of file backdoor_manager.test.cc.
References gem5::MemBackdoor::invalidate(), gem5::MemBackdoor::ptr(), and gem5::MemBackdoor::range().
gem5::backdoor_manager_test::TEST_F | ( | BackdoorManagerTest | , |
ReuseTest | ) |
The two packets have different address range, but both contained in the original address range.
The address range of the backdoor covers the whole address range, so both packets can be fulfilled by this backdoor.
For the first packet, a new backdoor should be constructed.
For the second packet, it should return the same backdoor as previous one, and no new backdoor should be constructed.
Definition at line 103 of file backdoor_manager.test.cc.
References gem5::MemBackdoor::invalidate().
gem5::backdoor_manager_test::TEST_F | ( | BackdoorManagerTest | , |
ShrinkTest | ) |
The backdoor range is larger than the address remapper's address range. Backdoor is expected to be shrinked.
Definition at line 78 of file backdoor_manager.test.cc.
References gem5::MemBackdoor::invalidate(), gem5::MemBackdoor::ptr(), and gem5::MemBackdoor::range().
const std::vector< AddrRange > gem5::backdoor_manager_test::kOriginalRange({AddrRange(0x0, 0x1000)}) | ( | {AddrRange(0x0, 0x1000)} | ) |
const std::vector< AddrRange > gem5::backdoor_manager_test::kRemappedRange({AddrRange(0x1000, 0x2000)}) | ( | {AddrRange(0x1000, 0x2000)} | ) |