locked
Why during full collection program execution is stopped? RRS feed

  • Question

  • Hi

    Why during full collection program execution is stopped?

    Regars
    kicaj
    Saturday, January 15, 2011 6:55 PM

Answers

  • Ok I think I found answer:

     

    "With execution stopped, it's safe for the collector to move all those objects, and to fix all the pointers so that everything is properly linked in its new location."


    kicaj
    • Marked as answer by Cookie Luo Tuesday, January 18, 2011 5:55 AM
    Sunday, January 16, 2011 9:06 AM
  • There have been some change in the .net 4.0 GC so a full pause does not need to occur each time.

     

    http://channel9.msdn.com/shows/Going+Deep/Maoni-Stephens-and-Andrew-Pardoe-CLR-4-Inside-Background-GC/

     

    • Proposed as answer by Cookie Luo Tuesday, January 18, 2011 5:55 AM
    • Marked as answer by Cookie Luo Tuesday, January 18, 2011 5:56 AM
    Sunday, January 16, 2011 11:20 PM

All replies

  • What does this mean?  Can you please provide some more information.
    Sunday, January 16, 2011 1:53 AM
  • I was reading this article:

    http://msdn.microsoft.com/en-us/library/ms973837.aspx

    In information about full collection they say: "In a full collection we must stop the program execution and find all of the roots into the GC heap." but they don`t explain why exactly program execution has to be stopped.

     

    I don`t understand why program execution has to be stopped.

     

    Regards


    kicaj
    Sunday, January 16, 2011 7:39 AM
  • Ok I think I found answer:

     

    "With execution stopped, it's safe for the collector to move all those objects, and to fix all the pointers so that everything is properly linked in its new location."


    kicaj
    • Marked as answer by Cookie Luo Tuesday, January 18, 2011 5:55 AM
    Sunday, January 16, 2011 9:06 AM
  • There have been some change in the .net 4.0 GC so a full pause does not need to occur each time.

     

    http://channel9.msdn.com/shows/Going+Deep/Maoni-Stephens-and-Andrew-Pardoe-CLR-4-Inside-Background-GC/

     

    • Proposed as answer by Cookie Luo Tuesday, January 18, 2011 5:55 AM
    • Marked as answer by Cookie Luo Tuesday, January 18, 2011 5:56 AM
    Sunday, January 16, 2011 11:20 PM