aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/ScriptInterpreter/Python/PythonReadline.h
diff options
context:
space:
mode:
authorhev <wangrui@loongson.cn>2025-11-07 21:01:53 +0800
committerGitHub <noreply@github.com>2025-11-07 21:01:53 +0800
commitcdc3cb20543bcb574f08ab23bffe0699f7a9cdc8 (patch)
tree7b6a478d81518ad3579913b4bd46871f5d622205 /lldb/source/Plugins/ScriptInterpreter/Python/PythonReadline.h
parent3719c438dc4a6d5035fc8da4bfe2a04acdaecfea (diff)
downloadllvm-cdc3cb20543bcb574f08ab23bffe0699f7a9cdc8.zip
llvm-cdc3cb20543bcb574f08ab23bffe0699f7a9cdc8.tar.gz
llvm-cdc3cb20543bcb574f08ab23bffe0699f7a9cdc8.tar.bz2
[LoongArch] Add `isSafeToMove` hook to prevent unsafe instruction motion (#163725)
This patch introduces a new virtual method `TargetInstrInfo::isSafeToMove()` to allow backends to control whether a machine instruction can be safely moved by optimization passes. The `BranchFolder` pass now respects this hook when hoisting common code. By default, all instructions are considered safe to to move. For LoongArch, `isSafeToMove()` is overridden to prevent relocation-related instruction sequences (e.g. PC-relative addressing and calls) from being broken by instruction motion. Correspondingly, `isSchedulingBoundary()` is updated to reuse this logic for consistency. Fixes #163681
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/PythonReadline.h')
0 files changed, 0 insertions, 0 deletions