summaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
diff options
context:
space:
mode:
authorNikita Popov <npopov@redhat.com>2025-09-04 09:27:33 +0200
committerGitHub <noreply@github.com>2025-09-04 09:27:33 +0200
commit4d927a5faf42d025410586f0cdc3bf60ef198a86 (patch)
tree2cfb41316d4cdce65a11091829e736fc7cc4b322 /lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
parent34d4f0c13666ea25b4d27dcb96dfc70da005f286 (diff)
[DataLayout] Specialize the getTypeAllocSize() implementation (#156687)
getTypeAllocSize() currently works by taking the type store size and aligning it to the ABI alignment. However, this ends up doing redundant work in various cases, for example arrays will unnecessarily repeat the alignment step, and structs will fetch the StructLayout multiple times. As this code is rather hot (it is called every time we need to calculate GEP offsets for example), specialize the implementation. This repeats a small amount of logic from getAlignment(), but I think that's worthwhile.
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp')
0 files changed, 0 insertions, 0 deletions