IT-Analysis.com
IT-Analysis.com Logo
Enterprise Other
Business Issues Channels Enterprise Services SME Technology
Module Header
Craig WentworthMWD Advisors
Craig Wentworth
16th April - Egnyte the blue touchpaper...
Louella FernandesLouella Fernandes
Louella Fernandes
11th April - Managed Print Services: Are SMBs Ready?
Louella FernandesLouella Fernandes
Louella Fernandes
11th April - The Managed Print Services (MPS) Opportunity for SMBs
Simon HollowayThe Holloway Angle
Simon Holloway
11th April - Intellinote - capture anything!
David NorfolkThe Norfolk Punt
David Norfolk
11th April - On the road to Morocco

Analysis

Is there new life in C++?
David Norfolk By: David Norfolk, Practice Leader - Development, Bloor Research
Published: 7th January 2013
Copyright Bloor Research © 2013
Logo for Bloor Research

There is no question that C++ is currently used in a lot of mission-critical applications (but, then, so is COBOL) and in a lot of commercial software packages. But is it a dying language, due for replacement by Java, C#, Python, Scala and so on? And, considering that a lot of COBOL and Fortran is still in active use, does this matter much anyway?

The answers are probably "no" and "no". Things are still happening in the C++ world. The latest Intel compilers, for example, are extremely good at optimising code for the latest Intel architectures and its Threading Building Blocks helps you exploit parallel programming on multicore architectures efficiently. Now there's a new C++ standard which addresses many of the issues associated with C++ programming. Even Bjarne Stroustrup says that C++11 feels like a new language here - read more in this interview.

Standard C++11 still lacks Java-style garbage collection, used to clean up allocated memory that is no longer needed (and I'm not sure that relying on programmers to do their own garbage collection is entirely safe), but it does include a state-of-the-art threading library. Many programmers don't like garbage collection, because of the propensity for basic Java to stop for a few seconds while garbage collecting, but that's an implementation issue and you can get modern high performance Javas with better-managed "deterministic" garbage collection facilities offering predictable latency (see, for example, Oracle JRockit). Read about the C++11 innovations here.

Embarcadero's new C++Builder XE3 compiler, which supports the new C++11 standards and allows VCL (Visual Component Library, a visual framework for building Windows applications originally developed by Borland) and FireMonkey (which is what Embarcadero calls its "modern, multi-platform, hardware accelerated GUI and application framework") to be moved onto 64bit platforms, is another sign that interest in C++ is still active. Embarcadero (or, rather, Borland, part of which it acquired in 2008) has a good record for providing productive developer tools and its new compiler promises "agile C++". In other words, developers can use Embarcadero extensions to make C++ up to 5x faster than traditional development, Embarcadero says, using rapid prototyping, PME (properties/methods/events) component-based programming, and visual development. Of course, that's hard to verify in the general case (and no improvement at all satisfies the "up to" 5 times promise) but if you are, or want to be, a C++ shop, it's probably worth investigating (the original Borland C++ Builder was pretty good).

Embarcadero's new compiler builds on clang, a front-end for the respected open-source LLVM compiler, which (it says) will address any advantage Intel compilers have in exploiting Intel's architectures And, usefully, Embarcadero promises industry-leading compliance with the C++ standards.

The key promise of C++Builder XE3, however, is that it will let you target multiple platforms with a single codebase and a single developer team. That sounds good to us, although it won't really come to fruition until its iOS and Android on ARM capabilities arrive. This is also a 64bit compiler, with good support for a Windows 8 look and feel interface, so it offers lots of options for legacy C++ Windows application modernisation (it supports (Windows XP, Windows Vista, Windows 7, and Windows 8). And support for Mac OS X and Retina Display (letting developers deliver a native user experience and automatic HiDPI display support in Mac applications) has to be a bonus. Despite the C++11 improvements, we suspect that native support for a wide range of popular desktop and mobile user environments will be what drives any actual C++ resurgence.

On balance, C++ probably wouldn't be our language of choice these days for general business systems, where something like Java (or Scala) will probably be more productive overall. But C++ is still the optimal choice for some applications and a perfectly adequate choice (if you have the right C++ skills) for many more; and we aren't in the business of building applications anyway. C++ certainly isn't anything like dead yet and, according to C++ guru Herb Sutter, now "computing feels young and fresh in a way that it hasn't felt for years, and that has only happened to this degree at two other times in its history" - although he's talking about the UI and mobile devices, which are what modern C++ has to support.

Advertisement



Published by: IT Analysis Communications Ltd.
T: +44 (0)190 888 0760 | F: +44 (0)190 888 0761
Email: