<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" media="screen" href="/styles/xslt/rss.xslt"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:media="http://search.yahoo.com/mrss/" xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" xmlns:c9="http://channel9.msdn.com">
<channel>
	<title>Channel 9 Forums - Coffeehouse - Patrick Dussud interview next week: Questions?</title>
	<atom:link rel="self" type="application/rss+xml" href="http://channel9.msdn.com/Forums/rss"></atom:link>
	<image>
		<url>http://mschnlnine.vo.llnwd.net/d1/Dev/App_Themes/C9/images/feedimage.png</url>
		<title>Channel 9 Forums - Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<link>http://channel9.msdn.com/Forums</link>
	</image>
	<description>Channel 9 keeps you up to date with the latest news and behind the scenes info from Microsoft that developers love to keep up with. From LINQ to SilverLight – Watch videos and hear about all the cool technologies coming and the people behind them.</description>
	<link>http://channel9.msdn.com/Forums</link>
	<language>en</language>
	<pubDate>Wed, 19 Jun 2013 20:40:10 GMT</pubDate>
	<lastBuildDate>Wed, 19 Jun 2013 20:40:10 GMT</lastBuildDate>
	<generator>Rev9</generator>
	<c9:totalResults>24</c9:totalResults>
	<c9:pageCount>-24</c9:pageCount>
	<c9:pageSize>-1</c9:pageSize>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p>We're lucky enough to have gotten on Patrick Dussud's calendar for a Going Deep interview to take place next Friday (that's Friday, June 8, 2007). For those who may not know, Patrick is a Distinguished Engineer and creator of the CLR's garbage collector
 and related technologies. We've wanted to chat with Patrick for a while. Finally, we got him!
<br>
<br>
So, for those of you out there who have been working with managed code for a while (.NET flavor), got any questions (the more technical, the better, but of course personal is fine since this is Channel 9 and humans make software...)?
<br>
<br>
What do you want to know about the CLR's GC? What about GCs in general? <br>
<br>
Ask away and I'll be sure to include a few of your questions in my next Going Deep.<br>
<br>
Thanks!<br>
C</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/255081#255081</link>
		<pubDate>Wed, 30 May 2007 01:18:37 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/255081#255081</guid>
		<dc:creator>Charles</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/Charles/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p>Is it true that I should not call GC.Collect() manually because that would adversely affect the garbage collection schedule? How badly will it affect? Is it beneficial to call Collect() just before allocating a large chunk of memory?</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/b1c5bc0f171c41e880cc9dec007ff34e#b1c5bc0f171c41e880cc9dec007ff34e</link>
		<pubDate>Wed, 30 May 2007 04:45:02 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/b1c5bc0f171c41e880cc9dec007ff34e#b1c5bc0f171c41e880cc9dec007ff34e</guid>
		<dc:creator>sushovande</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/sushovande/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p><blockquote>
<div class="quoteAuthor">sushovande wrote:</div>
<div class="quoteBody">&#65279;Is it true that I should not call GC.Collect() manually because that would adversely affect the garbage collection schedule? How badly will it affect? Is it beneficial to call Collect() just before allocating a large chunk of memory?</div>
</blockquote>
<br>
The only time to call GC.Collect() (or its Java equivalent) is when you're absolutely certain of what you are doing.&nbsp; For instance, if you've just finished using 10,000 objects (or more, depending on size)&nbsp;you are never using again and you need to make a whole
 bunch more, then you might be wise to call it.&nbsp; However, I'm reasonably sure that calling that function could just be ignored (in .NET or Java), as the run-time tends to know better than you do.&nbsp; The vast majority of the time, you're not even working with
 enough dead objects that it is going to matter.&nbsp; Garbage collection in .NET (in theory; of course, I read this back in version 1.0) only happens when you're running out or low on memory.<br>
<br>
(All of the following is based on my memory from a few years back.&nbsp; I could be wrong)&nbsp; Memory in the .NET runtime is different than what the OS does.&nbsp; The OS does some tricks to track what parts of memory are in use, which takes much more time (relatively speaking)&nbsp;than
 .NET for allocations.&nbsp; .NET just maintains a pointer to the top of the heap, and memory is allocated in chunks.&nbsp; If you're running out, GC.Collect will find blocks of memory that aren't in use and compact.&nbsp; I actually did a presentation on this way back in
 the day for the MSDN AA, but things could have changed.<br>
<br>
This would still be a good question though, because I get the impression that memory management is a bit of a mystery.&nbsp; Covering how .NET works here would be good for all devs to know: knowing how to write code doesn't mean you know what is actually going on.&nbsp;
 This is why I advocate everyone learning an honest to goodness assembly language like IA-32 or x64.&nbsp; Studying C and C&#43;&#43; was great, but once I saw how things would translate down lower made great sense to me.&nbsp; (Of course, individual instructions carry their
 own costs, knowing adder and shifter circuit designs shows why one is faster than the other)</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/75c4cf718ffe40d584c89dec007ff380#75c4cf718ffe40d584c89dec007ff380</link>
		<pubDate>Wed, 30 May 2007 08:04:29 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/75c4cf718ffe40d584c89dec007ff380#75c4cf718ffe40d584c89dec007ff380</guid>
		<dc:creator>DoomBringer</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/DoomBringer/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p>Personal questions:</p>
