aboutsummaryrefslogtreecommitdiff
path: root/clang/test/Index/annotate-nested-name-specifier.cpp
diff options
context:
space:
mode:
authorJason Molenda <jmolenda@apple.com>2024-04-25 16:42:33 -0700
committerGitHub <noreply@github.com>2024-04-25 16:42:33 -0700
commiteb7dc991841489e2f8f18467705944c9136b06d2 (patch)
treeacd2785980bc0438dfe1e862e78e1e7289dafbff /clang/test/Index/annotate-nested-name-specifier.cpp
parent5f67ce5611ba007ed363b6a78b9c4eac85b70837 (diff)
downloadllvm-eb7dc991841489e2f8f18467705944c9136b06d2.zip
llvm-eb7dc991841489e2f8f18467705944c9136b06d2.tar.gz
llvm-eb7dc991841489e2f8f18467705944c9136b06d2.tar.bz2
[lldb] Add SBValue::GetValueAsAddress API (#90144)
I previously added this API via https://reviews.llvm.org/D142792 in 2023, along with changes to the ValueObject class to treat pointer types as addresses, and to annotate those ValueObjects with the original uint64_t byte sequence AND the name of the symbol once stripped, if that points to a symbol. I did this unconditionally for all pointer type ValueObjects, and it caused several regressions in the Objective-C data formatters which have a ValueObject of an object, it has the address of its class -- but with ObjC, sometimes it is a "tagged pointer" which is metadata, not an actual pointer. (e.g. a small NSInteger value is stored entirely in the tagged pointer, instead of a separate object) Treating these not-addresses as addresses -- clearing the non-addressable-bits -- is invalid. The original version of this patch we're using downstream only does this bits clearing for pointer types that are specifically decorated with the pointerauth typequal, but not all of those clang changes are upstreamed to github main yet, so I tried this simpler approach and hit the tagged pointer issue and bailed on the whole patch. This patch, however, is simply adding SBValue::GetValueAsAddress so script writers who know that an SBValue has an address in memory, can strip off any metadata. It's an important API to have for script writers when AArch64 ptrauth is in use, so I'm going to put this part of the patch back on github main now until we can get the rest of that original patch upstreamed.
Diffstat (limited to 'clang/test/Index/annotate-nested-name-specifier.cpp')
0 files changed, 0 insertions, 0 deletions