Skip to content
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

System.OutOfMemoryException' was thrown. while i am importing vba classes from local folders #3730

Open
manjugb opened this issue Jan 26, 2018 · 11 comments
Labels
bug Identifies work items for known bugs

Comments

@manjugb
Copy link

manjugb commented Jan 26, 2018

steps to reproduce:
usually when developer finishes or modifiedsclasses , usually i import into my rubberduck tests , to make my tests should work or not. when ever i tried to import , i am getting parse error saying system.outofmemory

here is log

2018-01-26 14:43:05.6248;DEBUG-2.1.2.2766;Rubberduck.Parsing.PreProcessing.VBAPrecompilationParser;SLL mode exception;System.OutOfMemoryException: Exception of type 'System.OutOfMemoryException' was thrown.
   at Antlr4.Runtime.CommonTokenFactory.Create(Tuple`2 source, Int32 type, String text, Int32 channel, Int32 start, Int32 stop, Int32 line, Int32 charPositionInLine)
   at Antlr4.Runtime.CommonTokenFactory.Antlr4.Runtime.ITokenFactory.Create(Tuple`2 source, Int32 type, String text, Int32 channel, Int32 start, Int32 stop, Int32 line, Int32 charPositionInLine)
   at Antlr

@Vogel612
Copy link
Member

@manjugb we really need a few things to find where the problem is in the first place:

  1. Please attach the full logfile. As it stands I can only tell you that the Preprocessing step failed, deep inside the library we use for parsing.
  2. In the log, there will be information about the VBA Host you're using, that information (especially bitness) can tell us more about what memory-constraints your system has.
  3. Assuming that You're not using the 32-bit version of your host, the limit to memory is the physical memory limit you have. If you're using a 64-bit host, could you please tell us how much RAM you have installed?

Last but not least: Does this happen every time when importing any class or can you possibly nail it down to a specific class (and if so, can you make that class smaller and still reproduce the problem?)

@Vogel612 Vogel612 added the bug Identifies work items for known bugs label Jan 26, 2018
@manjugb
Copy link
Author

manjugb commented Jan 26, 2018

here i attached the log
RubberduckLog.txt
Please let me know what are the minimum hardware and software configuration to run rubberduck smoothly

@manjugb
Copy link
Author

manjugb commented Jan 26, 2018

its happen every time when import

@manjugb
Copy link
Author

manjugb commented Jan 26, 2018

check in the txt file line number
20905 and 20912

@Vogel612
Copy link
Member

System Information:

2018-01-26 14:23:40.4049;TRACE-2.1.2.2766;Rubberduck.Common.LogLevelHelper;
	Rubberduck version 2.1.2.2766 loading:
	Operating System: Microsoft Windows NT 6.1.7601 Service Pack 1 x64
	Host Product: Microsoft Office 2010 x86
	Host Version: 14.0.7190.5000
	Host Executable: EXCEL.EXE;

As suspected, the host is a 32-bit host, which means that Rubberduck apparently outdoes the 2GB mark when preprocessing ...

