Posted by on in Blogs
Spot the deadlock This is the final full day I'll be here in Kona, Hawaii for the ANSI/ISO C++ standards meeting and they're just going through some of the minor issues, or actually "bugs" in the standard, I've been playing with the thread pool class from my post about thread pools. I included a small project to demonstrate the concept. However, in working with it, I found a subtle deadlock condition. Can you spot it? I'll give you a hint: SendMessage. I think this highlights the complexity that can creep in...

Posted by on in Blogs
ANSI/ISO C++ meeting Day 4 Shameless namedrop... sitting across the table from Herb Sutter(from MS) and Bjarne Stroustrup (from AT&T labs) in the Evolution/Concurrency Working group discussing http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2007/n2407.html.  Just to make it clear to the Delphi and C++Builder folks... we've had this for many years in the form of packages.  It's good that the standards bodies are getting on board with this concept.  Of course there are many issues with defining a stand...
Tags: CodeGear

Posted by on in Blogs
ANSI/ISO C++ meeting Day 3 http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2007/n2320.html - Went over this paper some more and rehashed the issue surrounding whether or not the thread object should detach or join the underlying OS thread.  Join and detach are POSIX thread notions and roughly correspond to Windows WaitForSingleObject(<thread handle>) and CloseHandle(<thread handle>).  Looks like their going with the detach rather than the join, mainly because they had no known prior art where a th...
Tags: CodeGear

Posted by on in Blogs
ANSI/ISO C++ meeting Day 2 OK, it is actually getting somewhat interesting.  Aside from the myriad of straw-polls, and various other procedural items, the technical discussions have some interesting bits.  We're just finished discussing atomics per this paper: http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2007/n2393.html.  It was actually moderated by one of the authors, Lawrence. For the Delphi folks on the x86 architecture, it is generally assumed that most memory operations are sequentially consiste...
Tags: CodeGear

Posted by on in Blogs
ANSI/ISO C++ meeting Day 1 Two words.  Boring.  Tedious.  This is simply where previous meeting minutes are approved by the voting members, the setting of the agenda for the week and discussions of specific mechanical meetings issues.  This includes when we're going to get WiFi in the meeting rooms.  I don't particularly care since I'm using my cell phone as a data channel :-).  If I can stay awake, I'll try to report some more...  Once we get into the breakouts where the actual concepts...
Tags: CodeGear
Who is going where to attend what!?  The ISO C++ committee meetings. Yep.  That's right.  This weekend I'll be boarding a plane to attend the ISO C++ meetings next week.  So why is the long-term Delphi guy going to attend something for C++?  Since I do things for CodeGear across the product lines in different capacities, it isn't too much of a stretch.  But there are a couple of really interesting things happening within the C++ community surrounding the standards that may be of interest on the Delphi side of things.  This is concurr...

Posted by on in Blogs
Super editor zoom - proof of concept. David Clegg mentions in this post a new super secret, "super zoom" feature.  First of all the reason this "feature" isn't on by default is that it was implemented as a very quick hack to more or less simply be a proof of concept for the team to play with.  As such, it is riddled with problems that if you start using it you may encounter.  It is actually somewhat ironic that this comes up now because for the last couple of days I've been looking at this feature and how it should actually be imple...

Posted by on in Blogs
Wading in the shallow end of the pool - Thread Pools A few weeks ago I was following with interest the announcement by Intel where they open-sourced their Thread Building Blocks (TBB) library. OK, so it is written in C++, makes heavy use of templates, and is generally like nearly every C++ library out there with heavy macro usage and umpteen levels of nest macros... Besides all of that, either I've gotten way better at reading and understanding C++ or these libraries are simplifying things, I was able to understand it quite well. This got me th...

Posted by on in Blogs
Cleggy joins the CodeGear team The ever-present David Clegg, has just joined the CodeGear crew working on the Developer Network! Welcome to the crucible (it does get a little "hot" around here at times! :-)  Be sure to stop by his blog and say, "Hi."...
A Generic Playground, an intro to parameterized types in Delphi for .NET The other day, I presented an introduction to the new parameterized types language feature in the latest release of Delphi for .NET at the Developer Days event. First of all, I'm not what one would call a consummate expert in the realm of language generics. In fact a lot of it just makes my head hurt. For real hard-core, on the edge, looks at the kinds of things you can do with generics, you should be looking here or here. I'm sure you may recognize those guys that run those blogs. So gi...

Check out more tips and tricks in this development video: