mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-30 01:35:20 +08:00
Change maxNBitValue to a constexpr function
Now maxNBitValue can be used with run time variables. Change-Id: I323071400305e05e6303a33e24e90c521246d73f Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
This commit is contained in:
committed by
sys_ocldev
parent
0ba31a46cb
commit
0193b3ea69
@@ -232,7 +232,7 @@ void Event::updateCompletionStamp(uint32_t taskCount, uint32_t tasklevel, FlushS
|
||||
|
||||
cl_ulong Event::getDelta(cl_ulong startTime,
|
||||
cl_ulong endTime) {
|
||||
cl_ulong Max = (1ULL << OCLRT_NUM_TIMESTAMP_BITS) - 1;
|
||||
cl_ulong Max = maxNBitValue(OCLRT_NUM_TIMESTAMP_BITS);
|
||||
cl_ulong Delta = 0;
|
||||
|
||||
startTime &= Max;
|
||||
|
||||
Reference in New Issue
Block a user