2018-01-26 14:56:34.7823;DEBUG-2.1.2.2766;Rubberduck.Parsing.PreProcessing.VBAPrecompilationParser;SLL mode exception;System.OutOfMemoryException: Exception of type 'System.OutOfMemoryException' was thrown.
   at System.Collections.Generic.List`1.set_Capacity(Int32 value)
   at System.Collections.Generic.List`1.EnsureCapacity(Int32 min)
   at System.Collections.Generic.List`1.Add(T item)
   at Antlr4.Runtime.BufferedTokenStream.Fetch(Int32 n)
   at Antlr4.Runtime.BufferedTokenStream.Sync(Int32 i)
   at Antlr4.Runtime.BufferedTokenStream.Consume()
   at Antlr4.Runtime.Parser.Consume()
   at Rubberduck.Parsing.PreProcessing.VBAConditionalCompilationParser.physicalLine() in C:\projects\rubberduck\Rubberduck.Parsing\PreProcessing\VBAConditionalCompilationParser.cs:line 1302
   at Rubberduck.Parsing.PreProcessing.VBAConditionalCompilationParser.ccBlock() in C:\projects\rubberduck\Rubberduck.Parsing\PreProcessing\VBAConditionalCompilationParser.cs:line 251
   at Rubberduck.Parsing.PreProcessing.VBAConditionalCompilationParser.compilationUnit() in C:\projects\rubberduck\Rubberduck.Parsing\PreProcessing\VBAConditionalCompilationParser.cs:line 167
   at Rubberduck.Parsing.PreProcessing.VBAPrecompilationParser.Parse(String moduleName, CommonTokenStream unprocessedTokenStream, BaseErrorListener errorListener) in C:\projects\rubberduck\Rubberduck.Parsing\PreProcessing\VBAPrecompilationParser.cs:line 24
2018-01-26 14:57:05.9958;ERROR-2.1.2.2766;Rubberduck.Parsing.VBA.ComponentParseTask; Unexpected exception thrown in thread 48 while parsing module VBT_Continuity, ParseTaskID 4bc07eb6-beb2-4999-97a1-a790ce4ddec9.;System.OutOfMemoryException: Exception of type 'System.OutOfMemoryException' was thrown.
   at Antlr4.Runtime.Atn.PredictionContext.Join(PredictionContext context0, PredictionContext context1, PredictionContextCache contextCache)
   at Antlr4.Runtime.Atn.ATNConfigSet.Add(ATNConfig e, PredictionContextCache contextCache)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfigSet sourceConfigs, ATNConfigSet configs, Boolean collectPredicates, Boolean hasMoreContext, PredictionContextCache contextCache, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.ComputeStartState(DFA dfa, ParserRuleContext globalContext, Boolean useContext)
   at Antlr4.Runtime.Atn.ParserATNSimulator.AdaptivePredict(ITokenStream input, Int32 decision, ParserRuleContext outerContext, Boolean useContext)
   at Antlr4.Runtime.Atn.ParserATNSimulator.ExecDFA(DFA dfa, ITokenStream input, Int32 startIndex, SimulatorState state)
   at Antlr4.Runtime.Atn.ParserATNSimulator.AdaptivePredict(ITokenStream input, Int32 decision, ParserRuleContext outerContext, Boolean useContext)
   at Antlr4.Runtime.Atn.ParserATNSimulator.AdaptivePredict(ITokenStream input, Int32 decision, ParserRuleContext outerContext)
   at Rubberduck.Parsing.Grammar.VBAParser.whiteSpace() in C:\projects\rubberduck\Rubberduck.Parsing\Grammar\VBAParser.cs:line 20096
   at Rubberduck.Parsing.Grammar.VBAParser.endOfLine() in C:\projects\rubberduck\Rubberduck.Parsing\Grammar\VBAParser.cs:line 19068
   at Rubberduck.Parsing.Grammar.VBAParser.endOfStatement() in C:\projects\rubberduck\Rubberduck.Parsing\Grammar\VBAParser.cs:line 19163
   at Rubberduck.Parsing.Grammar.VBAParser.block() in C:\projects\rubberduck\Rubberduck.Parsing\Grammar\VBAParser.cs:line 1549
   at Rubberduck.Parsing.Grammar.VBAParser.functionStmt() in C:\projects\rubberduck\Rubberduck.Parsing\Grammar\VBAParser.cs:line 7654
   at Rubberduck.Parsing.Grammar.VBAParser.moduleBodyElement() in C:\projects\rubberduck\Rubberduck.Parsing\Grammar\VBAParser.cs:line 1456
   at Rubberduck.Parsing.Grammar.VBAParser.moduleBody() in C:\projects\rubberduck\Rubberduck.Parsing\Grammar\VBAParser.cs:line 1388
   at Rubberduck.Parsing.Grammar.VBAParser.module() in C:\projects\rubberduck\Rubberduck.Parsing\Grammar\VBAParser.cs:line 364
   at Rubberduck.Parsing.Grammar.VBAParser.startRule() in C:\projects\rubberduck\Rubberduck.Parsing\Grammar\VBAParser.cs:line 267
   at Rubberduck.Parsing.VBA.VBAModuleParser.Parse(String moduleName, CommonTokenStream moduleTokens, IParseTreeListener[] listeners, BaseErrorListener errorListener) in C:\projects\rubberduck\Rubberduck.Parsing\VBA\VBAModuleParser.cs:line 46
   at Rubberduck.Parsing.VBA.ComponentParseTask.ParseInternal(String moduleName, CommonTokenStream tokenStream, IParseTreeListener[] listeners) in C:\projects\rubberduck\Rubberduck.Parsing\VBA\ComponentParseTask.cs:line 184
   at Rubberduck.Parsing.VBA.ComponentParseTask.Start(CancellationToken cancellationToken) in C:\projects\rubberduck\Rubberduck.Parsing\VBA\ComponentParseTask.cs:line 64
2018-01-26 14:57:16.3093;ERROR-2.1.2.2766;Rubberduck.Parsing.VBA.ComponentParseTask; Unexpected exception thrown in thread 50 while parsing module VBT_BuckHF_m_StaticLineReg_OL, ParseTaskID e093bf13-a305-41a5-b078-28421beedc5c.;System.OutOfMemoryException: Exception of type 'System.OutOfMemoryException' was thrown.
   at Antlr4.Runtime.Atn.ATNConfig.Transform(ATNState state, PredictionContext context, SemanticContext semanticContext, Boolean checkNonGreedy, LexerActionExecutor lexerActionExecutor)
   at Antlr4.Runtime.Atn.ATNConfig.Transform(ATNState state, Boolean checkNonGreedy)
   at Antlr4.Runtime.Atn.ParserATNSimulator.GetEpsilonTarget(ATNConfig config, Transition t, Boolean collectPredicates, Boolean inContext, PredictionContextCache contextCache, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfig config, ATNConfigSet configs, ATNConfigSet intermediate, HashSet`1 closureBusy, Boolean collectPredicates, Boolean hasMoreContexts, PredictionContextCache contextCache, Int32 depth, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.Closure(ATNConfigSet sourceConfigs, ATNConfigSet configs, Boolean collectPredicates, Boolean hasMoreContext, PredictionContextCache contextCache, Boolean treatEofAsEpsilon)
   at Antlr4.Runtime.Atn.ParserATNSimulator.ComputeTargetState(DFA dfa, DFAState s, ParserRuleContext remainingGlobalContext, Int32 t, Boolean useContext, PredictionContextCache contextCache)
   at Antlr4.Runtime.Atn.ParserATNSimulator.ComputeReachSet(DFA dfa, SimulatorState previous, Int32 t, PredictionContextCache contextCache)
   at Antlr4.Runtime.Atn.ParserATNSimulator.ExecATN(DFA dfa, ITokenStream input, Int32 startIndex, SimulatorState initialState)
   at Antlr4.Runtime.Atn.ParserATNSimulator.ExecDFA(DFA dfa, ITokenStream input, Int32 startIndex, SimulatorState state)
   at Antlr4.Runtime.Atn.ParserATNSimulator.AdaptivePredict(ITokenStream input, Int32 decision, ParserRuleContext outerContext, Boolean useContext)
   at Antlr4.Runtime.Atn.ParserATNSimulator.ExecDFA(DFA dfa, ITokenStream input, Int32 startIndex, SimulatorState state)
   at Antlr4.Runtime.Atn.ParserATNSimulator.AdaptivePredict(ITokenStream input, Int32 decision, ParserRuleContext outerContext, Boolean useContext)
   at Antlr4.Runtime.Atn.ParserATNSimulator.AdaptivePredict(ITokenStream input, Int32 decision, ParserRuleContext outerContext)
   at Rubberduck.Parsing.PreProcessing.VBAConditionalCompilationParser.ccBlock() in C:\projects\rubberduck\Rubberduck.Parsing\PreProcessing\VBAConditionalCompilationParser.cs:line 259
   at Rubberduck.Parsing.PreProcessing.VBAConditionalCompilationParser.ccIfBlock() in C:\projects\rubberduck\Rubberduck.Parsing\PreProcessing\VBAConditionalCompilationParser.cs:line 483
   at Rubberduck.Parsing.PreProcessing.VBAConditionalCompilationParser.ccBlock() in C:\projects\rubberduck\Rubberduck.Parsing\PreProcessing\VBAConditionalCompilationParser.cs:line 245
   at Rubberduck.Parsing.PreProcessing.VBAConditionalCompilationParser.compilationUnit() in C:\projects\rubberduck\Rubberduck.Parsing\PreProcessing\VBAConditionalCompilationParser.cs:line 167
   at Rubberduck.Parsing.PreProcessing.VBAPrecompilationParser.Parse(String moduleName, CommonTokenStream unprocessedTokenStream, BaseErrorListener errorListener) in C:\projects\rubberduck\Rubberduck.Parsing\PreProcessing\VBAPrecompilationParser.cs:line 45
   at Rubberduck.Parsing.PreProcessing.VBAPreprocessor.PreprocessTokenStream(String moduleName, CommonTokenStream tokenStream, BaseErrorListener errorListener, CancellationToken token) in C:\projects\rubberduck\Rubberduck.Parsing\PreProcessing\VBAPreprocessor.cs:line 23
   at Rubberduck.Parsing.VBA.AttributeParser.Parse(QualifiedModuleName module, CancellationToken cancellationToken) in C:\projects\rubberduck\Rubberduck.Parsing\VBA\AttributeParser.cs:line 34
   at Rubberduck.Parsing.VBA.ComponentParseTask.RunAttributesPass(CancellationToken cancellationToken) in C:\projects\rubberduck\Rubberduck.Parsing\VBA\ComponentParseTask.cs:line 148
   at Rubberduck.Parsing.VBA.ComponentParseTask.Start(CancellationToken cancellationToken) in C:\projects\rubberduck\Rubberduck.Parsing\VBA\ComponentParseTask.cs:line 53
