EXSWHTEC-382 - Implement tests for Launch API functions #454
Change-Id: I0720758144e89adaa43bcbcc6262dbb16cd4e2be
Αυτή η υποβολή περιλαμβάνεται σε:
υποβλήθηκε από
Rakesh Roy
γονέας
e0c3f64e78
υποβολή
66e2885107
@@ -35,8 +35,8 @@ TEST_CASE("Unit_hipFuncGetAttributes_Positive_Basic") {
|
||||
|
||||
SECTION("binaryVersion") {
|
||||
#if HT_NVIDIA
|
||||
const auto major = GetDeviceAttribute(0, hipDeviceAttributeComputeCapabilityMajor);
|
||||
const auto minor = GetDeviceAttribute(0, hipDeviceAttributeComputeCapabilityMinor);
|
||||
const auto major = GetDeviceAttribute(hipDeviceAttributeComputeCapabilityMajor, 0);
|
||||
const auto minor = GetDeviceAttribute(hipDeviceAttributeComputeCapabilityMinor, 0);
|
||||
REQUIRE(attr.binaryVersion == major * 10 + minor);
|
||||
#elif HT_AMD
|
||||
REQUIRE(attr.binaryVersion > 0);
|
||||
@@ -48,7 +48,7 @@ TEST_CASE("Unit_hipFuncGetAttributes_Positive_Basic") {
|
||||
SECTION("constSizeBytes") { REQUIRE(attr.constSizeBytes == kConstSizeBytes); }
|
||||
|
||||
SECTION("maxThreadsPerBlock") {
|
||||
REQUIRE(attr.maxThreadsPerBlock == GetDeviceAttribute(0, hipDeviceAttributeMaxThreadsPerBlock));
|
||||
REQUIRE(attr.maxThreadsPerBlock == GetDeviceAttribute(hipDeviceAttributeMaxThreadsPerBlock, 0));
|
||||
}
|
||||
|
||||
SECTION("numRegs") { REQUIRE(attr.numRegs >= 0); }
|
||||
@@ -57,7 +57,7 @@ TEST_CASE("Unit_hipFuncGetAttributes_Positive_Basic") {
|
||||
|
||||
SECTION("sharedSizeBytes") {
|
||||
REQUIRE(attr.sharedSizeBytes <=
|
||||
GetDeviceAttribute(0, hipDeviceAttributeMaxSharedMemoryPerBlock));
|
||||
GetDeviceAttribute(hipDeviceAttributeMaxSharedMemoryPerBlock, 0));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Αναφορά σε νέο ζήτημα
Block a user