<p>What's his background; how did he end up doing what he does?</p>
<p>What does he do in his spare time and does he draw inspiration from that for his work, or does he see many analogies/parallels between his hobbies and work?</p>
<p>&nbsp;</p>
<p>Herbie</p>
<p>&nbsp;</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/9dfa2b4f1eef499d836f9dec007ff3aa#9dfa2b4f1eef499d836f9dec007ff3aa</link>
		<pubDate>Wed, 30 May 2007 08:40:08 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/9dfa2b4f1eef499d836f9dec007ff3aa#9dfa2b4f1eef499d836f9dec007ff3aa</guid>
		<dc:creator>Herbie Smith</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/Dr Herbie/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p>I wanna know a few things<br>
<br>
- Where is the GC heading? What are some of the major breaktroughs in the technology that is on the horizon, that will make the current technology better? And how will it change over time? Will it become more intelligent?<br>
<br>
- In how many cases is a GC not a good thing? I see that for a operative system like enviroment, you to some extend might wanna do it yourself. While we see that singularity is build in a C#-like language, what are the challenges to make the GC a thing which
 have less backsides, which allows its to be used in most, if not all, cases?</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/ddbb63b40711420bb2ab9dec007ff3d7#ddbb63b40711420bb2ab9dec007ff3d7</link>
		<pubDate>Wed, 30 May 2007 19:39:11 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/ddbb63b40711420bb2ab9dec007ff3d7#ddbb63b40711420bb2ab9dec007ff3d7</guid>
		<dc:creator>Chadk</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/Chadk/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p>silverlight&nbsp; - challenges/changes&nbsp;to the gc.</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/3dd7ef1632024c40bac49dec007ff3ff#3dd7ef1632024c40bac49dec007ff3ff</link>
		<pubDate>Wed, 30 May 2007 20:01:27 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/3dd7ef1632024c40bac49dec007ff3ff#3dd7ef1632024c40bac49dec007ff3ff</guid>
		<dc:creator>anand.t</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/anand.t/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p>Larry Osterman has said that the GC is one factor that speaks against using managed code for multimedia apps since many multimedia tasks rely on low-latency buffer reads/writes so the GC interrupting that flow (even for just a few milliseconds) can result
 in audible clicks and pops in audio for example.<br>
<br>
Is the GC being worked on to make it more &quot;low-latency friendly&quot; to make managed code more multimedia-friendly?</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/07cc47bd5b6d40beb6649dec007ff42a#07cc47bd5b6d40beb6649dec007ff42a</link>
		<pubDate>Thu, 31 May 2007 14:04:29 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/07cc47bd5b6d40beb6649dec007ff42a#07cc47bd5b6d40beb6649dec007ff42a</guid>
		<dc:creator>Stef&#225;n J&#246;kull Sigur&#240;arson</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/Stebet/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p>Explain how do objects get marked for Garbage Collection, and why is it the case that we cannot predict when a GC visit will happen? Also, when does the collection actually happen?<br>
