<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Performance on 7sharp9</title><link>https://7sharp9.github.io/tags/performance/</link><description>Recent content in Performance on 7sharp9</description><generator>Hugo -- gohugo.io</generator><language>en</language><managingEditor>7sharp9@mail.com (Dave Thomas)</managingEditor><webMaster>7sharp9@mail.com (Dave Thomas)</webMaster><copyright>© 2026 Dave Thomas</copyright><lastBuildDate>Sun, 29 May 2016 00:00:00 +0000</lastBuildDate><atom:link href="https://7sharp9.github.io/tags/performance/index.xml" rel="self" type="application/rss+xml"/><item><title>flame on</title><link>https://7sharp9.github.io/programming/2016-05-29-flame-on/</link><pubDate>Sun, 29 May 2016 00:00:00 +0000</pubDate><author>7sharp9@mail.com (Dave Thomas)</author><guid>https://7sharp9.github.io/programming/2016-05-29-flame-on/</guid><description>&lt;p&gt;A few weeks back I posted on Twitter that I was experimenting with flame graphs, In this post I will share how this was accomplished.&lt;/p&gt;</description></item><item><title>Black-Scholes Taste Test</title><link>https://7sharp9.github.io/programming/2012-03-10-black-scholes-taste-test/</link><pubDate>Sun, 11 Mar 2012 00:00:00 +0000</pubDate><author>7sharp9@mail.com (Dave Thomas)</author><guid>https://7sharp9.github.io/programming/2012-03-10-black-scholes-taste-test/</guid><description>&lt;p&gt;In this edition we are going to be doing a taste test, C# vs F#. Oh yeah, if you quickly glanced at the title you may&#10;have thought this was a recipe for black scones, as interesting and tasty as that may be, unfortunately its going&#10;to be finance related.&lt;/p&gt;</description></item><item><title>Fixing a hole...</title><link>https://7sharp9.github.io/programming/2011-12-11-fixing-a-hole/</link><pubDate>Sun, 11 Dec 2011 00:00:00 +0000</pubDate><author>7sharp9@mail.com (Dave Thomas)</author><guid>https://7sharp9.github.io/programming/2011-12-11-fixing-a-hole/</guid><description>&lt;p&gt;Due to popular demand&amp;hellip; well, I had a couple of requests anyway :-) Heres&#10;a post inspired by my recent encounters profiling some of the code in&#10;&lt;a href="https://github.com/fractureio/fracture" target="_blank" rel="noreferrer"&gt;Fracture-IO&lt;/a&gt;.  &lt;!-- more --&gt;I have recently been&#10;profiling the code in fracture to remove any so called low hanging fruits.&#10;During this time I also noticed an increase in memory allocation.  I&#10;remembered I had recently been experimenting in a branch using pipelets as a&#10;buffer between the send and receive stages in the Http Server, so I set up a&#10;simple test to see if pipelets were contributing to the memory allocation&#10;issues I was seeing.  Here&amp;rsquo;s the simple iteration test code I used for the&#10;memory profiling:&lt;/p&gt;</description></item><item><title> Agents and ObjectPools</title><link>https://7sharp9.github.io/programming/2011-06-05-agents-and-objectpools/</link><pubDate>Sun, 05 Jun 2011 00:00:00 +0000</pubDate><author>7sharp9@mail.com (Dave Thomas)</author><guid>https://7sharp9.github.io/programming/2011-06-05-agents-and-objectpools/</guid><description>&lt;p&gt;Everyone knows F# agents are cool right?  Well here&amp;rsquo;s yet another example of how versatile they can be&amp;hellip;&lt;/p&gt;&#10;&lt;p&gt;There was a series of posts last April by Stephen Toub from the &lt;a href="http://blogs.msdn.com/b/pfxteam/" target="_blank" rel="noreferrer"&gt;pfxteam&lt;/a&gt; at Microsoft.  I was reading&#10;through some of the posts again the other day and thought some of the ideas presented there would make interesting projects in F# to demonstrate the&#10;flexibility and succinctness of the language.  I thought the &lt;a href="http://blogs.msdn.com/b/pfxteam/archive/2010/04/13/9990427.aspx" target="_blank" rel="noreferrer"&gt;ObjectPool&lt;/a&gt;&#10;example would make an interesting project in F# using agents aka MailboxProcessors. An ObjectPool is basically a pool of objects that have been&#10;pre-created so that you can grab one and use it, and then place it back in the pool when you&amp;rsquo;re finished.  They are useful in situations where the cost of&#10;creating object from scratch is very high or you want to cut down on allocations in the garbage collector.&lt;!-- more --&gt;&lt;/p&gt;</description></item><item><title>Sockets and Bockets 4</title><link>https://7sharp9.github.io/programming/2011-01-28-sockets-and-bockets-part-4/</link><pubDate>Fri, 28 Jan 2011 00:00:00 +0000</pubDate><author>7sharp9@mail.com (Dave Thomas)</author><guid>https://7sharp9.github.io/programming/2011-01-28-sockets-and-bockets-part-4/</guid><description>&lt;h2 class="relative group"&gt;Welcome to part 4&#10; &lt;div id="welcome-to-part-4" class="anchor"&gt;&lt;/div&gt;&#10; &#10; &lt;span&#10; class="absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none"&gt;&#10; &lt;a class="text-primary-300 dark:text-neutral-700 !no-underline" href="#welcome-to-part-4" aria-label="Anchor"&gt;#&lt;/a&gt;&#10; &lt;/span&gt;&#10; &#10;&lt;/h2&gt;&#10;&lt;p&gt;If you were looking forward to some exciting new F# code this time your going&#10;to be disappointed, however if you are like me and like looking at graphs and&#10;stats and digging in deeper into the code then your going to enjoy this, lets&#10;get started&amp;hellip;&lt;!-- more --&gt;&lt;/p&gt;</description></item><item><title>Sockets and Bockets 3</title><link>https://7sharp9.github.io/programming/2011-01-20-sockets-and-bockets-part-3/</link><pubDate>Thu, 20 Jan 2011 00:00:00 +0000</pubDate><author>7sharp9@mail.com (Dave Thomas)</author><guid>https://7sharp9.github.io/programming/2011-01-20-sockets-and-bockets-part-3/</guid><description>&lt;h2 class="relative group"&gt;Welcome to part three!&#10; &lt;div id="welcome-to-part-three" class="anchor"&gt;&lt;/div&gt;&#10; &#10; &lt;span&#10; class="absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none"&gt;&#10; &lt;a class="text-primary-300 dark:text-neutral-700 !no-underline" href="#welcome-to-part-three" aria-label="Anchor"&gt;#&lt;/a&gt;&#10; &lt;/span&gt;&#10; &#10;&lt;/h2&gt;&#10;&lt;p&gt;As promised heres a description of the inner workings.  I&amp;rsquo;m sick to death of&#10;typing SocketAsyncEventArgs so from now on I will refer to it as SAEA.&lt;!-- more --&gt;&lt;/p&gt;</description></item><item><title>Sockets and Bockets 2</title><link>https://7sharp9.github.io/programming/2011-01-14-sockets-and-bockets-part-2/</link><pubDate>Fri, 14 Jan 2011 00:00:00 +0000</pubDate><author>7sharp9@mail.com (Dave Thomas)</author><guid>https://7sharp9.github.io/programming/2011-01-14-sockets-and-bockets-part-2/</guid><description>&lt;h3 class="relative group"&gt;Welcome to part two&#10; &lt;div id="welcome-to-part-two" class="anchor"&gt;&lt;/div&gt;&#10; &#10; &lt;span&#10; class="absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none"&gt;&#10; &lt;a class="text-primary-300 dark:text-neutral-700 !no-underline" href="#welcome-to-part-two" aria-label="Anchor"&gt;#&lt;/a&gt;&#10; &lt;/span&gt;&#10; &#10;&lt;/h3&gt;&#10;&lt;p&gt;Lets jump in at the deep end and take a look at some code&amp;hellip;&lt;/p&gt;&#10;&lt;p&gt;When you look at the method syntax for the xxxAsync methods you will notice&#10;they return a boolean value that indicates if the method completed&#10;synchronously, this means that you have to check the return value every time&#10;you use one of the methods and invoke the callback yourself if it completes&#10;synchronously.  In practice this hardly ever happens, and normally only on a&#10;send operation.  But as it is a possibility we will add module with a some&#10;extension methods in to help us out, this will make the code more readable and&#10;avoid unnecessary duplication.&lt;!-- more --&gt;&lt;/p&gt;</description></item><item><title>Sockets and Bockets 1</title><link>https://7sharp9.github.io/programming/2011-01-13-sockets-and-bockets-1/</link><pubDate>Thu, 13 Jan 2011 00:00:00 +0000</pubDate><author>7sharp9@mail.com (Dave Thomas)</author><guid>https://7sharp9.github.io/programming/2011-01-13-sockets-and-bockets-1/</guid><description>&lt;h3 class="relative group"&gt;Welcome to part 1&#10; &lt;div id="welcome-to-part-1" class="anchor"&gt;&lt;/div&gt;&#10; &#10; &lt;span&#10; class="absolute top-0 w-6 transition-opacity opacity-0 -start-6 not-prose group-hover:opacity-100 select-none"&gt;&#10; &lt;a class="text-primary-300 dark:text-neutral-700 !no-underline" href="#welcome-to-part-1" aria-label="Anchor"&gt;#&lt;/a&gt;&#10; &lt;/span&gt;&#10; &#10;&lt;/h3&gt;&#10;&lt;p&gt;A while back I read an interesting article by &lt;em&gt;Brian McNamara&lt;/em&gt; &lt;a href="http://lorgonblog.wordpress.com/2010/03/28/f-async-on-the-server-side/" target="_blank" rel="noreferrer"&gt;f-async-on-the-server-side&lt;/a&gt;&#10;which describes C# and F# versions of a simple asynchronous&#10;socket server, one of the driving forces behind the article was how F# can&#10;wrap the traditional asynchronous model with &lt;a href="http://msdn.microsoft.com/en-us/library/dd233250.aspx" target="_blank" rel="noreferrer"&gt;Asynchronous Workflows&lt;/a&gt;, this&#10;produces nice clean simple code compared to the C# version which uses lambda&#10;expressions, the code looks quite ugly in this style!  However thats not the&#10;end of the story, a lot of memory fragmentation can occur using the APM model&#10;when there is a high throughput, so I thought I would see if I could take this&#10;a step further&amp;hellip;&lt;!-- more --&gt;&lt;/p&gt;</description></item></channel></rss>