aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/ScriptInterpreter/Python/ScriptedPythonInterface.h
diff options
context:
space:
mode:
authorDavid Spickett <david.spickett@linaro.org>2023-02-15 08:55:22 +0000
committerDavid Spickett <david.spickett@linaro.org>2023-02-15 15:30:37 +0000
commit93164dba086df98d50bccf210e3e65115342c483 (patch)
tree234647feb1da662c8e412bb3aa22f0a22d6bb577 /lldb/source/Plugins/ScriptInterpreter/Python/ScriptedPythonInterface.h
parent2a2a6bfcfe8e62886542cb673ac8df349cf26499 (diff)
downloadllvm-93164dba086df98d50bccf210e3e65115342c483.zip
llvm-93164dba086df98d50bccf210e3e65115342c483.tar.gz
llvm-93164dba086df98d50bccf210e3e65115342c483.tar.bz2
[llvm][AArch64] Fix BTI after returns_twice when call has no attributes
Previously we were looking for the returns twice attribute by manually getting the function attributes from the call. This meant that we only found attributes on the call itself, not what it was calling. So if you had: %call1 = call i32 @setjmp(ptr noundef null) We would not BTI protect that even though setjmp clearly needs it. Clang happens to produce: %call = call i32 @setjmp(ptr noundef null) #0 ; returns_twice So all valid calls were protected. This is not guaranteed, the frontend may choose not to put attributes on the call. It is undefined behaviour to call setjmp indirectly (https://pubs.opengroup.org/onlinepubs/9699919799/functions/setjmp.html) but as I misused the APIs here I think it's worth fixing up regardless. Added comments to the test file where the IR differs from what clang would output. Reviewed By: nikic Differential Revision: https://reviews.llvm.org/D144082
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/ScriptedPythonInterface.h')
0 files changed, 0 insertions, 0 deletions