make it possible to disable all CPU features usage via "all" keyword

Signed-off-by: Ivailo Monev <xakepa10@laimg.moc>
This commit is contained in:
Ivailo Monev 2016-08-09 19:19:39 +00:00
parent 12a8fc09c3
commit b3ae735d42

View file

@ -387,7 +387,9 @@ uint qDetectCPUFeatures()
uint f = detectProcessorFeatures();
QByteArray disable = qgetenv("QT_NO_CPU_FEATURE");
if (!disable.isEmpty()) {
if (disable == "all") {
f = 0;
} else if (!disable.isEmpty()) {
disable.prepend(' ');
for (int i = 0; i < features_count; ++i) {
if (disable.contains(features_string + features_indices[i]))