| Summary: | Demangling issues with libcxxrt.so.1 | ||
|---|---|---|---|
| Product: | Base System | Reporter: | Ivan Kosarev <ivan> |
| Component: | standards | Assignee: | Ed Maste <emaste> |
| Status: | Closed FIXED | ||
| Severity: | Affects Only Me | CC: | emaste, mmokhi |
| Priority: | --- | Keywords: | needs-qa |
| Version: | 9.2-RELEASE | ||
| Hardware: | Any | ||
| OS: | Any | ||
LLVM cross-reference: http://reviews.llvm.org/D4668 Reported upstream at: https://sourceforge.net/p/elftoolchain/tickets/488/ Guys, does this problem still exist? The upstream reports fixed. Adding proper maintainer-feedback request now, as it was never set to begin with (so no timeout). There are open PRs to upgrade libcxxrt, so I'm setting a dependency relationship. Please correct if wrong. I see now the original report is about libcxxrt in the base. I have wrongly associated this with the port. Reverting. However, since the upstream report is closed, fixed, what to do with this PR? Upstream reports this as closed/fixed and the PR is a year old, so AFAICT it is obsolete. Testing on stable/10 and HEAD shows that this issue no longer exists. The upstream ELF Tool Chain fix was merged to libcxxrt in https://github.com/pathscale/libcxxrt/commit/58e8df3e30043c1a5d5e6dab5932e429a55d3613 and from there merged to FreeBSD in r284551. Merged to stable/10 in r288182. |
This test program: --- #include <stdlib.h> #include <stdio.h> char* __cxa_demangle(const char* mangled_name, char* buf, size_t* n, int* status); void test(const char *mangled) { int status = 0; char *DemangledName = __cxa_demangle(mangled, NULL, NULL, &status); printf("%s: status %d", mangled, status); if(status == 0) { printf("; demangled: '%s'", DemangledName); } free(DemangledName); printf("\n"); } int main() { test("_ZN8DeepFreeILi17EE4freeEPc"); return 0; } --- when linked against libcxxrt.so.1 on x86-64 FreeBSD 9.2 print: --- _ZN8DeepFreeILi17EE4freeEPc: status 0; demangled: 'DeepFree<17E>::free(char*)' --- Note the extra 'E' in 'DeepFree<17E>'. 'DeepFree<17>' is expected. This bug affects passing LLVM's address sanitizers tests on FreeBSD.