diff options
author | Laszlo Agocs <laszlo.agocs@qt.io> | 2020-06-17 16:27:12 +0200 |
---|---|---|
committer | Laszlo Agocs <laszlo.agocs@qt.io> | 2020-06-18 12:18:53 +0200 |
commit | 58ed7422f550d32b5ace9edc7a4887727f53493a (patch) | |
tree | 02d92822097b91b4c8d1105d046838ff11d54a86 /src/quick/scenegraph/util/qsgrhiatlastexture.cpp | |
parent | f4b1e41748adcb9189edf56545bbc2cde7138d9e (diff) |
Remove broken profiler/trace points in the scenegraph
As the todo note says: this profiling is all wrong
Not reporting something is better than reporting something bogus.
The other profiling points, f.ex. in the render loops, seem to work as
expected and give reasonable results in the QML Profiler view in Creator.
The autotest needs fixing because there is no SGContextFrame events left
with the rhi code path either atm, just like with the software backend.
Change-Id: Iee2d3feb586108db50c83c6c03ea415384561ede
Reviewed-by: Christian Strømme <christian.stromme@qt.io>
Diffstat (limited to 'src/quick/scenegraph/util/qsgrhiatlastexture.cpp')
-rw-r--r-- | src/quick/scenegraph/util/qsgrhiatlastexture.cpp | 34 |
1 files changed, 1 insertions, 33 deletions
diff --git a/src/quick/scenegraph/util/qsgrhiatlastexture.cpp b/src/quick/scenegraph/util/qsgrhiatlastexture.cpp index ce697a13fc..82aa680faf 100644 --- a/src/quick/scenegraph/util/qsgrhiatlastexture.cpp +++ b/src/quick/scenegraph/util/qsgrhiatlastexture.cpp @@ -46,19 +46,11 @@ #include <QtGui/QWindow> #include <private/qqmlglobal_p.h> -#include <private/qquickprofiler_p.h> #include <private/qsgdefaultrendercontext_p.h> #include <private/qsgtexture_p.h> #include <private/qsgcompressedtexture_p.h> #include <private/qsgcompressedatlastexture_p.h> -#include <qtquick_tracepoints_p.h> - -#if 0 -#include <private/qsgcompressedtexture_p.h> -#include <private/qsgcompressedatlastexture_p.h> -#endif - QT_BEGIN_NAMESPACE int qt_sg_envInt(const char *name, int defaultValue); @@ -183,33 +175,9 @@ void AtlasBase::commitTextureOperations(QRhiResourceUpdateBatch *resourceUpdates } } - for (TextureBase *t : m_pending_uploads) { - // ### this profiling is all wrong, the real work is done elsewhere - bool profileFrames = QSG_LOG_TIME_TEXTURE().isDebugEnabled(); - if (profileFrames) - qsg_renderer_timer.start(); - - Q_TRACE_SCOPE(QSG_texture_prepare); - Q_QUICK_SG_PROFILE_START(QQuickProfiler::SceneGraphTexturePrepare); - - // Skip bind, convert, swizzle; they're irrelevant - Q_QUICK_SG_PROFILE_SKIP(QQuickProfiler::SceneGraphTexturePrepare, - QQuickProfiler::SceneGraphTexturePrepareStart, 3); - Q_TRACE(QSG_texture_upload_entry); - + for (TextureBase *t : m_pending_uploads) enqueueTextureUpload(t, resourceUpdates); - Q_TRACE(QSG_texture_upload_exit); - Q_QUICK_SG_PROFILE_RECORD(QQuickProfiler::SceneGraphTexturePrepare, - QQuickProfiler::SceneGraphTexturePrepareUpload); - - // Skip mipmap; unused - Q_QUICK_SG_PROFILE_SKIP(QQuickProfiler::SceneGraphTexturePrepare, - QQuickProfiler::SceneGraphTexturePrepareUpload, 1); - Q_QUICK_SG_PROFILE_REPORT(QQuickProfiler::SceneGraphTexturePrepare, - QQuickProfiler::SceneGraphTexturePrepareMipmap); - } - m_pending_uploads.clear(); } |