dev-arm: Add a GICv3 model
Change-Id: Ib0067fc743f84ff7be9f12d2fc33ddf63736bdd1 Reviewed-on: https://gem5-review.googlesource.com/c/13436 Reviewed-by: Giacomo Travaglini <giacomo.travaglini@arm.com> Maintainer: Giacomo Travaglini <giacomo.travaglini@arm.com>
This commit is contained in:
committed by
Giacomo Travaglini
parent
7d5696d1a9
commit
93c7fa5731
@@ -282,4 +282,15 @@ inline uint64_t alignToPowerOfTwo(uint64_t val)
|
||||
return val;
|
||||
};
|
||||
|
||||
/**
|
||||
* Count trailing zeros in a 32-bit value.
|
||||
*
|
||||
* Returns 32 if the value is zero. Note that the GCC builtin is
|
||||
* undefined if the value is zero.
|
||||
*/
|
||||
inline int ctz32(uint32_t value)
|
||||
{
|
||||
return value ? __builtin_ctz(value) : 32;
|
||||
}
|
||||
|
||||
#endif // __BASE_BITFIELD_HH__
|
||||
|
||||
Reference in New Issue
Block a user