Dynamic Programming Languages on the Rise in Open Source

t one time or another, every software engineer makes the mistake of banking on a technology that becomes obsolete?leaving customers or users stuck in a dead-end. This scenario can make or break a company or product. Anyone who has worked in the tech industry for a while knows that it is very hard to predict what technologies will become obsolete.

Occasionally, however, a technological shift comes along that is so crystal clear that adopting the emerging technology is a no-brainer. One of those transformations is happening today: a slow, but steady, shift toward web architectures written in dynamic languages that rely on open source software.

For many years, static languages such as C, C++, and Java have been the bread and butter of software engineering. Even as use remains strong, these languages are losing ground, on a percentage basis, to dynamic programming languages such as JavaScript and PHP?languages commonly used in web applications.

Explanation of the Shift

One of the main reasons these newer languages are more attractive is their ease of use. With languages like JavaScript and PHP developers can write code much more quickly. Historically, people have always been attracted to languages that are easier to use: machine code gave way to assembly language, which yielded to procedural languages like C, COBOL and FORTRAN, which in turn were succeeded by object-oriented languages like C++ and Java.

On the downside, dynamic languages tend to be much less compact and efficient than their static counterparts, but hardware has typically reduced the impact of this flaw. As hardware costs and capability double every 18 months, software gets a free ride. Faster processors and denser memories continuously speed up the performance of legacy applications. Virtualization takes machine scalability to a whole new level. Cloud computing could push the trend even further. With plentiful hardware resources today, the programmer’s time has become the most precious resource. Companies are turning to the most productive programming languages. Scripting languages such as Ruby and PHP are often the fastest way to get an application deployed.

The Data Behind the Shift

An in-depth look at Black Duck Software’s KnowledgeBase reveals the truth behind these trends. The KnowledgeBase database consists of more than 220,000 open source projects with some 5.6 billion lines of code (considering only the latest and greatest releases). A few months ago, Black Duck ran language analysis on every source file in the database to find out which languages are used most frequently by open source projects.

Not surprisingly, open source developers chose C more often than any other language. However, for project releases that occurred in the past 12 months, C’s market share fell a small amount relative to other languages. This doesn’t necessarily mean that the amount of C being written is shrinking; it means that the use of C is growing more slowly than the use of other languages.

Programmers were turning to scripting languages such as JavaScript, PHP, and others. As a whole, static languages such as C, C++, and Java are giving way to these dynamic languages. Table 1 below offers an August 2009 snapshot of the Black Duck language analysis results.

Table 1. Market Share by Language for All Open Source Code, August 2009
Language All Projects ? Share (%) Trailing 12-Month Share (%) Trailing 12-Month Gain/Loss (%)
C 40.91 40.34 -0.6
C++ 14.02 13.43 -0.6
Java 10.95 10.29 -0.7
Shell 8.96 7.05 -1.9
JavaScript 5.55 7.6 2.1
PHP 4.86 5.19 0.3
Perl 3.2 2.43 -0.8
Python 2.73 2.63 -0.1
SQL 1.6 2.65 1.1
C# 1.24 1.32 0.1
Assembler 1.23 0.83 -0.4
Pascal 0.91 0.73 -0.2
Ruby 0.78 1.01 0.2
TCL 0.4 0.28 -0.1
Ada 0.39 0.22 -0.2
*Source: www.blackducksoftware.com/oss/projects#language
Author’s Note 1: The “All Projects ? Share” column shows the results for all open source projects in the KnowledgeBase. The “Trailing 12-Month Share” narrows the results to show only code that was published or released in the most recent 12-month period, reflecting recent trends in language choice by open source developers.

Author’s Note 2: Black Duck would not expect dramatic changes in these values over a 12 month time frame because each percentage point of share is about fifty million lines of code.

Open Source-Based Languages: The New De Facto Standard?

Languages popular with open source programmers will likely continue to grow as the use of open source grows within multi-source applications. With companies today looking for efficiencies both on fiscal and even environmental fronts, coders are going to choose those languages that most ably get the job done.

As the slow but steady shift towards dynamic programming languages occurs, web applications will be written more quickly at lower cost, and companies will save money by saving time. At the same time, web programmers will be able to do their jobs more easily, enabling them to direct their creativity to areas of innovation that create business value.

Share the Post:
Share on facebook
Share on twitter
Share on linkedin

More From DevX