}
}
+ void testAddRemoveIntlvBits()
+ {
+ for (Addr addr = start; addr <= end; addr++) {
+ AddrRange &r = range[getIndex(addr)];
+ Addr ch_addr = r.removeIntlvBits(addr);
+ Addr pa = r.addIntlvBits(ch_addr);
+ ASSERT_EQ(addr, pa);
+ }
+ }
+
static const Addr end = 0x1ffff;
static const Addr start = 0x0;
static const int intlvSize = 4;
testGetOffset();
}
+TEST_F(AddrRangeCont, AddrRangeAddRemoveIntlvBits)
+{
+ testAddRemoveIntlvBits();
+}
+
class AddrRangeContLegacy : public AddrRangeCont {
protected:
testGetOffset();
}
+TEST_F(AddrRangeContLegacy, AddrRangeAddRemoveIntlvBits)
+{
+ testAddRemoveIntlvBits();
+}
class AddrRangeArb : public AddrRangeBase {
protected:
{
testGetOffset();
}
+
+TEST_F(AddrRangeArb, AddrRangeAddRemoveIntlvBits)
+{
+ testAddRemoveIntlvBits();
+}