Create OS agnostic OSTime in AUB/TBX mode

Signed-off-by: Dunajski, Bartosz <bartosz.dunajski@intel.com>
This commit is contained in:
Dunajski, Bartosz
2023-02-01 17:26:39 +00:00
committed by Compute-Runtime-Automation
parent 5097ef4825
commit 31154dc20b
7 changed files with 87 additions and 18 deletions

View File

@@ -74,14 +74,14 @@ TEST(OSTimeWinTests, givenNoOSInterfaceWhenGetCpuTimeThenReturnsSuccess) {
auto osTime(OSTime::create(nullptr));
auto error = osTime->getCpuTime(&time);
EXPECT_TRUE(error);
EXPECT_NE(0u, time);
EXPECT_EQ(0u, time);
}
TEST(OSTimeWinTests, givenNoOSInterfaceWhenGetCpuGpuTimeThenReturnsError) {
TEST(OSTimeWinTests, givenNoOSInterfaceWhenGetCpuGpuTimeThenReturnsSuccess) {
TimeStampData CPUGPUTime = {0};
auto osTime(OSTime::create(nullptr));
auto success = osTime->getCpuGpuTime(&CPUGPUTime);
EXPECT_FALSE(success);
EXPECT_TRUE(success);
EXPECT_EQ(0u, CPUGPUTime.CPUTimeinNS);
EXPECT_EQ(0u, CPUGPUTime.GPUTimeStamp);
}