2018-01-26 14:57:21.4979;DEBUG-2.1.2.2766;Rubberduck.Parsing.VBA.RubberduckParserState;Module 'VBT_BuckHF_t_OTAofs' state is changing to 'Error' (thread 34);
2018-01-26 14:57:21.5109;DEBUG-2.1.2.2766;Rubberduck.Parsing.VBA.RubberduckParserState;Module 'VBT_Common' state is changing to 'Error' (thread 52);
2018-01-26 14:57:31.8210;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.ComponentParseTask;ParseTaskID 5075609b-e90b-463e-a4cb-308766a32e01 finished attributes pass.;
2018-01-26 14:57:31.8210;DEBUG-2.1.2.2766;Rubberduck.Parsing.VBA.RubberduckParserState;Module 'ATPG_OtpTest' state is changing to 'Error' (thread 11);
2018-01-26 14:57:37.1717;DEBUG-2.1.2.2766;Rubberduck.Parsing.VBA.RubberduckParserState;Module 'VBT_BasicTrim' state is changing to 'Error' (thread 44);
2018-01-26 14:57:42.4614;DEBUG-2.1.2.2766;Rubberduck.Parsing.VBA.RubberduckParserState;Module 'ATPG_BasicTrim' state is changing to 'Error' (thread 49);
2018-01-26 14:57:47.6436;DEBUG-2.1.2.2766;Rubberduck.Parsing.VBA.RubberduckParserState;Module 'VBT_BuckHF_m_StaticLineReg_OL' state is changing to 'Error' (thread 50);
2018-01-26 14:57:47.6436;DEBUG-2.1.2.2766;Rubberduck.Parsing.VBA.RubberduckParserState;Module 'VBT_Interface' state is changing to 'Error' (thread 51);
2018-01-26 14:57:47.6536;DEBUG-2.1.2.2766;Rubberduck.Parsing.VBA.RubberduckParserState;Module 'VBT_Continuity' state is changing to 'Error' (thread 48);
2018-01-26 14:57:52.8658;DEBUG-2.1.2.2766;Rubberduck.Parsing.VBA.RubberduckParserState;Module 'Util_DiasemiCustom' state is changing to 'Error' (thread 53);
2018-01-26 14:57:52.8658;DEBUG-2.1.2.2766;Rubberduck.Parsing.VBA.RubberduckParserState;Module 'Util_BuckHF' state is changing to 'Parsed' (thread 54);

