Refactor compiler version checks and arch flags
This commit is contained in:
@@ -25,11 +25,15 @@ public:
|
||||
return {prop->major, prop->minor};
|
||||
}
|
||||
|
||||
std::string get_arch() {
|
||||
std::string get_arch(const bool& number_only = false,
|
||||
const bool& support_arch_family = false) {
|
||||
const auto& [major, minor] = get_arch_pair();
|
||||
if (major == 10 and minor != 1)
|
||||
return "100f";
|
||||
return std::to_string(major * 10 + minor) + "a";
|
||||
if (major == 10 and minor != 1) {
|
||||
if (number_only)
|
||||
return "100";
|
||||
return support_arch_family ? "100f" : "100a";
|
||||
}
|
||||
return std::to_string(major * 10 + minor) + (number_only ? "" : "a");
|
||||
}
|
||||
|
||||
int get_arch_major() {
|
||||
|
||||
Reference in New Issue
Block a user