@@ -57,8 +57,8 @@ bool has_devices ()
57
57
}
58
58
59
59
void
60
- common_test_body (size_t nbytes, const DPPLSyclUSMRef Ptr,
61
- const DPPLSyclQueueRef Q, const char *expected)
60
+ common_test_body (size_t nbytes, const DPPLSyclUSMRef Ptr,
61
+ const DPPLSyclQueueRef Q, const char *expected)
62
62
{
63
63
auto Ctx = DPPLQueue_GetContext (Q);
64
64
@@ -69,9 +69,11 @@ common_test_body(size_t nbytes, const DPPLSyclUSMRef Ptr,
69
69
auto QueueDev = DPPLQueue_GetDevice (Q);
70
70
EXPECT_TRUE (DPPLDevice_AreEq (Dev, QueueDev));
71
71
72
- DPPLQueue_Prefetch (Q, Ptr, nbytes);
72
+ EXPECT_NO_FATAL_FAILURE (DPPLQueue_Prefetch (Q, Ptr, nbytes));
73
+
73
74
DPPLDevice_Delete (QueueDev);
74
75
DPPLDevice_Delete (Dev);
76
+ DPPLContext_Delete (Ctx);
75
77
}
76
78
77
79
} // end of namespace
@@ -86,7 +88,7 @@ struct TestDPPLSyclUSMInterface : public ::testing::Test
86
88
{ }
87
89
};
88
90
89
- TEST_F (TestDPPLSyclUSMInterface, MallocShared)
91
+ TEST_F (TestDPPLSyclUSMInterface, MallocShared)
90
92
{
91
93
if (!has_devices ())
92
94
GTEST_SKIP_ (" Skipping: No Sycl Devices.\n " );
@@ -102,7 +104,7 @@ TEST_F(TestDPPLSyclUSMInterface, MallocShared)
102
104
DPPLQueue_Delete (Q);
103
105
}
104
106
105
- TEST_F (TestDPPLSyclUSMInterface, MallocDevice)
107
+ TEST_F (TestDPPLSyclUSMInterface, MallocDevice)
106
108
{
107
109
if (!has_devices ())
108
110
GTEST_SKIP_ (" Skipping: No Sycl Devices.\n " );
@@ -118,7 +120,7 @@ TEST_F(TestDPPLSyclUSMInterface, MallocDevice)
118
120
DPPLQueue_Delete (Q);
119
121
}
120
122
121
- TEST_F (TestDPPLSyclUSMInterface, MallocHost)
123
+ TEST_F (TestDPPLSyclUSMInterface, MallocHost)
122
124
{
123
125
if (!has_devices ())
124
126
GTEST_SKIP_ (" Skipping: No Sycl Devices.\n " );
@@ -134,7 +136,7 @@ TEST_F(TestDPPLSyclUSMInterface, MallocHost)
134
136
DPPLQueue_Delete (Q);
135
137
}
136
138
137
- TEST_F (TestDPPLSyclUSMInterface, AlignedAllocShared)
139
+ TEST_F (TestDPPLSyclUSMInterface, AlignedAllocShared)
138
140
{
139
141
if (!has_devices ())
140
142
GTEST_SKIP_ (" Skipping: No Sycl Devices.\n " );
@@ -150,7 +152,7 @@ TEST_F(TestDPPLSyclUSMInterface, AlignedAllocShared)
150
152
DPPLQueue_Delete (Q);
151
153
}
152
154
153
- TEST_F (TestDPPLSyclUSMInterface, AlignedAllocDevice)
155
+ TEST_F (TestDPPLSyclUSMInterface, AlignedAllocDevice)
154
156
{
155
157
if (!has_devices ())
156
158
GTEST_SKIP_ (" Skipping: No Sycl Devices.\n " );
@@ -166,7 +168,7 @@ TEST_F(TestDPPLSyclUSMInterface, AlignedAllocDevice)
166
168
DPPLQueue_Delete (Q);
167
169
}
168
170
169
- TEST_F (TestDPPLSyclUSMInterface, AlignedAllocHost)
171
+ TEST_F (TestDPPLSyclUSMInterface, AlignedAllocHost)
170
172
{
171
173
if (!has_devices ())
172
174
GTEST_SKIP_ (" Skipping: No Sycl Devices.\n " );
0 commit comments