diff options
author | Ulf Hermann <[email protected]> | 2023-06-21 09:19:16 +0200 |
---|---|---|
committer | Ulf Hermann <[email protected]> | 2023-06-21 14:14:39 +0200 |
commit | dae48cf190c282ef65df94ef7148a93cf3306e2d (patch) | |
tree | c48a25f66e7d22cd0a1b0a41c522118fab58a8cd /src/qmlcompiler/qqmljsbasicblocks.cpp | |
parent | 2e1dbd7e0c8081275a92e36a4800c3721c912597 (diff) |
QmlCompiler: Properly reset before re-running basic blocks pass
If we were within dead code at the end of the previous run we need to
reset the "skip until next label" flag. Otherwise we still assume we're
in dead code at the beginning of the function, with interesting effects.
Pick-to: 6.5 6.6
Fixes: QTBUG-114476
Change-Id: Ib6e3d6c81aad4c8aaac12accdb3936e4136235fc
Reviewed-by: Fabian Kosmale <[email protected]>
Diffstat (limited to 'src/qmlcompiler/qqmljsbasicblocks.cpp')
-rw-r--r-- | src/qmlcompiler/qqmljsbasicblocks.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/qmlcompiler/qqmljsbasicblocks.cpp b/src/qmlcompiler/qqmljsbasicblocks.cpp index 2d76ff971e..57f0572374 100644 --- a/src/qmlcompiler/qqmljsbasicblocks.cpp +++ b/src/qmlcompiler/qqmljsbasicblocks.cpp @@ -51,6 +51,8 @@ QQmlJSCompilePass::InstructionAnnotations QQmlJSBasicBlocks::run( it->second.jumpIsUnconditional = false; } + m_skipUntilNextLabel = false; + reset(); decode(byteCode.constData(), static_cast<uint>(byteCode.size())); for (auto it = m_basicBlocks.begin(), end = m_basicBlocks.end(); it != end; ++it) |