<br>
What causes an object to move from Generation 0 to Generation 1 or to Generation 2, and why is most process memory in Generation 2?<br>
<br>
Can a .NET application&nbsp;have a true memory leak as in the C&#43;&#43; sense where we allocate a chunk of memory&nbsp;and throw away the handle/pointer to it?<br>
<br>
What does Garbage Collection for the Garbage Collector?<br>
<br>
How does Multi-Core processors improve performance of GC<font color="#000000"><b></b></font> Operations? Can parallelism benifit things in GC<b></b>? [GC Threads].<br>
<br>
<br>
In the Database Connection side, why do I have to close and dispose its objects? Isnt that the job of the GC?<br>
<br>
<br>
Why does GC Halt Program execution as it searches for objects to GC? Isnt this bad for performance?<br>
<br>
What happens when the GC is unable to reclaim memory used by objects marked for Garbage collection? How does GC behave under exhaustive system conditions ?
<br>
<br>
Can GC cause memory corruption?<br>
<br>
<br>
Thanks<br></p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/62c26a5701374e0491fd9dec007ff458#62c26a5701374e0491fd9dec007ff458</link>
		<pubDate>Thu, 31 May 2007 17:17:12 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/62c26a5701374e0491fd9dec007ff458#62c26a5701374e0491fd9dec007ff458</guid>
		<dc:creator>SecretSoftware</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/SecretSoftware/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p><blockquote>
