locked
FxCop run "Out of Memory" RRS feed

  • General discussion

  • Hi all,

    when running FxCop on a Assembly sized over 8 MB, FxCop run "Out of Memory".

    Any ideas out there? Thanks!

    Hubertus

    Wednesday, January 17, 2007 6:49 AM

All replies

  • How much memory do you have your system?

    We do have known memory issues when running over large binaries and a binary of 8MB would, at the moment in 1.35, require over 512 MB RAM. This will be improved in the next version of FxCop/Visual Studio Code Analysis.

    I have also seen other problems when FxCop raises warnings on large string resources, can you try turning off the string resources and see if that makes a difference?

    Regards

    David

    Wednesday, January 17, 2007 3:37 PM
    Moderator
  •  

    First many thanks for the answer.

    We are running FxCop on Systems with 1 GB RAM.

    What exactly do you mean with "try turning off the string resources"? I do not have influence on the process of generating.

    Regards

    Hubertus

     

    Monday, January 22, 2007 6:39 AM
  • If you are using an FxCop project, you can have explicit control over what types and resources FxCop runs over.

    Try unchecking any string resources in the Targets tab page in FxCop and see if that makes a difference.

    Monday, January 22, 2007 4:21 PM
    Moderator
  • I open the FxCop project with the following result:

    Used memory goes from 500 MB up to 1,77 GB

    When I try to walk through the tree to uncheck string resources, FxCop crashes. Here the (short) dump:

    ************** Exception Text **************

    System.NullReferenceException: Object reference not set to an instance of an object.

    at Microsoft.FxCop.Common.NodeBase.set_Checked(Boolean value)

    at Microsoft.FxCop.UI.BaseTreeView.CheckChildren(TreeNode parentNode, Boolean checkState)

    at Microsoft.FxCop.UI.BaseTreeView.CheckChildren(TreeNode parentNode, Boolean checkState)

    at Microsoft.FxCop.UI.BaseTreeView.CheckChildren(TreeNode parentNode, Boolean checkState)

    at Microsoft.FxCop.UI.BaseTreeView.ItemCheckedHandler(Object sender, TreeViewEventArgs e)

    at System.Windows.Forms.TreeView.OnAfterCheck(TreeViewEventArgs e)

    at System.Windows.Forms.TreeView.WndProc(Message& m)

    at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)

    at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)

    at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

     

    Regards

    Hubertus

    Tuesday, January 23, 2007 8:47 AM
  • Hubertus,

    Any chance you send the binary to me (david dot kean at microsoft dot com) so that I can investigate this?

    Regards

    David

    Tuesday, January 23, 2007 3:54 PM
    Moderator
  • I have discussed this with my colleagues. Unfortunately, there is no possibility - it is too much is business logic in the assembly.

    ISorry, but many thanks for your support

    Regards

    Hubertus

    Tuesday, January 30, 2007 6:26 AM
  • Thanks fine, I understand./

    Any chance you could tell me the size/types of embedded resources within the assembly and how big the binary is?

    Tuesday, January 30, 2007 6:55 AM
    Moderator
  • Sorry David,

    but I have noticed the question only now and will find the facts out asap.

    Question:

    To when is the next Version of FxCop planned?

    Regards

    Hubertus

     

    Thursday, March 1, 2007 10:51 AM
  • You should see a beta of the next version towards the second quarter of the year.
    Thursday, March 1, 2007 3:45 PM
    Moderator
  • Hello David,

    send you some assembly-data with mail.

    Regards

    Hubertus

    Friday, March 2, 2007 1:50 PM
  • By the look of what you sent me, it looks like you have about 3 MB of strings.

    Can you try the following:

    1. Open your FxCop project (*.fxcop)
    2. Choose Window -> Targets
    3. Expand your assembly to Resources
    4. Uncheck Resources

    Try that and tell me how you go.

    Regards

    David

     

    Monday, March 5, 2007 5:22 PM
    Moderator
  •  

    Hello David,

     

    .... several months late:

    we changed the code analysis from debug to release (it is more smaller) and it works fine - until now the release assembly also chrashes FxCop!

    We couldn't uncheck Resources, because there is no check-box for Resources. Also when I execute only a small part of the assembly, FxCop terminate during analysis without any message.

    Do you have an idea?

    And when come the next Version of FxCop (you used to say in the 2nd quarter)?

     

    Best regards

     

    Hubertus Wurm

    Monday, August 27, 2007 12:45 PM
  •  

    The beta of FxCop is running a little late as we've been working hard on trying to Visual Studio 2008 out. However, we've nearly got a build ready for another release - it should be within a month or two.

     

    How does the release assembly crash FxCop? What errors do we display?

     

    Thursday, August 30, 2007 4:15 PM
    Moderator
  •  

    Hello David,

     

    FxCop crashes in different ways:

    When I expand the assembly tree (Target window)), following messsage go to the output window:

    Eine Ausnahme vom Typ System.OutOfMemoryException wurde ausgelöst.

     

    When I run "analyze", FxCop exit sometimes without any messages, sometimes just-in-time-debugger started with message:

    Unbehandelte Ausnahme ("System.OutOfMemoryException") in FxCp.exe [3708]

     

    Best regards

     

    Hubertus Wurm

    Friday, August 31, 2007 9:57 AM
  •  

    Hubertus,

     

    Sorry for the late reply - unfortunately, I'm not sure what we can do to work around this besides trying on a machine with a little more RAM.

     

    We have made improvements in this area in 1.36, so when a beta of it releases in the next month or so, hopefully that will solve the problem.

     

    Regards

     

    David

    Thursday, September 6, 2007 5:45 AM
    Moderator