<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Performance implications of unmanaged array accesses</title><link>http://blogs.msdn.com/clrcodegeneration/archive/2008/02/08/performance-implications-of-unmanaged-array-accesses.aspx</link><description>I was recently shown the following code and asked why the loop calling SafeAccess executed significantly faster than the second loop calling UnsafeAccess : static int [] intarray = new int [ 5000 ]; static void SafeAccess(int a, int b) { int temp = intarray[a];</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>re: Performance implications of unmanaged array accesses</title><link>http://blogs.msdn.com/clrcodegeneration/archive/2008/02/08/performance-implications-of-unmanaged-array-accesses.aspx#7558353</link><pubDate>Sat, 09 Feb 2008 12:55:31 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:7558353</guid><dc:creator>jvangael</dc:creator><description>&lt;p&gt;Is there a good resource to learn when it would be appropriate to use unsafe accesses? I can imagine that if there were a loop in the unsafe method, and the problem were large enough, the range checking would incur a performance overhead?&lt;/p&gt;
&lt;p&gt;Any place or book I could check out to learn more?&lt;/p&gt;
&lt;p&gt;Jurgen&lt;/p&gt;
</description></item></channel></rss>