|By Jyoti Bansal||
|January 23, 2017 10:54 AM EST|
C++ is one of the most popular programming languages in the world. It’s very fast and used for many high-profile projects, including Google Chrome and Microsoft Office. C++ is a mid-level language that communicates close to the hardware layer while still being easier to program than low-level assembly languages. It offers a unique blend of ease of coding and high-speed hardware control. Let’s take a closer look at C++, how it originated, who uses it, and its advantages over other languages.
The Origins and History of C++
In 1972, Dennis Ritchie of Bell Labs created a language for Unix called C. By the late 1970s, C had become popular for developing operating systems. A number of variations on the original language were developed. In the late 1980s, ANSI Standard C was created.
In 1979, Denmark’s Bjarne Stroustrup modified C by adding classes. He made further refinements by implementing object-oriented features to create C++. He was trying to create a language like Scala, so it would be easy to program large software systems but also fast with low-level hardware control like BCPL. C++ gave him more advanced features than C offered while retaining its flexibility and efficiency. By the 1990s, C++ continued to grow and develop and it was often the first choice for operating systems like Windows, BeOS Haiku, and Syllable. It’s ideal for low-level development, robotic spacecraft, and telephone exchanges.
C++ is a language, development environment, and library in one, used for both object-oriented and procedural programming. It can be modified and extended depending on the goals of the programmer, and there are a number of versions of C++ today. They include Microsoft C++ (Microsoft Visual C++ 6.0); ANSI C++; C++ versions from companies such as Turbo, Symantec, Borland, and others; and platform-specific versions.
C++ uses standards written by an ISO standard committee. C++ is not an implementation itself, but has many variations developed by different organizations and companies. Some variations are open-source depending on the goals and guidelines of the originator — for example, both Clang and GNU are open-source implementations of C++.
The Advantages of C++
C++ is sometimes referred to as a “multi-paradigm” language because it can be used for procedural, object-oriented, or functional programming. It is known for its flexibility and extensibility. In a procedural language, modules communicate by writing and reading state located in shared data stores. It is loosely bound with very little shared code.
With a tightly bound object-oriented language, objects communicate by sending various messages to other objects. Object-oriented programming uses encapsulation, with both code and data acting as objects. It simplifies code using polymorphism, the process of deploying one interface and several entities. C++ code runs faster than most other languages. It is highly portable and is a popular choice for creating multi-platform, multi-device applications. It has a useful function library, allows function overloading and exception handling, and includes classes, data abstraction, polymorphism, encapsulation, and inheritance.
Used in a Variety of Fields
C++ is deployed for tasks that demand high performance, such as video editing and transcoding, high-end computer-aided design (CAD), image processing, games, telecommunications, and business. It is used by companies such as Reuters and Bloomberg for data feeds with low latency, by the military for onboard systems, by Google for Chrome and other apps, and by Microsoft for the Office Suite.
Major airlines use flight control systems written in C++. It is popular for game development — the Torque 3-D game engine, written in C++, is used to develop Xbox and iPhone games. Advanced medical equipment makers use C++, and defense contractors use it for mission-specific software APIs. Well-known tech companies and organizations using C++ include Evernote, LinkedIn, Microsoft, Opera, NASA, and Facebook. Evernote switched from .NET to C++ for more speed and better graphics. LinkedIn uses restclient-cpp, a client written in C++ used for making HTTP/REST requests. Facebook uses it for back end services and regularly modifies C++ standards for custom features.
In addition, Wall Street and the financial industry have long used C++ for trading high volumes at high-frequency levels — they like that it can be easily used for modeling and data simulations. Its popularity in finance can be partly attributed to the fact that it is a major investment to adapt to new technologies and C++ simplifies the digital transformation of creating applications that run on legacy systems. More importantly, more than 70 percent of trading is known as High Frequency Trading (HFT), where software programs can trade tens of thousands of transactions in mere seconds. C++ is favored over other languages in HFT environments because on Wall Street, speed equals millions of dollars of revenue and profits.
C++ vs. Other Languages
Programming languages offer different advantages depending on the goals of the project. At Google, for example, C++, Java, and Python dominate. Here’s how they compare:
Java: C++ compiles to bytecode at the system level, while Java compiles to Java Virtual Machine bytecode. As a result, there are many cross-platform libraries associated with C++ because different platforms have different compilers. Because Java Virtual Machine is essentially an abstraction layer, Java programs can be run on any device that supports Java. Java is memory safe, but C++ is not. Java has a disciplined system for detecting errors, whereas C++ has unchecked casts and relies on the developer for memory management. Java is a complete object-oriented language, while C++ only utilizes certain OOP elements. Java uses interfaces to provide multiplicity — C++ offers multiple class inheritance.
Python: Python differs from C++ in that C++ is a compiled language, while Python is a scripting language. Python’s types are much simpler, and it has a distinct lack of declarations. Types in C++ are bound to names, explicitly declared, and checked when compiled. C++ is a mid-level language that offers lots of power and subsequent complexity. Python is simple to code and understand, which leads to quicker development and easier troubleshooting.
Garbage collection was originally intended to be included in C++, but there were too many technical problems to integrate properly with the rest of the code. However, the lack of garbage collection is an example of the power C++ gives you to customize the language for your purposes — you can easily add garbage collections with smart pointers. Unlike some other programming languages that have garbage collection built in, C++ was developed with speed and efficient infrastructure as its primary goals. It offers many advantages over other languages, with the caveat that you must have a working understanding of low-level programming to get the most out of it.
Is C++ a Good Investment for the Future?
C++ remains a solid investment for the future because of its power, versatility, flexibility, and prevalence in a number of industry verticals. It is still one of the most popular languages for game development, and is a favorite of the scientific community and financial industry. Further, it is often used for creating device drivers, software-defined networking, operating systems, and embedded software.
Handling the Back End at Google
The Go-to Language on Wall Street
Part of the reason that C++ is popular on Wall Street, and for quantitative finance in general, is due to its historical presence in the industry. Many developers in the finance industry “grew up” on C++ in the early part of their careers, so it became ubiquitous. Many financial programmers are able to develop in C++, and there’s a plethora of resources and communities to support it. Further, there are extensive math and quantitative-oriented libraries available.
Beyond that, it offers superior performance compared to other solutions such as Java or .NET. In addition, popular C++ libraries such as Boost have made C++ simpler and faster. Also, C++ templates potentially make code easier to optimize than Java or C. There are useful packages such as Rcpp, which adds R functions to C++, and RInside, which adds the R interpreter using a C++ wrapper class.
A Favorite of Game Developers
For a long time, C++ was the only choice for creating high-performance programs such as games. As a result, it’s become a standard solution, with lots of investment in game engines and libraries.
Game developers like C++ because it provides lots of control over hardware. It offers a powerful blend of high-level ease of use, high speed, and low-level hardware access. It is highly deterministic, a quality that is not always true for languages that operate in virtual machines or garbage-collected languages. Many games used to be written in Assembler, because you needed to access the hardware directly to get the best performance. With today’s computers, C++ makes code development faster while still allowing plenty of control over the machine layer.
With a powerful language like C++, application performance management is critical. AppDynamics offers C/C++ application performance monitoring that identifies and resolves performance problems in dynamic and distributed environments. The SDK discovers application topology, allowing you to trace transactions from application behavior. It correlates your C++ and C apps with programs written in other languages such as PHP, Node.js, and Python, and it lets you monitor databases, web services, and other back-end functions.
C++ is a fast, reliable, powerful language with few peers in game development, quantitative finance, banking, military and defense, back end systems, and many other applications. It offers a unique blend of hardware control while still being easy to program. Because of these advantages, the future is bright for C++ as it continues to adapt and improve in today’s modern computing environment.
Learn more about our C++ performance monitoring solution today.
The post The Bedrock of the Software World: C++ Programming Language appeared first on Application Performance Monitoring Blog | AppDynamics.
Feb. 19, 2017 11:00 AM EST Reads: 1,521
Feb. 19, 2017 11:00 AM EST Reads: 2,877
Feb. 19, 2017 10:45 AM EST Reads: 7,621
Feb. 19, 2017 10:45 AM EST Reads: 764
Feb. 19, 2017 10:30 AM EST Reads: 6,511
Feb. 19, 2017 10:00 AM EST Reads: 851
Feb. 19, 2017 10:00 AM EST Reads: 5,684
Feb. 19, 2017 09:45 AM EST Reads: 1,141
Feb. 19, 2017 09:45 AM EST Reads: 728
Almost two-thirds of companies either have or soon will have IoT as the backbone of their business. Though, IoT is far more complex than most firms expected with a majority of IoT projects having failed. How can you not get trapped in the pitfalls? In his session at @ThingsExpo, Tony Shan, Chief IoTologist at Wipro, will introduce a holistic method of IoTification, which is the process of IoTifying the existing technology portfolios and business models to adopt and leverage IoT. He will delve in...
Feb. 19, 2017 09:15 AM EST Reads: 1,013
Feb. 19, 2017 09:15 AM EST Reads: 5,030
As cloud adoption continues to transform business, today's global enterprises are challenged with managing a growing amount of information living outside of the data center. The rapid adoption of IoT and increasingly mobile workforce are exacerbating the problem. Ensuring secure data sharing and efficient backup poses capacity and bandwidth considerations as well as policy and regulatory compliance issues.
Feb. 19, 2017 09:15 AM EST Reads: 1,561
Many private cloud projects were built to deliver self-service access to development and test resources. While those clouds delivered faster access to resources, they lacked visibility, control and security needed for production deployments. In their session at 18th Cloud Expo, Steve Anderson, Product Manager at BMC Software, and Rick Lefort, Principal Technical Marketing Consultant at BMC Software, discussed how a cloud designed for production operations not only helps accelerate developer inno...
Feb. 19, 2017 09:15 AM EST Reads: 1,493
SYS-CON Events announced today that Conference Guru has been named “Media Sponsor” of SYS-CON's 20th International Cloud Expo, which will take place on June 6–8, 2017, at the Javits Center in New York City, NY. A valuable conference experience generates new contacts, sales leads, potential strategic partners and potential investors; helps gather competitive intelligence and even provides inspiration for new products and services. Conference Guru works with conference organizers to pass great dea...
Feb. 19, 2017 07:45 AM EST Reads: 1,672
SYS-CON Events announced today that LeaseWeb USA, a cloud Infrastructure-as-a-Service (IaaS) provider, will exhibit at the 19th International Cloud Expo, which will take place on November 1–3, 2016, at the Santa Clara Convention Center in Santa Clara, CA. LeaseWeb is one of the world's largest hosting brands. The company helps customers define, develop and deploy IT infrastructure tailored to their exact business needs, by combining various kinds cloud solutions.
Feb. 19, 2017 07:30 AM EST Reads: 1,400