зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1550422
- P25. Don't make prefs unnecessarily atomic. r=njn
Skip and Once prefs are only ever written on the main thread once. There's no need to make those prefs atomic. Differential Revision: https://phabricator.services.mozilla.com/D31732 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
19a12894ee
Коммит
03b0ba3a01
|
@ -100,25 +100,25 @@ class StaticPrefs {
|
|||
};
|
||||
|
||||
#define PREF(str, cpp_type, default_value)
|
||||
#define VARCACHE_PREF(policy, str, id, cpp_type, default_value) \
|
||||
private: \
|
||||
static cpp_type sVarCache_##id; \
|
||||
\
|
||||
public: \
|
||||
static StripAtomic<cpp_type> id() { \
|
||||
MOZ_ASSERT(UpdatePolicy::policy != UpdatePolicy::Live || \
|
||||
IsAtomic<cpp_type>::value || NS_IsMainThread(), \
|
||||
"Non-atomic static pref '" str \
|
||||
"' being accessed on background thread by getter"); \
|
||||
return sVarCache_##id; \
|
||||
} \
|
||||
static void Set##id(StripAtomic<cpp_type> aValue) { \
|
||||
MOZ_ASSERT(IsAtomic<cpp_type>::value || NS_IsMainThread(), \
|
||||
"Non-atomic static pref '" str \
|
||||
"' being accessed on background thread by setter"); \
|
||||
sVarCache_##id = aValue; \
|
||||
} \
|
||||
static const char* Get##id##PrefName() { return str; } \
|
||||
#define VARCACHE_PREF(policy, str, id, cpp_type, default_value) \
|
||||
private: \
|
||||
static cpp_type sVarCache_##id; \
|
||||
\
|
||||
public: \
|
||||
static StripAtomic<cpp_type> id() { \
|
||||
MOZ_DIAGNOSTIC_ASSERT(UpdatePolicy::policy != UpdatePolicy::Live || \
|
||||
IsAtomic<cpp_type>::value || NS_IsMainThread(), \
|
||||
"Non-atomic static pref '" str \
|
||||
"' being accessed on background thread by getter"); \
|
||||
return sVarCache_##id; \
|
||||
} \
|
||||
static void Set##id(StripAtomic<cpp_type> aValue) { \
|
||||
MOZ_DIAGNOSTIC_ASSERT(IsAtomic<cpp_type>::value || NS_IsMainThread(), \
|
||||
"Non-atomic static pref '" str \
|
||||
"' being accessed on background thread by setter"); \
|
||||
sVarCache_##id = aValue; \
|
||||
} \
|
||||
static const char* Get##id##PrefName() { return str; } \
|
||||
static StripAtomic<cpp_type> Get##id##PrefDefault() { return default_value; }
|
||||
|
||||
#include "mozilla/StaticPrefList.h"
|
||||
|
|
|
@ -79,6 +79,10 @@
|
|||
// of one of those. The C++ preprocessor doesn't like template syntax in a
|
||||
// macro argument, so use the typedefs defines in StaticPrefs.h; for example,
|
||||
// use `ReleaseAcquireAtomicBool` instead of `Atomic<bool, ReleaseAcquire>`.
|
||||
// Pref with a Skip or Once policy can be non-atomic as they are only ever
|
||||
// written to once during the parent process startup.
|
||||
// Pref with a Live policy must be made Atomic if ever accessed outside the
|
||||
// main thread; assertions are in place to prevent incorrect usage.
|
||||
//
|
||||
// - <default-value> is the same as for normal prefs.
|
||||
//
|
||||
|
@ -3248,7 +3252,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.gpu-process.enabled",
|
||||
GPUProcessEnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
// The apz prefs are explained in AsyncPanZoomController.cpp
|
||||
|
@ -3459,28 +3463,28 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"apz.fling_curve_function_x1",
|
||||
APZCurveFunctionX1,
|
||||
AtomicFloat, 0.0f
|
||||
float, 0.0f
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"apz.fling_curve_function_x2",
|
||||
APZCurveFunctionX2,
|
||||
AtomicFloat, 1.0f
|
||||
float, 1.0f
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"apz.fling_curve_function_y1",
|
||||
APZCurveFunctionY1,
|
||||
AtomicFloat, 0.0f
|
||||
float, 0.0f
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"apz.fling_curve_function_y2",
|
||||
APZCurveFunctionY2,
|
||||
AtomicFloat, 1.0f
|
||||
float, 1.0f
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -3529,7 +3533,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"apz.keyboard.enabled",
|
||||
APZKeyboardEnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -3557,7 +3561,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"apz.max_velocity_queue_size",
|
||||
APZMaxVelocityQueueSize,
|
||||
RelaxedAtomicUint32, 5
|
||||
uint32_t, 5
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -3655,7 +3659,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"apz.pinch_lock.buffer_max_age",
|
||||
APZPinchLockBufferMaxAge,
|
||||
RelaxedAtomicInt32, 50
|
||||
int32_t, 50
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -3832,7 +3836,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"dom.vr.enabled",
|
||||
VREnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -3853,7 +3857,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"dom.vr.external.enabled",
|
||||
VRExternalEnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -3881,7 +3885,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"dom.vr.oculus.enabled",
|
||||
VROculusEnabled,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -3909,21 +3913,21 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"dom.vr.openvr.enabled",
|
||||
VROpenVREnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"dom.vr.openvr.action_input",
|
||||
VROpenVRActionInputEnabled,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"dom.vr.osvr.enabled",
|
||||
VROSVREnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -3986,21 +3990,21 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"dom.vr.process.enabled",
|
||||
VRProcessEnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"dom.vr.process.startup_timeout_ms",
|
||||
VRProcessTimeoutMs,
|
||||
RelaxedAtomicInt32, 5000
|
||||
int32_t, 5000
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"dom.vr.service.enabled",
|
||||
VRServiceEnabled,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4178,14 +4182,14 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.android.rgb16.force",
|
||||
AndroidRGB16Force,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"gfx.apitrace.enabled",
|
||||
UseApitrace,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
#if defined(RELEASE_OR_BETA)
|
||||
|
@ -4194,7 +4198,7 @@ VARCACHE_PREF(
|
|||
Skip,
|
||||
"gfx.blocklist.all",
|
||||
BlocklistAll,
|
||||
RelaxedAtomicInt32, 0
|
||||
int32_t, 0
|
||||
)
|
||||
|
||||
#else
|
||||
|
@ -4202,7 +4206,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.blocklist.all",
|
||||
BlocklistAll,
|
||||
RelaxedAtomicInt32, 0
|
||||
int32_t, 0
|
||||
)
|
||||
|
||||
#endif
|
||||
|
@ -4295,7 +4299,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.content.skia-font-cache-size",
|
||||
SkiaContentFontCacheSize,
|
||||
RelaxedAtomicInt32, 5
|
||||
int32_t, 5
|
||||
)
|
||||
|
||||
|
||||
|
@ -4303,14 +4307,14 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.device-reset.limit",
|
||||
DeviceResetLimitCount,
|
||||
RelaxedAtomicInt32, 10
|
||||
int32_t, 10
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"gfx.device-reset.threshold-ms",
|
||||
DeviceResetThresholdMilliseconds,
|
||||
RelaxedAtomicInt32, -1
|
||||
int32_t, -1
|
||||
)
|
||||
|
||||
|
||||
|
@ -4318,14 +4322,14 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.direct2d.disabled",
|
||||
Direct2DDisabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"gfx.direct2d.force-enabled",
|
||||
Direct2DForceEnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4360,21 +4364,21 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.direct3d11.enable-debug-layer",
|
||||
Direct3D11EnableDebugLayer,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"gfx.direct3d11.break-on-error",
|
||||
Direct3D11BreakOnError,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"gfx.direct3d11.sleep-on-create-device",
|
||||
Direct3D11SleepOnCreateDevice,
|
||||
RelaxedAtomicInt32, 0
|
||||
int32_t, 0
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4409,14 +4413,14 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.e10s.hide-plugins-for-scroll",
|
||||
HidePluginsForScroll,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"gfx.e10s.font-list.shared",
|
||||
SharedFontList,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
#if defined(XP_MACOSX)
|
||||
|
@ -4454,7 +4458,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.logging.crash.length",
|
||||
GfxLoggingCrashLength,
|
||||
RelaxedAtomicUint32, 16
|
||||
uint32_t, 16
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4469,21 +4473,21 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.logging.texture-usage.enabled",
|
||||
GfxLoggingTextureUsageEnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"gfx.logging.peak-texture-usage.enabled",
|
||||
GfxLoggingPeakTextureUsageEnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"gfx.logging.slow-frames.enabled",
|
||||
LoggingSlowFramesEnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
// Use gfxPlatform::MaxAllocSize instead of the pref directly
|
||||
|
@ -4491,7 +4495,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.max-alloc-size",
|
||||
MaxAllocSizeDoNotUseDirectly,
|
||||
RelaxedAtomicInt32, (int32_t)500000000
|
||||
int32_t, (int32_t)500000000
|
||||
)
|
||||
|
||||
// Use gfxPlatform::MaxTextureSize instead of the pref directly
|
||||
|
@ -4499,7 +4503,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.max-texture-size",
|
||||
MaxTextureSizeDoNotUseDirectly,
|
||||
RelaxedAtomicInt32, (int32_t)32767
|
||||
int32_t, (int32_t)32767
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4534,7 +4538,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.text.disable-aa",
|
||||
DisableAllTextAA,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4558,28 +4562,28 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.use-iosurface-textures",
|
||||
UseIOSurfaceTextures,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"gfx.use-mutex-on-present",
|
||||
UseMutexOnPresent,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"gfx.use-surfacetexture-textures",
|
||||
UseSurfaceTextureTextures,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"gfx.allow-texture-direct-mapping",
|
||||
AllowTextureDirectMapping,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4593,7 +4597,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.vsync.compositor.unobserve-count",
|
||||
CompositorUnobserveCount,
|
||||
RelaxedAtomicInt32, 10
|
||||
int32_t, 10
|
||||
)
|
||||
|
||||
|
||||
|
@ -4601,14 +4605,14 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.webrender.all",
|
||||
WebRenderAll,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"gfx.webrender.all.qualified",
|
||||
WebRenderAllQualified,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4657,14 +4661,14 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.webrender.enabled",
|
||||
WebRenderEnabledDoNotUseDirectly,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"gfx.webrender.force-disabled",
|
||||
WebRenderForceDisabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4699,7 +4703,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.webrender.split-render-roots",
|
||||
WebRenderSplitRenderRoots,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4715,7 +4719,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"gfx.work-around-driver-bugs",
|
||||
WorkAroundDriverBugs,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
|
||||
|
@ -4810,14 +4814,14 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"image.cache.size",
|
||||
ImageCacheSize,
|
||||
RelaxedAtomicInt32, 5*1024*1024
|
||||
int32_t, 5*1024*1024
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"image.cache.timeweight",
|
||||
ImageCacheTimeWeight,
|
||||
RelaxedAtomicInt32, 500
|
||||
int32_t, 500
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4852,7 +4856,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"image.mem.decode_bytes_at_a_time",
|
||||
ImageMemDecodeBytesAtATime,
|
||||
RelaxedAtomicUint32, 200000
|
||||
uint32_t, 200000
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4866,7 +4870,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"image.mem.animated.discardable",
|
||||
ImageMemAnimatedDiscardable,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4894,28 +4898,28 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"image.mem.surfacecache.discard_factor",
|
||||
ImageMemSurfaceCacheDiscardFactor,
|
||||
RelaxedAtomicUint32, 1
|
||||
uint32_t, 1
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"image.mem.surfacecache.max_size_kb",
|
||||
ImageMemSurfaceCacheMaxSizeKB,
|
||||
RelaxedAtomicUint32, 100 * 1024
|
||||
uint32_t, 100 * 1024
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"image.mem.surfacecache.min_expiration_ms",
|
||||
ImageMemSurfaceCacheMinExpirationMS,
|
||||
RelaxedAtomicUint32, 60*1000
|
||||
uint32_t, 60*1000
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"image.mem.surfacecache.size_factor",
|
||||
ImageMemSurfaceCacheSizeFactor,
|
||||
RelaxedAtomicUint32, 64
|
||||
uint32_t, 64
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4929,14 +4933,14 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"image.multithreaded_decoding.limit",
|
||||
ImageMTDecodingLimit,
|
||||
RelaxedAtomicInt32, -1
|
||||
int32_t, -1
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"image.multithreaded_decoding.idle_timeout",
|
||||
ImageMTDecodingIdleTimeout,
|
||||
RelaxedAtomicInt32, -1
|
||||
int32_t, -1
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4951,7 +4955,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.acceleration.disabled",
|
||||
LayersAccelerationDisabledDoNotUseDirectly,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
// Instead, use gfxConfig::IsEnabled(Feature::HW_COMPOSITING).
|
||||
|
@ -4981,7 +4985,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.acceleration.force-enabled",
|
||||
LayersAccelerationForceEnabledDoNotUseDirectly,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -4995,14 +4999,14 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.amd-switchable-gfx.enabled",
|
||||
LayersAMDSwitchableGfxEnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.async-pan-zoom.enabled",
|
||||
AsyncPanZoomEnabledDoNotUseDirectly,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -5016,7 +5020,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.bufferrotation.enabled",
|
||||
BufferRotationEnabled,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -5033,7 +5037,7 @@ VARCACHE_PREF(
|
|||
Skip,
|
||||
"layers.componentalpha.enabled",
|
||||
ComponentAlphaEnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
#else
|
||||
|
@ -5043,7 +5047,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.componentalpha.enabled",
|
||||
ComponentAlphaEnabled,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
#endif
|
||||
|
@ -5051,7 +5055,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.d3d11.force-warp",
|
||||
LayersD3D11ForceWARP,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -5154,14 +5158,14 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.enable-tiles",
|
||||
LayersTilesEnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.enable-tiles-if-skia-pomtp",
|
||||
LayersTilesEnabledIfSkiaPOMTP,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -5175,28 +5179,28 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.force-shmem-tiles",
|
||||
ForceShmemTiles,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.gpu-process.allow-software",
|
||||
GPUProcessAllowSoftware,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.gpu-process.force-enabled",
|
||||
GPUProcessForceEnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.gpu-process.ipc_reply_timeout_ms",
|
||||
GPUProcessIPCReplyTimeoutMs,
|
||||
RelaxedAtomicInt32, 10000
|
||||
int32_t, 10000
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -5218,7 +5222,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.gpu-process.startup_timeout_ms",
|
||||
GPUProcessTimeoutMs,
|
||||
RelaxedAtomicInt32, 5000
|
||||
int32_t, 5000
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -5253,42 +5257,42 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.mlgpu.enabled",
|
||||
AdvancedLayersEnabledDoNotUseDirectly,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.mlgpu.enable-buffer-cache",
|
||||
AdvancedLayersEnableBufferCache,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.mlgpu.enable-buffer-sharing",
|
||||
AdvancedLayersEnableBufferSharing,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.mlgpu.enable-clear-view",
|
||||
AdvancedLayersEnableClearView,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.mlgpu.enable-cpu-occlusion",
|
||||
AdvancedLayersEnableCPUOcclusion,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.mlgpu.enable-depth-buffer",
|
||||
AdvancedLayersEnableDepthBuffer,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -5302,21 +5306,21 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.mlgpu.enable-on-windows7",
|
||||
AdvancedLayersEnableOnWindows7,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.mlgpu.enable-container-resizing",
|
||||
AdvancedLayersEnableContainerResizing,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.offmainthreadcomposition.force-disabled",
|
||||
LayersOffMainThreadCompositionForceDisabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -5330,7 +5334,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.omtp.capture-limit",
|
||||
LayersOMTPCaptureLimit,
|
||||
RelaxedAtomicUint32, 25 * 1024 * 1024
|
||||
uint32_t, 25 * 1024 * 1024
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -5344,7 +5348,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.omtp.paint-workers",
|
||||
LayersOMTPPaintWorkers,
|
||||
RelaxedAtomicInt32, 1
|
||||
int32_t, 1
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -5365,7 +5369,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.prefer-opengl",
|
||||
LayersPreferOpenGL,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -5404,49 +5408,49 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.tile-width",
|
||||
LayersTileWidth,
|
||||
RelaxedAtomicInt32, 256
|
||||
int32_t, 256
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.tile-height",
|
||||
LayersTileHeight,
|
||||
RelaxedAtomicInt32, 256
|
||||
int32_t, 256
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.tile-initial-pool-size",
|
||||
LayersTileInitialPoolSize,
|
||||
RelaxedAtomicUint32, (uint32_t)50
|
||||
uint32_t, (uint32_t)50
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.tile-pool-unused-size",
|
||||
LayersTilePoolUnusedSize,
|
||||
RelaxedAtomicUint32, (uint32_t)10
|
||||
uint32_t, (uint32_t)10
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.tile-pool-shrink-timeout",
|
||||
LayersTilePoolShrinkTimeout,
|
||||
RelaxedAtomicUint32, (uint32_t)50
|
||||
uint32_t, (uint32_t)50
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.tile-pool-clear-timeout",
|
||||
LayersTilePoolClearTimeout,
|
||||
RelaxedAtomicUint32, (uint32_t)5000
|
||||
uint32_t, (uint32_t)5000
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.tiles.adjust",
|
||||
LayersTilesAdjust,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -5460,7 +5464,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.tiles.edge-padding",
|
||||
TileEdgePaddingEnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -5488,14 +5492,14 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layers.uniformity-info",
|
||||
UniformityInfo,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
Once,
|
||||
"layers.use-image-offscreen-surfaces",
|
||||
UseImageOffscreenSurfaces,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -5717,7 +5721,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"layout.paint_rects_separately",
|
||||
LayoutPaintRectsSeparately,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
// This and code dependent on it should be removed once containerless scrolling looks stable.
|
||||
|
@ -5748,7 +5752,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"media.hardware-video-decoding.force-enabled",
|
||||
HardwareVideoDecodingForceEnabled,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
#ifdef XP_WIN
|
||||
|
@ -5784,7 +5788,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"media.wmf.use-sync-texture",
|
||||
PDMWMFUseSyncTexture,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
@ -5833,7 +5837,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"media.wmf.vp9.enabled",
|
||||
MediaWmfVp9Enabled,
|
||||
RelaxedAtomicBool, true
|
||||
bool, true
|
||||
)
|
||||
|
||||
#endif
|
||||
|
@ -5919,7 +5923,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"slider.snapMultiplier",
|
||||
SliderSnapMultiplier,
|
||||
RelaxedAtomicInt32, 0
|
||||
int32_t, 0
|
||||
)
|
||||
|
||||
|
||||
|
@ -6117,7 +6121,7 @@ VARCACHE_PREF(
|
|||
Once,
|
||||
"webgl.force-layers-readback",
|
||||
WebGLForceLayersReadback,
|
||||
RelaxedAtomicBool, false
|
||||
bool, false
|
||||
)
|
||||
|
||||
VARCACHE_PREF(
|
||||
|
|
Загрузка…
Ссылка в новой задаче