Bug 1278302 - Add failureid for WARP failIfMajorPerformanceCaveat. r=jrmuizel

MozReview-Commit-ID: 2Ieeaqp4Sgj

--HG--
extra : rebase_source : cdb3cfc40bd85a1bc1e8943c2f60b5d9f08b1b2e
This commit is contained in:
Benoit Girard 2016-06-06 13:33:13 -04:00
parent 4934adbfe6
commit 454efa4e56

View File

@ -937,6 +937,8 @@ WebGLContext::SetDimensions(int32_t signedWidth, int32_t signedHeight)
if (mOptions.failIfMajorPerformanceCaveat) {
if (gl->IsWARP()) {
Telemetry::Accumulate(Telemetry::CANVAS_WEBGL_FAILURE_ID,
NS_LITERAL_CSTRING("FEATURE_FAILURE_PERF_WARP"));
const nsLiteralCString text("failIfMajorPerformanceCaveat: Driver is not"
" hardware-accelerated.");
ThrowEvent_WebGLContextCreationError(text);