-
-
Notifications
You must be signed in to change notification settings - Fork 267
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Segmentation Fault when "struct ModuleReference" added to code file #551
Comments
Thanks for the report. Could you please add some more infos about the ldc version you are using? E.g. output of Are you aware of this thread in the forum? http://forum.dlang.org/post/bcfnbrbrgytdycalklav@forum.dlang.org Maybe you could join forces with Mike. |
I am Mike. I just updated the LDC version information. I'm using Arch Linux 64-bit. |
:-) I was not sure because of the different nicknames. Could you run ldc2 under control of gdb and see if it prints more information? E.g. Is there a possibility that I can compile your code on my box? E.g., do you have a GitHub fork of druntime? |
Here's the backtrace:
I don't have a fork yet. I'm still just trying to learn the basics, and figure out the dependencies. My code is really simple, so I'll just paste it here. *** start.d ***
*** object.d ***
*** rt/sections.d ***
That's all there is to it so far. |
It looks like the crash is caused by some missing |
The compiler assumes that (most of) the types in |
This is missing in your version of
But you should really consider using the provided |
Yep, that's it. I will be adding in object.di and object.d, but the defaults include too many other things, and I'm trying to figure out what is absolutely necessary. Anyway TypeInfo_AssociativeArray gets me past the crash. I guess this report should really be "Add the necessary checks for required types", but I understand my situation is a corner case. |
The scope of the upcoming DMD release 2.065 is to reduce compiler crashes. Obviously, we should do the same for ldc. I will add some checks. |
I'm trying to port the D Runtime to the ARM Cortex-M, and therefore, I'm incrementally importing parts of the Runtime from the LDC runtime codebase and trying to figure out how it works.
Whenever I add the following code to any of my files, the compiler generates a segmentation fault.
Output
If I remove the struct, the compiler executes fine.
I know it might take a while to get to this bug, but I'm stalled if I can't get this struct in my code. So, if you know a temporary workaround, please let me know.
LDC Version Info:
LDC - the LLVM D compiler (0.12.1):
based on DMD v2.063.2 and LLVM 3.3
Default target: x86_64-unknown-linux-gnu
Host CPU: corei7
The text was updated successfully, but these errors were encountered: