Some D on Linux Progress

I’ve spent some time looking at D again and really trying to evaluate it’s fitness for MMO game development. There’s a lot of holes left still in the whole development picture. The IRC channel has been a really great source of information, and is generally a fun place to hang out.

It might seem like a small thing but a huge milestone I’ve hit recently is getting a full tool chain running patched gcc-4.1 and gdb-6.5 with D support. Here’s a sample call stack from a crasher I’m investigating in phobos. Notice that it has the correct line numbers and all the D symbols are correctly demanged. This isn’t the case if I use stock dmd or gdb.

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread -1211786352 (LWP 19585)]
0xb7dcccbc in memcpy () from /lib/tls/i686/cmov/libc.so.6
(gdb) bt
#0  0xb7dcccbc in memcpy () from /lib/tls/i686/cmov/libc.so.6
#1  0x0805ac8e in _adDupT (ti=@0x806381c, a={length = 134815743, ptr = 0xb7c72c1f})
    at ../.././libphobos/internal/gc/gc.d:1045
#2  0x08055a25 in std.stdio.readln(std.c.stdio._iobuf*, inout char[]) (fp=0xb7ea1440, buf=@0xb7c5932c) at ../.././libphobos/std/stdio.d:447
#3  0x08055aaa in std.stdio.readln(std.c.stdio._iobuf*) (fp=0xb7ea1440)
    at ../.././libphobos/std/stdio.d:281
#4  0x0804a218 in main.ConsoleThread.run() (this=@0xb7c5bb00) at main.d:37
#5  0x08053620 in std.thread.Thread.threadstart() (p=0xb7c5bb00)
    at ../.././libphobos/std/thread.d:988
#6  0xb7eaa46b in start_thread () from /lib/tls/i686/cmov/libpthread.so.0
#7  0xb7e2e6de in clone () from /lib/tls/i686/cmov/libc.so.6
(gdb) 
This entry was posted in d, game programming. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>