@(require_target_feature=<string>) @(enable_target_feature=<string>)

require_target_feature - required by the target micro-architecture
enable_target_feature - will be enabled for the specified procedure only
This commit is contained in:
gingerBill
2022-05-30 14:53:12 +01:00
parent cef022539e
commit f3aefbc443
16 changed files with 533 additions and 9 deletions

View File

@@ -3207,6 +3207,22 @@ DECL_ATTRIBUTE_PROC(proc_decl_attribute) {
}
}
return true;
} else if (name == "require_target_feature") {
ExactValue ev = check_decl_attribute_value(c, value);
if (ev.kind == ExactValue_String) {
ac->require_target_feature = ev.value_string;
} else {
error(elem, "Expected a string value for '%.*s'", LIT(name));
}
return true;
} else if (name == "enable_target_feature") {
ExactValue ev = check_decl_attribute_value(c, value);
if (ev.kind == ExactValue_String) {
ac->enable_target_feature = ev.value_string;
} else {
error(elem, "Expected a string value for '%.*s'", LIT(name));
}
return true;
}
return false;
}