At this point I should mention that the stacktrace is on line 21k in the log. It seems there's a humungous amount of modules that we parse, which of course takes a toll on memory...

@manjugb The system requirements (especially those for memory) should generally be fulfilled by having a 64-bit OS and host, as well as ~8GB of RAM. Any more than that would most likely brick the VBE anyways.
Could you tell me how many modules the project you're importing has?

@manjugb
Copy link
Author

manjugb commented Jan 26, 2018

this is least size project which containes arround 20 classes from dev, i started write my rubberduck tests [5 tests classes which containes over all 25 test methods] , i must import basic needs of modules, then only my tests works.

@Vogel612
Copy link
Member

@MDoerner raised an interesting point in chat just now: If you import these modules in rapid succession, Rubberduck may still be working on the first import, while you already import the next module. This can lead to a significant increase in memory consumption ...

Could you try waiting for Rubberduck to report a Ready status before importing the next module?
That might already fix the symptom

@retailcoder
Copy link
Member

retailcoder commented Jan 26, 2018

@manjugb haven't looked at the full log, but are you importing the modules from the Code Explorer or from the VBE's own "import" command? The VBE doesn't allow selecting multiple files AFAIK, but Rubberduck's import tool does - and when RD imports the files it knows to only initiate a parse after all modules are imported... whereas importing files one at a time via the VBE's import command makes Rubberduck work harder - a module is created in the VBE, we launch a parse task; then another module is created, we try to cancel the first task and launch a new one - then another module is created in the VBE, we try to cancel the previous one, and launch a parse task - this one completes, and inspections start running - then another module is created in the VBE, so we cancel the previous parse task, but inspections keep running in the background (we need to fix that); we launch a new parse task, and so on. When RD is doing the import, we disable "module created" event handling, import all the selected files, re-enable event handling, and launch one parse task that picks up all the new modules.