<div class="quoteAuthor">littleguru wrote:</div>
<div class="quoteBody">&#65279;<br>
&#65279;Hey Charles, <br>
<br>
I have a few:<br>
<br>
- What are the challenges in implementing a GC that is also written in managed code?
<br>
<br>
- Why does WeakReference not have a Event that fires upon the Garbage collector has collected the object (i have seen that WeakReference is integrated very deeply in the CLR - he might perhapshave infos on this)?<br>
<br>
- What was the biggest challenge when building GC v1.0? Has the GC been written from scratch for .NET 1.0?<br>
<br>
- Why isn't it possible to force the GC to do a collect. I mean GC.Collect() just signalizes that a collect is required, but the GC could decide to do not. Why has this been implemented in that way?<br>
<br>
- I have seen that memory is not always returned to the Windows operating system. I know that requesting memory from Windows is slow. What's the threshold here? Does this vary from Windows to Windows? Windows XP vs Windows Server 2003...<br>
<br>
- What are the major differences between the GC in the compact framework and the GC<b></b> in the full desktop framework? What should we look after when we code for the compact framework and want the GC to be efficient?<br>
<br>
- Are there any upcoming changes for .NET 3.5? Why does WeakReference still not have a Collected event?<br>
<br>
- What was the biggest (big as hardest to fix) bug he ever found in the GC?<br>
<br>
- Is the GC building the reachable tree on each run? Or are there caching mechanism build in? How long does an average run take (I don't know if this one is possible to respond to)?<br>
<br>
- When a class implements a finalizer and the GC detects that the class is no longer referenced the finalizer is called and the class is put in a separate list and removed in the next run. What were the decissions to build that in this way? Why not clean the
 immediately after all other classes have been removed - why wait for the next run?<br>
</div>
</blockquote>
<br></p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/73c3d3c3ddcf49838c4a9dec007ff488#73c3d3c3ddcf49838c4a9dec007ff488</link>
		<pubDate>Thu, 31 May 2007 20:45:44 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/73c3d3c3ddcf49838c4a9dec007ff488#73c3d3c3ddcf49838c4a9dec007ff488</guid>
		<dc:creator>SecretSoftware</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/SecretSoftware/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p>my friend (who is to lazy to signup) asks<br>
<br>
&quot;
<dir>
<b><font color="#006600" size="2">
<p>All this discussion is about the collection of unused objects regarding the GC. I'd like to hear about how the memory management and object referencing system knows when an object is garbage and a candidate for collection.</p>
</dir>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Not just stuff about the collection process.&quot;</font></b><br>
<br>
perhaps you could ask something like that.<br>
<br>
*edit*</p></p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/962ec2bb3bda4098b7509dec007ff4b4#962ec2bb3bda4098b7509dec007ff4b4</link>
		<pubDate>Thu, 31 May 2007 23:21:38 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/962ec2bb3bda4098b7509dec007ff4b4#962ec2bb3bda4098b7509dec007ff4b4</guid>
		<dc:creator>Jaz</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/Jaz/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p>What's the best practice re: the GC for a performance-sensitive app like a 3D XNA game?</p>
<p></p>
<blockquote>
<div class="quoteAuthor">Littleguru wrote:</div>
<div class="quoteBody"><em>- Why isn't it possible to force the GC to do a collect. I mean GC.Collect() just signalizes that a collect is required, but the GC could decide to do not. Why has this been implemented in that way?</div>
</blockquote>
<br>
<br>
If this is indeed true, can't we have a GC.Collect(bool meanIt); ?</em>
<p></p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/995c802f1c8346b494df9dec007ff4df#995c802f1c8346b494df9dec007ff4df</link>
		<pubDate>Sun, 03 Jun 2007 23:27:36 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/995c802f1c8346b494df9dec007ff4df#995c802f1c8346b494df9dec007ff4df</guid>
		<dc:creator>Minh</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/Minh/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p><blockquote>
<div class="quoteAuthor">Minh wrote:</div>
<div class="quoteBody">&#65279;
<p></p>
<blockquote>
<table class="quoteTable">
<tbody>
<tr>
<td valign="top" width="10"><img src="/Themes/AlmostGlass/images/icon-quote.gif"></td>
<td class="txt3"><strong>Littleguru wrote:</strong>
<hr size="1">
<i><em>- Why isn't it possible to force the GC to do a collect. I mean GC.Collect() just signalizes that a collect is required, but the GC could decide to do not. Why has this been implemented in that way?</i></em></td>
</tr>
</tbody>
</table>
</blockquote>
<br>
<br>
If this is indeed true, can't we have a GC.Collect(bool meanIt); ?
<p></p>
</div>
</blockquote>
<br>
Probably because the GC knows more about current memory than the developer does 99% of the time.&nbsp; Forcing a GC when there are only a few dozen objects that need cleaning up is a bad idea.&nbsp; GC collection is a high overhead operation and calling it arbitrarily
 is bad practice nearly all of the time.</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/4a64b1470cc74019bce39dec007ff50b#4a64b1470cc74019bce39dec007ff50b</link>
		<pubDate>Wed, 06 Jun 2007 00:32:02 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/4a64b1470cc74019bce39dec007ff50b#4a64b1470cc74019bce39dec007ff50b</guid>
		<dc:creator>DoomBringer</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/DoomBringer/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p><blockquote>
<div class="quoteAuthor">DoomBringer wrote:</div>
<div class="quoteBody">&#65279;
<blockquote>
<table class="quoteTable">
<tbody>
<tr>
<td valign="top" width="10"><img src="/Themes/AlmostGlass/images/icon-quote.gif"></td>
<td class="txt3"><strong>Minh wrote:</strong>
<hr size="1">
<i>&#65279; </i>
<p></p>
<blockquote>
<table class="quoteTable">
<tbody>
<tr>
<td valign="top" width="10"><img src="/Themes/AlmostGlass/images/icon-quote.gif"></td>
<td class="txt3"><strong>Littleguru wrote:</strong>
<hr size="1">
<i><em>- Why isn't it possible to force the GC to do a collect. I mean GC.Collect() just signalizes that a collect is required, but the GC could decide to do not. Why has this been implemented in that way?</em></i></td>
</tr>
</tbody>
</table>
</blockquote>
<i><br>
<br>
If this is indeed true, can't we have a GC.Collect(bool meanIt); ? </i>
<p></p>
</td>
</tr>
</tbody>
</table>
</blockquote>
<br>
Probably because the GC knows more about current memory than the developer does 99% of the time.&nbsp; Forcing a GC when there are only a few dozen objects that need cleaning up is a bad idea.&nbsp; GC collection is a high overhead operation and calling it arbitrarily
 is bad practice nearly all of the time.</div>
</blockquote>
<br>
I don't agree. The end-result for a GC.Collect is ALWAYS a less fragmented memory space. So there must be a penalty if they don't want us to do this all the time.<br>
<br>
I'm guessing that penalty is the runtime becomes unresponsive for a while. In a game, you'd do anything not to have the GC runs its Collect routine in the middle of a game, and if you could, you should minimize that chance when it's OK to run at a lower framerate,
 say, the user is shopping for a new sword with his loot.<br>
<br>
Now, the crazy desktop app programmer who thinks he knows better by running GC.Collect everytime the user click on a button will be punished by having his app run like crap --- but at least that's a positive feedback for him to remove that GC.Collect.<br>
<br>
If you can't deterministically run GC.Collect() as a game programmer, you're punished by a run-time that think it knows better.<br></p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/eef471f09b8640d3842d9dec007ff566#eef471f09b8640d3842d9dec007ff566</link>
		<pubDate>Wed, 06 Jun 2007 03:51:54 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/eef471f09b8640d3842d9dec007ff566#eef471f09b8640d3842d9dec007ff566</guid>
		<dc:creator>Minh</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/Minh/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p><blockquote>
<div class="quoteAuthor">Minh wrote:</div>
<div class="quoteBody">&#65279;
<blockquote>
<table class="quoteTable">
<tbody>
<tr>
<td valign="top" width="10"><img src="/Themes/AlmostGlass/images/icon-quote.gif"></td>
<td class="txt3"><strong>DoomBringer wrote:</strong>
<hr size="1">
<i>&#65279;
<blockquote>
<table class="quoteTable">
<tbody>
<tr>
<td valign="top" width="10"><img src="/Themes/AlmostGlass/images/icon-quote.gif"></td>
<td class="txt3"><strong>Minh wrote:</strong>
<hr size="1">
<i>&#65279; </i>
<p></p>
<blockquote>
<table class="quoteTable">
<tbody>
<tr>
<td valign="top" width="10"><img src="/Themes/AlmostGlass/images/icon-quote.gif"></td>
<td class="txt3"><strong>Littleguru wrote:</strong>
<hr size="1">
<i><em>- Why isn't it possible to force the GC to do a collect. I mean GC.Collect() just signalizes that a collect is required, but the GC could decide to do not. Why has this been implemented in that way?</em></i></td>
</tr>
</tbody>
</table>
</blockquote>
<i><br>
<br>
If this is indeed true, can't we have a GC.Collect(bool meanIt); ? </i>
<p></p>
</td>
</tr>
</tbody>
</table>
</blockquote>
<br>
Probably because the GC knows more about current memory than the developer does 99% of the time.&nbsp; Forcing a GC when there are only a few dozen objects that need cleaning up is a bad idea.&nbsp; GC collection is a high overhead operation and calling it arbitrarily
 is bad practice nearly all of the time.</i></td>
</tr>
</tbody>
</table>
</blockquote>
<br>
I don't agree. The end-result for a GC.Collect is ALWAYS a less fragmented memory space. So there must be a penalty if they don't want us to do this all the time.<br>
<br>
I'm guessing that penalty is the runtime becomes unresponsive for a while. In a game, you'd do anything not to have the GC runs its Collect routine in the middle of a game, and if you could, you should minimize that chance when it's OK to run at a lower framerate,
 say, the user is shopping for a new sword with his loot.<br>
<br>
Now, the crazy desktop app programmer who thinks he knows better by running GC.Collect everytime the user click on a button will be punished by having his app run like crap --- but at least that's a positive feedback for him to remove that GC.Collect.<br>
<br>
If you can't deterministically run GC.Collect() as a game programmer, you're punished by a run-time that think it knows better.<br>
</div>
</blockquote>
<br>
It will always be less fragmented, yes,&nbsp;(except the very edge case of course) but the CPU time required for a full GC round is pretty significant.&nbsp; Moreover, with how much memory most systems have these days, your app might not even get any benefit in the long
 run: if I compact memory after allocating and dropping only a few dozen megabytes, well, that isn't all that great, since you've got hundreds more usually.&nbsp; (The story on the mobile side is different, however, since there is less memory.&nbsp; I don't know the
 mobile stuff as well really.)<br>
<br>
I'm thinking the best time for a GC is after you've blown through a lot of temporary objects, and are moving on to another very large round of allocations.&nbsp; It probably hurts more to get interrupted during the middle of your allocaiton phase, instead of before
 any at all.&nbsp; I'm talking about a large amount of data here too, something that you know is going to eat up a lot of RAM (several dozen or more megs).&nbsp; The average &quot;Oh Look A WinForm&quot; app isn't going to use all that much.<br>
<br>
I don't know how games would deal with it, but I would guess you could build a strategy to deal with it.&nbsp; I'm thinking that the majority of item creations are going to be during load sequences, so having a GC run in there wouldn't be so bad.<br>
<br>
Adding a boolean flag to indicate &quot;ya, srsly&quot; to the GC is kind of silly.&nbsp; No developer would ever use false, because they'd all think that they knew what they were doing.<br>
<br>
Finally, I just think that if somebody is writing an application that needs ultra-fine-grained control over memory control and demands high performance, then it probably needs to be written in native code.&nbsp; A business app that pops up a WinForm and queries
 a few databases isn't going to need to have millisecond precision, after all, but Gears of War will.</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/542a71bd0ae84c02942c9dec007ff59e#542a71bd0ae84c02942c9dec007ff59e</link>
		<pubDate>Wed, 06 Jun 2007 06:34:12 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/542a71bd0ae84c02942c9dec007ff59e#542a71bd0ae84c02942c9dec007ff59e</guid>
		<dc:creator>DoomBringer</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/DoomBringer/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p><blockquote>
<div class="quoteAuthor">Minh wrote:</div>
<div class="quoteBody">&#65279;<br>
I don't agree. The end-result for a GC.Collect is ALWAYS a less fragmented memory space. So there must be a penalty if they don't want us to do this all the time.<br>
<br>
If you can't deterministically run GC.Collect() as a game programmer, you're punished by a run-time that think it knows better.<br>
</div>
</blockquote>
<br>
<br>
The penalty is that things would get pushed into older generations much earlier than they should and consequently are much more like to live longer and hog memory unnecessarily.<br>
<br>
Games programming requires a slight shift in mindset. You shouldn't ever get punished by the GC because you shouldn't really be doing any allocations during the critical path. It's all about reserving resources in advance and then reusing them efficiently.</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/6dda4c4f0ad04117aca49dec007ff5ca#6dda4c4f0ad04117aca49dec007ff5ca</link>
		<pubDate>Wed, 06 Jun 2007 07:47:25 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/6dda4c4f0ad04117aca49dec007ff5ca#6dda4c4f0ad04117aca49dec007ff5ca</guid>
		<dc:creator>AndyC</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/AndyC/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p>&nbsp;&nbsp;&nbsp;Is it possible to build the weak event paradigm directly into CLR so that we ain't need to rely on some out of band techniques to tackle the lifetime management issue related to CLR events?<br>
<br>
Sheva</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/664fbd8f8b2843a690439dec007ff536#664fbd8f8b2843a690439dec007ff536</link>
		<pubDate>Wed, 06 Jun 2007 07:49:23 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/664fbd8f8b2843a690439dec007ff536#664fbd8f8b2843a690439dec007ff536</guid>
		<dc:creator>Zhou Yong</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/footballism/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p><blockquote>
<div class="quoteAuthor">DoomBringer wrote:</div>
<div class="quoteBody">&#65279;<br>
I don't know how games would deal with it, but I would guess you could build a strategy to deal with it.&nbsp; I'm thinking that the majority of item creations are going to be during load sequences, so having a GC run in there wouldn't be so bad.<br>
</div>
</blockquote>
<br>
Which spawn another question for me. So while a true GC.Collect() is under way, does the entire runtime stop? Are all objects unavailable to the app? What's the refresh scenario in this situation?<br>
<br>
<blockquote>
<div class="quoteAuthor">DoomBringer wrote:</div>
<div class="quoteBody">&#65279;<br>
Adding a boolean flag to indicate &quot;ya, srsly&quot; to the GC is kind of silly.&nbsp; No developer would ever use false, because they'd all think that they knew what they were doing.</div>
</blockquote>
<br>
It's not silly. Of course all the devs would pass in true, but in my case it'd be appropriate <img src='http://ecn.channel9.msdn.com/o9/content/images/emoticons/emotion-5.gif' alt='Wink' /><br>
<br>
<blockquote>
<div class="quoteAuthor">DoomBringer wrote:</div>
<div class="quoteBody">&#65279;<br>
Finally, I just think that if somebody is writing an application that needs ultra-fine-grained control over memory control and demands high performance, then it probably needs to be written in native code.&nbsp; A business app that pops up a WinForm and queries
 a few databases isn't going to need to have millisecond precision, after all, but Gears of War will.</div>
</blockquote>
<br>
Well, MS is positioning XNA as a viable Xbox Live Arcade framework. It's not Gears of War, but the last thing you want to see a game sputter during mid-play.<br>
<br>
Well, that's another question:<br>
<br>
How's the GC on the Xbox different than the PC one?<br></p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/06a748ab003b49e8aad19dec007ff5f9#06a748ab003b49e8aad19dec007ff5f9</link>
		<pubDate>Wed, 06 Jun 2007 14:35:26 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/06a748ab003b49e8aad19dec007ff5f9#06a748ab003b49e8aad19dec007ff5f9</guid>
		<dc:creator>Minh</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/Minh/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p><blockquote>
<div class="quoteAuthor">AndyC wrote:</div>
<div class="quoteBody">&#65279;<br>
Games programming requires a slight shift in mindset. You shouldn't ever get punished by the GC because you shouldn't really be doing any allocations during the critical path. It's all about reserving resources in advance and then reusing them efficiently.</div>
</blockquote>
I agree. But take this scenario. During a level load, I allocate all my objects. Fine. Played the level. Time to load another level. What I would like to do is to &quot;deallocate&quot; the previous level. Do a GC.Collect(true);. Then load the new level.<br>
<br>
I realize that I can unreference the previous level, load the new level, and if there was memory pressure during the new load, a Collect will be done. But I don't know what other factors can create a memory pressure during gameplay.<br></p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/3c175a3a7ca947e7b7679dec007ff628#3c175a3a7ca947e7b7679dec007ff628</link>
		<pubDate>Wed, 06 Jun 2007 14:40:26 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/3c175a3a7ca947e7b7679dec007ff628#3c175a3a7ca947e7b7679dec007ff628</guid>
		<dc:creator>Minh</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/Minh/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p><blockquote>
<div class="quoteAuthor">Minh wrote:</div>
<div class="quoteBody">&#65279;
<blockquote>
<table class="quoteTable">
<tbody>
<tr>
<td valign="top" width="10"><img src="/Themes/AlmostGlass/images/icon-quote.gif"></td>
<td class="txt3"><strong>DoomBringer wrote:</strong>
<hr size="1">
<i>&#65279;<br>
I don't know how games would deal with it, but I would guess you could build a strategy to deal with it.&nbsp; I'm thinking that the majority of item creations are going to be during load sequences, so having a GC run in there wouldn't be so bad.<br>
</i></td>
</tr>
</tbody>
</table>
</blockquote>
<br>
Which spawn another question for me. So while a true GC.Collect() is under way, does the entire runtime stop? Are all objects unavailable to the app? What's the refresh scenario in this situation?<br>
<br>
<blockquote>
<table class="quoteTable">
<tbody>
<tr>
<td valign="top" width="10"><img src="/Themes/AlmostGlass/images/icon-quote.gif"></td>
<td class="txt3"><strong>DoomBringer wrote:</strong>
<hr size="1">
<i>&#65279;<br>
Adding a boolean flag to indicate &quot;ya, srsly&quot; to the GC is kind of silly.&nbsp; No developer would ever use false, because they'd all think that they knew what they were doing.</i></td>
</tr>
</tbody>
</table>
</blockquote>
<br>
It's not silly. Of course all the devs would pass in true, but in my case it'd be appropriate
<img src="/emoticons/emotion-5.gif" border="0"><br>
<br>
<blockquote>
<table class="quoteTable">
<tbody>
<tr>
<td valign="top" width="10"><img src="/Themes/AlmostGlass/images/icon-quote.gif"></td>
<td class="txt3"><strong>DoomBringer wrote:</strong>
<hr size="1">
<i>&#65279;<br>
Finally, I just think that if somebody is writing an application that needs ultra-fine-grained control over memory control and demands high performance, then it probably needs to be written in native code.&nbsp; A business app that pops up a WinForm and queries
 a few databases isn't going to need to have millisecond precision, after all, but Gears of War will.</i></td>
</tr>
</tbody>
</table>
</blockquote>
<br>
Well, MS is positioning XNA as a viable Xbox Live Arcade framework. It's not Gears of War, but the last thing you want to see a game sputter during mid-play.<br>
<br>
Well, that's another question:<br>
<br>
How's the GC on the Xbox different than the PC one?<br>
</div>
</blockquote>
<br>
I'm not sure.&nbsp; The runtime might have to stop a particular thread while things are being cleaned up for that thread, but these are good questions.&nbsp;</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/9bc98be62c6d409fb44c9dec007ff65a#9bc98be62c6d409fb44c9dec007ff65a</link>
		<pubDate>Wed, 06 Jun 2007 22:34:48 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/9bc98be62c6d409fb44c9dec007ff65a#9bc98be62c6d409fb44c9dec007ff65a</guid>
		<dc:creator>DoomBringer</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/DoomBringer/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p>Great questions. We'll get some answers from the person who knows best <img src='http://ecn.channel9.msdn.com/o9/content/images/emoticons/emotion-5.gif' alt='Wink' /></p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/670299b49e32453fa1de9dec007ff683#670299b49e32453fa1de9dec007ff683</link>
		<pubDate>Thu, 07 Jun 2007 00:05:07 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/670299b49e32453fa1de9dec007ff683#670299b49e32453fa1de9dec007ff683</guid>
		<dc:creator>Charles</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/Charles/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p>whats next (CLR-GC)?? <br></p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/c21b1eb058884b92bbab9dec007ff6ad#c21b1eb058884b92bbab9dec007ff6ad</link>
		<pubDate>Thu, 07 Jun 2007 21:20:35 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/c21b1eb058884b92bbab9dec007ff6ad#c21b1eb058884b92bbab9dec007ff6ad</guid>
		<dc:creator>Ion Todirel</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/Ion Todirel/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p><blockquote>
<div class="quoteAuthor">Siyavash wrote:</div>
<div class="quoteBody">&#65279;hm... I was bored.... so I went to page &quot;1392&quot; and dug up this thread, just for fun. I'm probably the first one doing such a useless thing here.<br>
<br>
<img src="/emoticons/emotion-4.gif" border="0"><img src="/emoticons/emotion-10.gif" border="0"><img src="/emoticons/emotion-10.gif" border="0"><img src="/emoticons/emotion-10.gif" border="0"><img src="/emoticons/emotion-13.gif" border="0"><img src="/emoticons/emotion-13.gif" border="0"><img src="/emoticons/emotion-13.gif" border="0"></div>
</blockquote>
<br>
Just stop bloody necroing. Its SO not cool.</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/43a996a2c31f4ec28acd9dec007ff6d8#43a996a2c31f4ec28acd9dec007ff6d8</link>
		<pubDate>Sun, 28 Oct 2007 13:52:30 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/43a996a2c31f4ec28acd9dec007ff6d8#43a996a2c31f4ec28acd9dec007ff6d8</guid>
		<dc:creator>Chadk</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/Chadk/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p>I did notice the other day that this thread and one other that were that had fairly recent last post dates were on the very last page under heaps of older threads (last post date 2004 threads).<br>
<br>
Any reason?<br></p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/1d2b59f34124411090c89dec007ff702#1d2b59f34124411090c89dec007ff702</link>
		<pubDate>Sun, 28 Oct 2007 15:22:26 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/1d2b59f34124411090c89dec007ff702#1d2b59f34124411090c89dec007ff702</guid>
		<dc:creator>GoddersUK</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/GoddersUK/Discussions/RSS</wfw:commentRss>
	</item>
	<item>
		<title>Coffeehouse - Patrick Dussud interview next week: Questions?</title>
		<description><![CDATA[<p><blockquote>
<div class="quoteAuthor">SecretSoftware wrote:</div>
<div class="quoteBody">&#65279;<br>
Can a .NET application&nbsp;have a true memory leak as in the C&#43;&#43; sense where we allocate a chunk of memory&nbsp;and throw away the handle/pointer to it?<br>
</div>
</blockquote>
<br>
<br>
Hopefully not in safe code, but there&nbsp;is unsafe.<br>
<br>
<blockquote>
<div class="quoteAuthor">SecretSoftware wrote:</div>
<div class="quoteBody">&#65279;<br>
How does Multi-Core processors improve performance of GC<font color="#000000"><b></b></font> Operations? Can parallelism benifit things in GC<b></b>? [GC Threads].<br>
</div>
</blockquote>
<br>
<br>
I find this fascinating as well. I seem to recall Bertrand Meyer (Eiffel)&nbsp;contemplating a GC &quot;processor&quot;.<br>
<br>
...Bah, moot thread anyway...</p>]]></description>
		<link>http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/800c9435133d46e286559dec007ff72f#800c9435133d46e286559dec007ff72f</link>
		<pubDate>Sun, 28 Oct 2007 17:21:27 GMT</pubDate>
		<guid isPermaLink="false">http://channel9.msdn.com/Forums/Coffeehouse/255081-Patrick-Dussud-interview-next-week-Questions/800c9435133d46e286559dec007ff72f#800c9435133d46e286559dec007ff72f</guid>
		<dc:creator>Bent Rasmussen</dc:creator>
		<slash:comments>24</slash:comments>
		<wfw:commentRss>http://channel9.msdn.com/Niners/esoteric/Discussions/RSS</wfw:commentRss>
	</item>
</channel>
</rss>