WebKit Bugzilla
Attachment 343035 Details for
Bug 186801
: [GTK][WPE][Nicosia] Add environment variable to enable threaded rendering and set the number of painting threads
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-186801-20180619114019.patch (text/plain), 3.67 KB, created by
Miguel Gomez
on 2018-06-19 02:40:21 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Miguel Gomez
Created:
2018-06-19 02:40:21 PDT
Size:
3.67 KB
patch
obsolete
>Subversion Revision: 232956 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index 5a8027ccff3a51c60a6e02ef1d33e9a787499b2a..70df022c8750cb9148c040c7fe484b839e3d2b26 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,21 @@ >+2018-06-19 Miguel Gomez <magomez@igalia.com> >+ >+ [GTK][WPE][Nicosia] Add environment variable to enable threaded rendering and set the number of painting threads >+ https://bugs.webkit.org/show_bug.cgi?id=186801 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Add and environment variable to enable the usage of the threaded renderer and define the number >+ of painting threads. >+ >+ No new tests. >+ >+ * platform/graphics/nicosia/NicosiaPaintingEngine.cpp: >+ (Nicosia::PaintingEngine::create): >+ * platform/graphics/nicosia/NicosiaPaintingEngineThreaded.cpp: >+ (Nicosia::PaintingEngineThreaded::PaintingEngineThreaded): >+ * platform/graphics/nicosia/NicosiaPaintingEngineThreaded.h: >+ > 2018-06-19 Youenn Fablet <youenn@apple.com> > > RTCRtpSender.replaceTrack(null) ends current track >diff --git a/Source/WebCore/platform/graphics/nicosia/NicosiaPaintingEngine.cpp b/Source/WebCore/platform/graphics/nicosia/NicosiaPaintingEngine.cpp >index 6de3509a84cff6ae258f86af06acdbafeab9ea55..a911d78f78c85dc4a4e4c340d540bcc78122bb21 100644 >--- a/Source/WebCore/platform/graphics/nicosia/NicosiaPaintingEngine.cpp >+++ b/Source/WebCore/platform/graphics/nicosia/NicosiaPaintingEngine.cpp >@@ -30,11 +30,24 @@ > #include "NicosiaPaintingEngine.h" > > #include "NicosiaPaintingEngineBasic.h" >+#include "NicosiaPaintingEngineThreaded.h" > > namespace Nicosia { > > std::unique_ptr<PaintingEngine> PaintingEngine::create() > { >+ if (const char* numThreadsEnv = getenv("WEBKIT_NICOSIA_PAINTING_THREADS")) { >+ unsigned numThreads = 0; >+ if (sscanf(numThreadsEnv, "%u", &numThreads) == 1) { >+ if (numThreads < 1 || numThreads > 8) { >+ WTFLogAlways("The number of Nicosia painting threads is not between 1 and 8. Using the default value 4\n"); >+ numThreads = 4; >+ } >+ >+ return std::unique_ptr<PaintingEngine>(new PaintingEngineThreaded(numThreads)); >+ } >+ } >+ > return std::unique_ptr<PaintingEngine>(new PaintingEngineBasic); > } > >diff --git a/Source/WebCore/platform/graphics/nicosia/NicosiaPaintingEngineThreaded.cpp b/Source/WebCore/platform/graphics/nicosia/NicosiaPaintingEngineThreaded.cpp >index 760878bb8ee9f09bb50bbba703c18f25daa21693..609d1c301c3f000b93de17cd9e89074c3a457166 100644 >--- a/Source/WebCore/platform/graphics/nicosia/NicosiaPaintingEngineThreaded.cpp >+++ b/Source/WebCore/platform/graphics/nicosia/NicosiaPaintingEngineThreaded.cpp >@@ -59,8 +59,8 @@ static void paintLayer(GraphicsContext& context, GraphicsLayer& layer, const Int > context.restore(); > } > >-PaintingEngineThreaded::PaintingEngineThreaded() >- : m_workerPool(WorkerPool::create(4)) >+PaintingEngineThreaded::PaintingEngineThreaded(unsigned numThreads) >+ : m_workerPool(WorkerPool::create(numThreads)) > { > } > >diff --git a/Source/WebCore/platform/graphics/nicosia/NicosiaPaintingEngineThreaded.h b/Source/WebCore/platform/graphics/nicosia/NicosiaPaintingEngineThreaded.h >index f5580bbed2442de38690884926efd66a7807f168..546be39619f3769e4f7debf7a18651ec82e4d090 100644 >--- a/Source/WebCore/platform/graphics/nicosia/NicosiaPaintingEngineThreaded.h >+++ b/Source/WebCore/platform/graphics/nicosia/NicosiaPaintingEngineThreaded.h >@@ -37,7 +37,7 @@ namespace Nicosia { > > class PaintingEngineThreaded final : public PaintingEngine { > public: >- PaintingEngineThreaded(); >+ PaintingEngineThreaded(unsigned); > virtual ~PaintingEngineThreaded(); > > private:
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 186801
:
343035
|
343037
|
343039