VisualD: VisualDComServer.exe crashes frequently inside D_Parser.dll to stackoverflow.

Random D-user via Digitalmars-d-ide digitalmars-d-ide at puremagic.com
Wed May 6 07:57:42 PDT 2015


I went through hovering all the symbols and it turns out that the 
bindings in Derelict lib actually trigger the crash.
 From there I managed to quickly do a small repro case that 
crashes for me in completely new empty visuald project:

module mytest;

int function(uint) TestCase;
TestCase test;

class TestClass
{
     this()
     {
         test(); // <--- hover on this
     }
}


On Wednesday, 6 May 2015 at 14:36:52 UTC, Random D-user wrote:
> I've been playing more with this and it seems that now my 
> msvc2013 shell also crashes from time to time. But I think it 
> only crashes after VisualDComServer.exe has crashed first.
>
> So, it looks like the issue might be editor/visuald trying to 
> build a "data tip" on mouse hover.
> That would match your tool tip guess. And I guess this could 
> also explain why it's so random, since the mouse cursor 
> probably just randomly hovers on top of some code while I type.
>
> Perhaps I just need to bite the bullet and try to build 
> visualDComParser myself so that I can debug what's wrong with 
> it. (no promises though :))
>
> Anyway, the msvc2013 crash exception is:
>
> -$exception	{System.AccessViolationException: Attempted to read 
> or write protected memory. This is often an indication that 
> other memory is corrupt.
> at 
> Microsoft.VisualStudio.TextManager.Interop.IVsTextViewFilter.GetDataTipText(TextSpan[] 
> pSpan, String& pbstrText)
> at 
> Microsoft.VisualStudio.Editor.Implementation.ShimQuickInfoSource.TryGetQuickInfoFromFilter(IQuickInfoSession 
> session, TextSpan[] dataBufferTextSpan, String& tipText)
> at 
> Microsoft.VisualStudio.Editor.Implementation.ShimQuickInfoSource.AugmentQuickInfoSession(IQuickInfoSession 
> session, IList`1 qiContent, ITrackingSpan& applicableToSpan)
> at 
> Microsoft.VisualStudio.Language.Intellisense.Implementation.QuickInfoSession.Recalculate()
> at 
> Microsoft.VisualStudio.Language.Intellisense.Implementation.QuickInfoSession.Start()
> at 
> Microsoft.VisualStudio.Language.Intellisense.Implementation.DefaultQuickInfoController.OnTextView_MouseHover(Object 
> sender, MouseHoverEventArgs e)
> at 
> Microsoft.VisualStudio.Text.Editor.Implementation.WpfTextView.RaiseHoverEvents()
> at 
> Microsoft.VisualStudio.Text.Editor.Implementation.WpfTextView.OnHoverTimer(Object 
> sender, EventArgs e)
> at System.Windows.Threading.DispatcherTimer.FireTick(Object 
> unused)
> ...
>
> On Sunday, 3 May 2015 at 14:26:22 UTC, Random D-user wrote:
>> Thans for reply.
>>
>> Unfortunately I don't have a clue what it's parsing when it 
>> crashes. It pretty much just randomly crashes (suddenly pops 
>> crash dialog (typically after 10 to 30 min)) as I'm typing 
>> code. I really haven't seen any crashes directly after 
>> attempting to use autocomplete, goto definition etc.
>>
>> My codebase size is 15K+ loc, so isolating the crash is not 
>> trivial.
>>
>> Is there any kind of log, debug message etc. for the visuald 
>> parser?
>> It would really help if I knew what type it was parsing when 
>> it crashed.
>>
>> On Sunday, 3 May 2015 at 13:55:05 UTC, Rainer Schuetze wrote:
>>>
>>> Seems like it is recursing endlessly while generating a 
>>> string representation of some code, maybe a tool tip.
>>>
>>> Can you reduce the relevant code that triggers this and post 
>>> it here?
>>>
>>> Rainer
>>>
>>> On 01.05.2015 09:26, Random D-user wrote:
>>>> I've been toying around with my hobby project lately and 
>>>> VisualD parser
>>>> often (randomly) crashes in the background (and popping 
>>>> crashed program
>>>> dialog of course). So I decided to post this quick bug 
>>>> report on the off
>>>> chance it helps to fix it.
>>>>
>>>> My project compiles with latest DMD 2.067.1 without errors 
>>>> or warnings,
>>>> but it uses quite a bit of legacy d1.0 idioms, since I just 
>>>> ported to
>>>> 2.0 recently.
>>>>
>>>> For Visual D I've been using v0.3.41 beta 1 and 2. MSVC2013 
>>>> shell.
>>>>
>>>> Launching visual studio debugger on crash gives:
>>>>
>>>> An unhandled exception of type 
>>>> 'System.StackOverflowException' occurred
>>>> in D_Parser.dll
>>>>
>>>>>  
>>>>> D_Parser.dll!D_Parser.Resolver.DTypeToCodeVisitor.GenerateCode(D_Parser.Resolver.AbstractType
>>>>> t, bool pretty)
>>>>    D_Parser.dll!D_Parser.Resolver.AbstractType.ToString()
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DTypeToCodeVisitor.VisitDelegateCallSymbol(D_Parser.Resolver.DelegateCallSymbol 
>>>> t)
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DelegateCallSymbol.Accept(D_Parser.Resolver.IResolvedTypeVisitor 
>>>> vis)
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DTypeToCodeVisitor.AcceptType(D_Parser.Resolver.AbstractType 
>>>> t)
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DTypeToCodeVisitor.GenerateCode(D_Parser.Resolver.AbstractType 
>>>> t, bool pretty)
>>>>    D_Parser.dll!D_Parser.Resolver.AbstractType.ToString()
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DTypeToCodeVisitor.VisitDelegateCallSymbol(D_Parser.Resolver.DelegateCallSymbol 
>>>> t)
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DelegateCallSymbol.Accept(D_Parser.Resolver.IResolvedTypeVisitor 
>>>> vis)
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DTypeToCodeVisitor.AcceptType(D_Parser.Resolver.AbstractType 
>>>> t)
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DTypeToCodeVisitor.GenerateCode(D_Parser.Resolver.AbstractType 
>>>> t, bool pretty)
>>>>    D_Parser.dll!D_Parser.Resolver.AbstractType.ToString()
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DTypeToCodeVisitor.VisitDelegateCallSymbol(D_Parser.Resolver.DelegateCallSymbol 
>>>> t)
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DelegateCallSymbol.Accept(D_Parser.Resolver.IResolvedTypeVisitor 
>>>> vis)
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DTypeToCodeVisitor.AcceptType(D_Parser.Resolver.AbstractType 
>>>> t)
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DTypeToCodeVisitor.GenerateCode(D_Parser.Resolver.AbstractType 
>>>> t, bool pretty)
>>>>    D_Parser.dll!D_Parser.Resolver.AbstractType.ToString()
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DTypeToCodeVisitor.VisitDelegateCallSymbol(D_Parser.Resolver.DelegateCallSymbol 
>>>> t)
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DelegateCallSymbol.Accept(D_Parser.Resolver.IResolvedTypeVisitor 
>>>> vis)
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DTypeToCodeVisitor.AcceptType(D_Parser.Resolver.AbstractType 
>>>> t)
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DTypeToCodeVisitor.GenerateCode(D_Parser.Resolver.AbstractType 
>>>> t, bool pretty)
>>>>    D_Parser.dll!D_Parser.Resolver.AbstractType.ToString()
>>>>
>>>>   
>>>> D_Parser.dll!D_Parser.Resolver.DTypeToCodeVisitor.VisitDelegateCallSymbol(D_Parser.Resolver.DelegateCallSymbol 
>>>> t)
>>>>
>>>> ...



More information about the Digitalmars-d-ide mailing list