зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1477599 - Move StyloParsingBench helper functions into #if as well. r=emilio
MozReview-Commit-ID: GhcdIdX6IBk --HG-- extra : rebase_source : a6a8870f2605f2fa87a37d775f1250a71797e769
This commit is contained in:
Родитель
77274c3ef2
Коммит
04cfb39e53
|
@ -17,11 +17,13 @@ using namespace mozilla::css;
|
||||||
using namespace mozilla::dom;
|
using namespace mozilla::dom;
|
||||||
using namespace mozilla::net;
|
using namespace mozilla::net;
|
||||||
|
|
||||||
|
// Bug 1436018 - Disable Stylo microbenchmark on Windows
|
||||||
|
#if !defined(_WIN32) && !defined(_WIN64)
|
||||||
|
|
||||||
#define PARSING_REPETITIONS 20
|
#define PARSING_REPETITIONS 20
|
||||||
#define SETPROPERTY_REPETITIONS (1000 * 1000)
|
#define SETPROPERTY_REPETITIONS (1000 * 1000)
|
||||||
#define GETPROPERTY_REPETITIONS (1000 * 1000)
|
#define GETPROPERTY_REPETITIONS (1000 * 1000)
|
||||||
|
|
||||||
|
|
||||||
static void ServoParsingBench() {
|
static void ServoParsingBench() {
|
||||||
|
|
||||||
auto css = AsBytes(MakeStringSpan(EXAMPLE_STYLESHEET));
|
auto css = AsBytes(MakeStringSpan(EXAMPLE_STYLESHEET));
|
||||||
|
@ -98,8 +100,6 @@ static void ServoGetPropertyValueById() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Bug 1436018 - Disable Stylo microbenchmark on Windows
|
|
||||||
#if !defined(_WIN32) && !defined(_WIN64)
|
|
||||||
MOZ_GTEST_BENCH(Stylo, Servo_StyleSheet_FromUTF8Bytes_Bench, ServoParsingBench);
|
MOZ_GTEST_BENCH(Stylo, Servo_StyleSheet_FromUTF8Bytes_Bench, ServoParsingBench);
|
||||||
|
|
||||||
MOZ_GTEST_BENCH(Stylo, Servo_DeclarationBlock_SetPropertyById_Bench, [] {
|
MOZ_GTEST_BENCH(Stylo, Servo_DeclarationBlock_SetPropertyById_Bench, [] {
|
||||||
|
@ -111,4 +111,5 @@ MOZ_GTEST_BENCH(Stylo, Servo_DeclarationBlock_SetPropertyById_WithInitialSpace_B
|
||||||
});
|
});
|
||||||
|
|
||||||
MOZ_GTEST_BENCH(Stylo, Servo_DeclarationBlock_GetPropertyById_Bench, ServoGetPropertyValueById);
|
MOZ_GTEST_BENCH(Stylo, Servo_DeclarationBlock_GetPropertyById_Bench, ServoGetPropertyValueById);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
Загрузка…
Ссылка в новой задаче