aboutsummaryrefslogtreecommitdiff
path: root/llvm/unittests/ADT/APIntTest.cpp
diff options
context:
space:
mode:
authorbvlgah <octopus.busts_0w@icloud.com>2024-03-14 17:11:37 +0800
committerGitHub <noreply@github.com>2024-03-14 09:11:37 +0000
commitece2c25ab9f572f719fd18f1ced4fa80f3e5ed1c (patch)
treee4214d03d2b653a0217b09548642de6a5fe3bc68 /llvm/unittests/ADT/APIntTest.cpp
parent8f68022f8e6e54d1aeae4ed301f5a015963089b7 (diff)
downloadllvm-ece2c25ab9f572f719fd18f1ced4fa80f3e5ed1c.zip
llvm-ece2c25ab9f572f719fd18f1ced4fa80f3e5ed1c.tar.gz
llvm-ece2c25ab9f572f719fd18f1ced4fa80f3e5ed1c.tar.bz2
[LLDB][Test] Fix the test case of listing verbose break info on Windows (#85200)
I noticed a failure of [running LLDB test suites on Windows AArch64](https://lab.llvm.org/buildbot/#/builders/219/builds/9849). The failed test case is about checking output of command `breakpoint list -v -L c++`, and an mismatch on the demangled name of a function occurred. The test case expects `ns::func(void)`, but on Windows it is `int ns::func(void)`. It results from the different mangling scheme used by MSVC, and the comparison is as follows: | Scheme | Mangled | Demangled (fully) | Note | | --- | --- | --- | --- | | MSVC | `?func@ns@@YAHXZ` | `int __cdecl ns::func(void)` | [Godbolt](https://godbolt.org/z/5ns8c7xW3) (I have no available Windows device) | | Itanium | `_ZN2ns4funcEv` | `ns::func()` | | According to the current use of MSVC demangling, https://github.com/llvm/llvm-project/blob/8f68022f8e6e54d1aeae4ed301f5a015963089b7/lldb/source/Core/Mangled.cpp#L128-L143 the `__cdecl` specifier is not part of the name. However, the function's parameter types should be present as ` llvm::MSDF_NoVariableType` [does not affect a symbol for functions](https://github.com/llvm/llvm-project/blob/8f68022f8e6e54d1aeae4ed301f5a015963089b7/llvm/lib/Demangle/MicrosoftDemangleNodes.cpp#L417-L453). Therefore, it is inappropriate to assume the demangled name are the same on all platforms. Instead of tweaking the existing code of demangling to get the same (demangled) name, I think it is more reasonable to modify the test case.
Diffstat (limited to 'llvm/unittests/ADT/APIntTest.cpp')
0 files changed, 0 insertions, 0 deletions