FWIW I'm running 32-bit Office 2010 too (albeit with 8GB RAM), and my 107-module project imports & exports just fine :0)

@Vogel612
Copy link
Member

OBTW: linking to #3347 for another instance of RAM consumption being heavy...

@manjugb
Copy link
Author

manjugb commented Jan 26, 2018

Great thanks for explanation, i will try do as you explained on monday

@retailcoder
Copy link
Member

@manjugb looking at the logs right now - your project seems to have lots of references:

2018-01-26 14:25:02.1598;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'VBA'.;
2018-01-26 14:25:02.1598;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'Excel'.;
2018-01-26 14:25:02.1598;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'stdole'.;
2018-01-26 14:25:02.1598;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'VBA'.;
2018-01-26 14:25:02.1598;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'Excel'.;
2018-01-26 14:25:02.1598;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'stdole'.;
2018-01-26 14:25:02.2208;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'Office'.;
2018-01-26 14:25:02.2208;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'MSForms'.;
2018-01-26 14:25:02.2208;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'Office'.;
2018-01-26 14:25:02.2208;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'MSForms'.;
2018-01-26 14:25:02.5340;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'ERRORSERVICELib'.;
2018-01-26 14:25:02.5340;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'ERRORSERVICELib'.;
2018-01-26 14:25:02.5340;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'DataTool'.;
2018-01-26 14:25:02.5340;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'DataTool'.;
2018-01-26 14:25:02.5340;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'IGXLLanguage'.;
2018-01-26 14:25:02.5340;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'IGXLLanguage'.;
2018-01-26 14:25:02.6430;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'STDSVCCLIENTLib'.;
2018-01-26 14:25:02.6430;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'STDSVCCLIENTLib'.;
2018-01-26 14:25:03.6185;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'AdjusterLib'.;
2018-01-26 14:25:03.6185;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'AdjusterLib'.;
2018-01-26 14:25:03.6185;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'ArrayMgt'.;
2018-01-26 14:25:03.6185;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'ArrayMgt'.;
2018-01-26 14:25:03.6255;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'DDRMemoryLI'.;
2018-01-26 14:25:03.6255;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'DDRMemoryLI'.;
2018-01-26 14:25:03.6475;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'DMCharacterizationMgrNet'.;
2018-01-26 14:25:03.6475;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'DMCharacterizationMgrNet'.;
2018-01-26 14:25:03.7136;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'DMCharacterizationMgrNetLib'.;
2018-01-26 14:25:03.7136;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'DMCharacterizationMgrNetLib'.;
2018-01-26 14:25:03.8036;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'LoopbackLI'.;
2018-01-26 14:25:03.8036;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'LoopbackLI'.;
2018-01-26 14:25:03.8446;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'NWire'.;
2018-01-26 14:25:03.8446;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'NWire'.;
2018-01-26 14:25:03.8846;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'PINDATASRVLib'.;
2018-01-26 14:25:03.8846;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'PINDATASRVLib'.;
2018-01-26 14:25:03.9167;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'PRBSLI'.;
2018-01-26 14:25:03.9167;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'PRBSLI'.;
2018-01-26 14:25:03.9657;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'ProtocolServiceNet'.;
2018-01-26 14:25:03.9917;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'ProtocolServiceNet'.;
2018-01-26 14:25:04.4069;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'SVCPROVIDERLib'.;
2018-01-26 14:25:04.4339;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'SVCPROVIDERLib'.;
2018-01-26 14:25:04.4439;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'SWireLI'.;
2018-01-26 14:25:04.4439;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'SWireLI'.;
2018-01-26 14:25:04.4819;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'TESTELEMENTSUPPORTLib'.;
2018-01-26 14:25:04.4839;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'TESTELEMENTSUPPORTLib'.;
2018-01-26 14:25:04.5099;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'TERMISCUTILSLib'.;
2018-01-26 14:25:04.5099;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'TERMISCUTILSLib'.;
2018-01-26 14:25:04.5530;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'TraceServiceLib'.;
2018-01-26 14:25:04.5530;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'TraceServiceLib'.;
2018-01-26 14:25:04.5530;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'AuditService'.;
2018-01-26 14:25:04.5610;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'AuditService'.;
2018-01-26 14:25:04.5850;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'VBIDE'.;
2018-01-26 14:25:04.5850;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'VBIDE'.;
2018-01-26 14:25:04.6720;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'Template'.;
2018-01-26 14:25:04.6720;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'Template'.;
2018-01-26 14:25:04.6890;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'DATALOGSERVICELib'.;
2018-01-26 14:25:04.6890;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'DATALOGSERVICELib'.;
2018-01-26 14:25:04.8091;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'DemodLib'.;
2018-01-26 14:25:04.8111;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'DemodLib'.;
2018-01-26 14:25:04.9232;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'DSPALGSLib'.;
2018-01-26 14:25:04.9232;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'TestProcIEWizard'.;
2018-01-26 14:25:04.9232;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'DSPALGSLib'.;
2018-01-26 14:25:04.9232;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'TestProcIEWizard'.;
2018-01-26 14:25:04.9522;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'DSPUTILITYLib'.;
2018-01-26 14:25:04.9522;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'TestProcIEWizardEx'.;
2018-01-26 14:25:04.9802;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'TestProcIEWizardEx'.;
2018-01-26 14:25:04.9522;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'MWSParameterEx'.;
2018-01-26 14:25:05.0082;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'INSTRUMENTWAVELib'.;
2018-01-26 14:25:05.0212;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'S_PARAMETERLib'.;
2018-01-26 14:25:05.0212;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'PCIeLI'.;
2018-01-26 14:25:05.0482;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'INSTRUMENTWAVELib'.;
2018-01-26 14:25:05.0362;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'MSXML2'.;
2018-01-26 14:25:05.0482;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'PCIeLI'.;
2018-01-26 14:25:05.0482;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'S_PARAMETERLib'.;
2018-01-26 14:25:05.0212;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'DSPUTILITYLib'.;
2018-01-26 14:25:05.0812;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'ASCII_Utils'.;
2018-01-26 14:25:05.1583;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'Scratch'.;
2018-01-26 14:25:05.0362;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'ProtocolAware'.;
2018-01-26 14:25:05.1153;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'IGXL_Utils'.;
2018-01-26 14:25:05.1153;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'PATTERNDATAMANAGERLib'.;
2018-01-26 14:25:05.1773;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'PATTERNDATAMANAGERLib'.;
2018-01-26 14:25:05.1773;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'IGXL_Utils'.;
2018-01-26 14:25:05.0482;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'MSXML2'.;
2018-01-26 14:25:05.1983;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'CALJOBCONFIGLIBLib'.;
2018-01-26 14:25:05.2623;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'Scripting'.;
2018-01-26 14:25:05.0482;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'ADODB'.;
2018-01-26 14:25:05.2683;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'ProtocolAware'.;
2018-01-26 14:25:05.2683;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'ADODB'.;
2018-01-26 14:25:05.2683;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'ASCII_Utils'.;
2018-01-26 14:25:05.2683;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'Scratch'.;
2018-01-26 14:25:05.2683;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'Scripting'.;
2018-01-26 14:25:05.1153;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'PROCMGRLib'.;
2018-01-26 14:25:05.3514;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'PROCMGRLib'.;
2018-01-26 14:25:05.3604;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'CALJOBCONFIGLIBLib'.;
2018-01-26 14:25:05.1983;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;Loading referenced type 'VBRUN'.;
2018-01-26 14:25:05.3884;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'VBRUN'.;
2018-01-26 14:25:05.4244;TRACE-2.1.2.2766;Rubberduck.Parsing.VBA.COMReferenceSynchronizerBase;COM reflecting reference 'MWSParameterEx'.;

If some of these libraries aren't needed, I'd recommend removing their reference - that could greatly improve the memory situation. With all these libraries loaded it wouldn't surprise me that Rubberduck's resolver would be caching something in the ballpark of a million Declaration objects

Note that Lines 182 and 183 of Util_DiasemiCustom seem to be momentarily confusing the parser - see if there's any extraneous instructions separators on these lines; removing them could speed up the parsing.

The logs contain a number of resolver failure notifications involving relatively complex expressions; consider splitting member accesses across multiple instructions - if a member returns a Variant or an Object and its return value has further member calls, the rest of the expression can't be resolved because we don't know what type we're looking at. This shouldn't be a problem, except when local variables get involved further down the expression I think we might end up missing these references (@MDoerner right?)

@Vogel612 Vogel612 added the hacktoberfest Tags issues for Hacktoberfest 2019 label Sep 20, 2019
@bclothier bclothier removed the hacktoberfest Tags issues for Hacktoberfest 2019 label Nov 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Identifies work items for known bugs
Projects
None yet
Development

No branches or pull requests

4 participants