summaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
diff options
context:
space:
mode:
authorTom Eccles <tom.eccles@arm.com>2023-02-13 15:45:47 +0000
committerTom Eccles <tom.eccles@arm.com>2023-02-14 13:44:59 +0000
commit7a49d50f22ad577d91cda7904c8a162c2cecd4a8 (patch)
treeb5bfe0ffb2a729f8ac8f06181ef1e6c98c41a81a /lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
parenteb436da6b8269407e03b6954319de77a082f4adf (diff)
[flang] support fir.unreachable in stack arrays pass
Some functions (e.g. the main function) end with a call to the STOP statement instead of a func.return. This is lowered as a call to the stop runtime function followed by a fir.unreachable. fir.unreachable is a terminator and so this can cause functions to have no func.return. The stack arrays pass looks to see which heap allocations have always been freed by the time a function returns. Without any returns, the pass does not detect any freed allocations. This patch changes this behaviour so that fir.unreachable is checked as well as func.return. This allows 15 heap allocations for array temporaries in spec2017 exchange2's main function to be moved to the stack. Differential Revision: https://reviews.llvm.org/D143918
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp')
0 files changed, 0 insertions, 0 deletions