aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.h
diff options
context:
space:
mode:
authorNikita Popov <npopov@redhat.com>2023-01-10 16:06:30 +0100
committerNikita Popov <npopov@redhat.com>2023-01-12 10:00:54 +0100
commit84a5d93f43cd92b489d3ee6327f88764364fdb26 (patch)
tree1649bc8bd9e31f78f4a2a3dfeb83f37fd0014fb1 /lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.h
parent91181db6d6fd896f01e1e89786d6d7d3d09a911e (diff)
downloadllvm-84a5d93f43cd92b489d3ee6327f88764364fdb26.zip
llvm-84a5d93f43cd92b489d3ee6327f88764364fdb26.tar.gz
llvm-84a5d93f43cd92b489d3ee6327f88764364fdb26.tar.bz2
[LangRef] Make !range, !nonnull and !align return poison instead of IUB
Make violation of !range, !nonnull and !align metadata return poison instead of causing immediate undefined behavior. This makes the behavior match that of the nonnull and align parameter and return value attributes. The previous behavior can be restored by additionally specifying the !noundef metadata, same as with parameters. Some benefits of this change are: * This is needed to fix https://github.com/llvm/llvm-project/issues/59888. Under current semantics, it is illegal to add !range annotations based on known bits. Unless we want to drop that optimization entirely, we need to change the !range semantics. * This allows preserving range/nonnull/align metadata on speculated loads. !noundef metadata needs to be dropped, but the poison-generating metadata can be retained. I don't think there are really disadvantages to the change (apart from the need to review and adjust optimizations for the new semantics), as the old behavior is still available via !noundef, so it should be strictly more flexible. Differential Revision: https://reviews.llvm.org/D141386
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.h')
0 files changed, 0 insertions, 0 deletions