Hi D community!

I’m here again, to describe what I’ve done during the seventh week of Symmetry Autumn of Code.

LLVM/LLDB upstream status update

Some trivial changes about LLDB plugins got merged and a fix got raised after my investigation on https://bugs.llvm.org/show_bug.cgi?id=45856 .

I have some fresh news about the demangler being upstreamed. It appears that approval from official foundation members is not going forward, as expected. At this point, most of the code from libiberty got changed, at least on the first patches. This is unfortunate, but I’m going to do my best to push this forward. I have some experience with D demangling, so making a clean room implementation is not big of a deal, it is just time consuming.

Some of my considerations on this is to try to contact every single contributor in d-demangler.c file, which is roughly 5 contributors, but I still need to coordinate this with them and my mentor for the best option.

About the D plugin for LLDB, I also got news. They seems to accept new language plugins as long as there is enough maintainers. If someone wants to volunteer to co-maintain it, I would appreciate.

DWARF Abbreviation refactor

I pushed the refactor I was working on in the past week. You can find more about it here: https://github.com/dlang/dmd/pull/13237 . I’m probably going to freeze this until I fix the other issues that have much more priority and work on this when DWARF behaviour is more consistent.

During the refactor I accidentally discovered a double free after rebasing with andrea’s change and reported some ASAN issues I found suitable to report:

Fixed issues

Delegates are now distinguishable

Previously, delegates was being generated with _Delegate naming and now they use the qualified name of the type, being something similar to void delegate() @nogc. You can find the patch and the associated issue here:

wchar_t reports incorrect DECL attributes

When a wchar is used, the typedef generated by the compiler reports a dummy filename and line declarations. I fixed this on:

dchar encoding is missing

When using dchar type, encoding is not correctly reported as UTF and debuggers like LLDB doesn’t show it properly. I fixed it on:

During these various fixes, I ended up making the following trivial minor patches:

Other reported issues

I also reported the following issues that I’ll consider fixing next week:

What is next?

I didn’t have much time this week to make all the tasks I wanted to do, which was primarily fixing the compiler related issues. I’m currently in a conference and my productive is limited. I hope next week I can do a bit more stuff and hopefully fix most of the issues I have in mind to homogenize the DWARF generation.

You can also read this on the D programming language forum, here, and discuss there.

Read about the previous week and the next week.