JetBrains dotTrace Profiler and Dual Core CPU

We need to do some profiling on our project, and I decided to evaluate JetBrains dotTrace Profiler 3.1. First of all, I have tried to profile the sample application included with the tool, and got really surprised when I saw the times reported – they were “randomly distributed” in the plus-minus billions of milliseconds range :). I couldn’t believe it! Looked for a solution on Google, but first few pages of the search results proved to be totally useless.

Fortunetely, I got “enlightment” at this point – I recalled that I had problems with WPF animations on my dual core AMD Athlon64 x2 processors because of system timers – they were not in sync between cores, and GetPerformanceCounter API was returning “floating” numbers instead of non-decreasing sequence, thus causing “jumpy” animations. The solution then was to install AMD Dual-Core Optimizer (its description talks about gaming, RDTSC, etc., so it is not necessarily obvious that the thing can help with WPF :).

I went and downloaded and installed the tool again, and voilaz – nice times in the profiler! :) Now, the problem is, that I am absolutely sure that I have already installed this tool few months ago when I hit the WPF problem. So, how could it be that the tool was not working, and I had to install it again? Honestly, I don’t know… Most likely, some new drivers or system updates have disabled or otherwise damaged the tool. Which brings me to the (rhetoric?) question: how can “normal” people use today’s computers (and technologies in general) with all this complexity?


Stanford Engineering Everywhere Courses

The Stanford Engineering Everywhere has launched a series of free online computer science and electrical engineering courses (10 available so far). The courses span an introduction to computer science and an introduction to artificial intelligence and robotics, among other topics, and offer anytime and anywhere access to complete lecture videos via streaming or downloaded media, as well as full course materials including syllabi, handouts, homework, and exams.

More C++ Idioms

More C++ Idioms is a Wikibook aimed toward anyone with an intermediate level of knowledge in C++ and supported language paradigms. The goal there is to first build an exhaustive catalog of modern C++ idioms, and later evolve it into an idiom language, just like a pattern language.

The thing has been started by the author of C++ Truths blog. The blog is interesting by itself, as it has really many interesting articles on advanced C++ topics. was started recently by Joel Spolsky (no intro needed, I guess), and Jeff Atwood, the author of the Coding Horror blog. It is a programmer Q&A site that offers programmers the opportunity to ask questions and receive answers from the programming community for free, and intends to become the right source of answers for any programming question. What I have seen so far looked interesting and promising.

More C++ Resources

Michael D. Crawford’s GoingWare’s Bag of Programming Tricks contains wealth of super-interesting and useful information about many things, including advanced C++ topics. Especially I would mention Sermon at the Soup Kitchen (On C++ Software Quality and Institutional Resistance to Change), Pointers, References and Values (Passing Parameters, Returning Results, and Storing Member Variables with Musings on Good C++ Style), On Refactoring C++ Code (Properly managing memory returned by transcode() in the Xerces XML Library: from memory leak to clean, leak-free exception safety), and Pointers to C++ Member Functions (A tutorial on a useful yet poorly understood language feature, useful as a cache or to enable a different sort of polymorphism).

Then, there are tens of extremely interesting articles (despite older) about advanced C++ topics on Articles by Angelika Langer & Klaus Kreft site. Areas covered include STL, Standard Library, Core C++, and IOStreams.

Microsoft RTC Client SDK 1.3 Under Vista

We use Microsoft RTC Client SDK 1.3 in our application to provide SIP telephony. Vista is not our priority, but, as all laptops and PCs nowadays come preloaded with Vista rather than XP, some time ago we decided to try our software on Vista. We’ve got everything working, except the phone – it was complaining about the RTCClient COM component. I wasted about half a day trying to “please” Vista to get RTC client running on it – checked forums, did all mumbo-jumbo things people claimed helped them – all in vain. In the end we simply abandoned the idea…

Today I decided to try it once more. And, guess what! Got it working in 10 minutes! :) All thanks to the post on MSDN Forum and then the corresponding blog post (mirror is here) by Laurent Etiemble.

The thing worked like a charm! Unfortunately, I cannot confirm if registering DLLs is a needed step – I do not have Vista near me, so I have made a script that my colleague at remote location tried on his Vista laptop and, to save time and reduce the “human-error” possibility/hassle, I included the registration part (regsvr32 for all DLLs) just in case.