<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:media="http://search.yahoo.com/mrss/"
		>
<channel>
	<title>Comments on: Garbage, Part Two (Director&#8217;s Cut): oh, alright then</title>
	<atom:link href="http://bittermanandy.wordpress.com/2008/11/12/garbage-part-two-directors-cut-oh-alright-then/feed/" rel="self" type="application/rss+xml" />
	<link>http://bittermanandy.wordpress.com/2008/11/12/garbage-part-two-directors-cut-oh-alright-then/</link>
	<description>My game, XNA, game development, and the games industry</description>
	<lastBuildDate>Wed, 04 Nov 2009 09:04:39 +0000</lastBuildDate>
	<generator>http://wordpress.com/</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Nicholas</title>
		<link>http://bittermanandy.wordpress.com/2008/11/12/garbage-part-two-directors-cut-oh-alright-then/#comment-332</link>
		<dc:creator>Nicholas</dc:creator>
		<pubDate>Mon, 30 Mar 2009 19:36:07 +0000</pubDate>
		<guid isPermaLink="false">http://bittermanandy.wordpress.com/?p=101#comment-332</guid>
		<description>Still trying to come to grips with GC; this was very helpful, I now have some idea of what it actually is (as opposed to yet another acronym).</description>
		<content:encoded><![CDATA[<p>Still trying to come to grips with GC; this was very helpful, I now have some idea of what it actually is (as opposed to yet another acronym).</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: P4</title>
		<link>http://bittermanandy.wordpress.com/2008/11/12/garbage-part-two-directors-cut-oh-alright-then/#comment-305</link>
		<dc:creator>P4</dc:creator>
		<pubDate>Wed, 04 Feb 2009 10:22:41 +0000</pubDate>
		<guid isPermaLink="false">http://bittermanandy.wordpress.com/?p=101#comment-305</guid>
		<description>Once I read a good article about this, but unfortunately I cannot find it now.
Here is an other one :
http://msdn.microsoft.com/en-us/magazine/cc163791.aspx</description>
		<content:encoded><![CDATA[<p>Once I read a good article about this, but unfortunately I cannot find it now.<br />
Here is an other one :<br />
<a href="http://msdn.microsoft.com/en-us/magazine/cc163791.aspx" rel="nofollow">http://msdn.microsoft.com/en-us/magazine/cc163791.aspx</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: bittermanandy</title>
		<link>http://bittermanandy.wordpress.com/2008/11/12/garbage-part-two-directors-cut-oh-alright-then/#comment-304</link>
		<dc:creator>bittermanandy</dc:creator>
		<pubDate>Mon, 02 Feb 2009 12:23:39 +0000</pubDate>
		<guid isPermaLink="false">http://bittermanandy.wordpress.com/?p=101#comment-304</guid>
		<description>I believe - though I am fully prepared to be shown that I am wrong on this - that a reference in a 32-bit system is 8 bytes because, as well as a four-byte pointer, it also contains a four-byte type ID.

It&#039;s also possible I miscounted the number of strings that become garbage in my example - the important thing is that string operations generate lots of garbage in places that you may not expect...

Glad you liked the article anyway!</description>
		<content:encoded><![CDATA[<p>I believe &#8211; though I am fully prepared to be shown that I am wrong on this &#8211; that a reference in a 32-bit system is 8 bytes because, as well as a four-byte pointer, it also contains a four-byte type ID.</p>
<p>It&#8217;s also possible I miscounted the number of strings that become garbage in my example &#8211; the important thing is that string operations generate lots of garbage in places that you may not expect&#8230;</p>
<p>Glad you liked the article anyway!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: P4</title>
		<link>http://bittermanandy.wordpress.com/2008/11/12/garbage-part-two-directors-cut-oh-alright-then/#comment-303</link>
		<dc:creator>P4</dc:creator>
		<pubDate>Mon, 02 Feb 2009 09:29:51 +0000</pubDate>
		<guid isPermaLink="false">http://bittermanandy.wordpress.com/?p=101#comment-303</guid>
		<description>Great article !
BTW Isn&#039;t 32-bit system means that the size of a reference is 4 bytes and not 8.

Also I think the string concat example would only generate 3 garbage strings because of string interning.

To Filip:
structs can indeed implement interfaces, but if you use them through the IF then boxing (and possible garbage) will occur.</description>
		<content:encoded><![CDATA[<p>Great article !<br />
BTW Isn&#8217;t 32-bit system means that the size of a reference is 4 bytes and not 8.</p>
<p>Also I think the string concat example would only generate 3 garbage strings because of string interning.</p>
<p>To Filip:<br />
structs can indeed implement interfaces, but if you use them through the IF then boxing (and possible garbage) will occur.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: BlackSpiderWolf</title>
		<link>http://bittermanandy.wordpress.com/2008/11/12/garbage-part-two-directors-cut-oh-alright-then/#comment-254</link>
		<dc:creator>BlackSpiderWolf</dc:creator>
		<pubDate>Wed, 10 Dec 2008 13:02:17 +0000</pubDate>
		<guid isPermaLink="false">http://bittermanandy.wordpress.com/?p=101#comment-254</guid>
		<description>Great article, I finaly understand garbage collection :). I&#039;ve never been able to learn somthing without knowing the &quot;why and How&quot;, memorising rules puts to much trust in what somone else thinks is the right thing to do. so thank you for explaining it *Goes off to clean code*</description>
		<content:encoded><![CDATA[<p>Great article, I finaly understand garbage collection <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> . I&#8217;ve never been able to learn somthing without knowing the &#8220;why and How&#8221;, memorising rules puts to much trust in what somone else thinks is the right thing to do. so thank you for explaining it *Goes off to clean code*</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Filip</title>
		<link>http://bittermanandy.wordpress.com/2008/11/12/garbage-part-two-directors-cut-oh-alright-then/#comment-240</link>
		<dc:creator>Filip</dc:creator>
		<pubDate>Fri, 28 Nov 2008 23:27:07 +0000</pubDate>
		<guid isPermaLink="false">http://bittermanandy.wordpress.com/?p=101#comment-240</guid>
		<description>Thanks for another great post!

I have a couple of nit-picking comments:

&quot;Second, it’s not completely accurate to say that value types never generate garbage. They can, of course, contain reference members, in which case creating a new struct object can indirectly create a new class object, which generates garbage exactly as though you’d created the class object yourself. It’s fair to say that this is a slightly unusual thing to do (I’m not sure I can think of an example?) but it’s entirely legal and something to watch out for.&quot;

Well, you will never indirectly create a new class object by creating a struct that contains reference members, unless you use a specific non-default struct constructor that does that, and since you can&#039;t override the default struct constructor it will probably not happen unless you did want it to happen!

Also, it&#039;s not entirely correct to say that value types cannot inherit at all - structs can can implement interfaces :)


Waiting for a new post - keep it up! :)</description>
		<content:encoded><![CDATA[<p>Thanks for another great post!</p>
<p>I have a couple of nit-picking comments:</p>
<p>&#8220;Second, it’s not completely accurate to say that value types never generate garbage. They can, of course, contain reference members, in which case creating a new struct object can indirectly create a new class object, which generates garbage exactly as though you’d created the class object yourself. It’s fair to say that this is a slightly unusual thing to do (I’m not sure I can think of an example?) but it’s entirely legal and something to watch out for.&#8221;</p>
<p>Well, you will never indirectly create a new class object by creating a struct that contains reference members, unless you use a specific non-default struct constructor that does that, and since you can&#8217;t override the default struct constructor it will probably not happen unless you did want it to happen!</p>
<p>Also, it&#8217;s not entirely correct to say that value types cannot inherit at all &#8211; structs can can implement interfaces <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Waiting for a new post &#8211; keep it up! <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: XNA Team Blog : Creators Club Communiqu&#233; 09</title>
		<link>http://bittermanandy.wordpress.com/2008/11/12/garbage-part-two-directors-cut-oh-alright-then/#comment-225</link>
		<dc:creator>XNA Team Blog : Creators Club Communiqu&#233; 09</dc:creator>
		<pubDate>Wed, 19 Nov 2008 02:03:33 +0000</pubDate>
		<guid isPermaLink="false">http://bittermanandy.wordpress.com/?p=101#comment-225</guid>
		<description>[...] Bittermanandy served up a second course on dealing with garbage in C# as it relates to the XNA Framework. [...]</description>
		<content:encoded><![CDATA[<p>[...] Bittermanandy served up a second course on dealing with garbage in C# as it relates to the XNA Framework. [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Seth</title>
		<link>http://bittermanandy.wordpress.com/2008/11/12/garbage-part-two-directors-cut-oh-alright-then/#comment-224</link>
		<dc:creator>Seth</dc:creator>
		<pubDate>Tue, 18 Nov 2008 23:06:08 +0000</pubDate>
		<guid isPermaLink="false">http://bittermanandy.wordpress.com/?p=101#comment-224</guid>
		<description>Just to chime in -- I stumbled onto this article, which wasn&#039;t really what I was searching for, but a pleasant surprise instead. I&#039;m familiar with these issues from doing a lot of Java work, but it&#039;s nice to see some detailed treatment of value types (which we sadly lack). I also appreciated the link to CLR Profiler; the free tools are so much better than last time I was playing with .Net! (And anything&#039;s better than running your code in a loop and checking GC stats before and after... it works, but it&#039;s a hassle after a few passes.)</description>
		<content:encoded><![CDATA[<p>Just to chime in &#8212; I stumbled onto this article, which wasn&#8217;t really what I was searching for, but a pleasant surprise instead. I&#8217;m familiar with these issues from doing a lot of Java work, but it&#8217;s nice to see some detailed treatment of value types (which we sadly lack). I also appreciated the link to CLR Profiler; the free tools are so much better than last time I was playing with .Net! (And anything&#8217;s better than running your code in a loop and checking GC stats before and after&#8230; it works, but it&#8217;s a hassle after a few passes.)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: thinkinggamer</title>
		<link>http://bittermanandy.wordpress.com/2008/11/12/garbage-part-two-directors-cut-oh-alright-then/#comment-222</link>
		<dc:creator>thinkinggamer</dc:creator>
		<pubDate>Mon, 17 Nov 2008 10:30:24 +0000</pubDate>
		<guid isPermaLink="false">http://bittermanandy.wordpress.com/?p=101#comment-222</guid>
		<description>Good work Andy! I&#039;ve read of lot of C# texts, but you have a nice, easy to understand, way of explaining important issues.

Kostas</description>
		<content:encoded><![CDATA[<p>Good work Andy! I&#8217;ve read of lot of C# texts, but you have a nice, easy to understand, way of explaining important issues.</p>
<p>Kostas</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Kevin</title>
		<link>http://bittermanandy.wordpress.com/2008/11/12/garbage-part-two-directors-cut-oh-alright-then/#comment-214</link>
		<dc:creator>Kevin</dc:creator>
		<pubDate>Thu, 13 Nov 2008 16:13:03 +0000</pubDate>
		<guid isPermaLink="false">http://bittermanandy.wordpress.com/?p=101#comment-214</guid>
		<description>Andy, good follow up, very interesting.  I wasnt aware the GC havok that careless use of strings could wreak.  Keep up the excellent posts.</description>
		<content:encoded><![CDATA[<p>Andy, good follow up, very interesting.  I wasnt aware the GC havok that careless use of strings could wreak.  Keep up the excellent posts.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
