UPDATED 22:38 EDT / OCTOBER 19 2017

APPS

Facebook open-sources RacerD tool to prevent bugs in concurrent programming

Facebook Inc. has open-sourced a new tool for developers that helps them root out hard to detect bugs in concurrent programming. With the snappy name “RacerD,” it’s designed to examine software code for issues known as “race conditions” and find ways to prevent them.

Race conditions are known to crop up when programmers try to introduce concurrency into their programs. Concurrent programming refers to a form of computing in which several computations are executed during overlapping time periods, thereby allowing applications to work on multiple tasks at once. Software that has been programmed this way can execute multiple instructions at the same time, making it more responsive and allowing it to complete tasks faster.

However, concurrent computing often throws up problems when two or more parts of a program attempt to change the same data at the same time. Because two sets of instructions are being executed at the same time, the potential exists for them to interact in ways that lead to undesirable behavior, which is known as a “race condition.” One example is when a set of instructions alters the value of data just before that piece of data is used by a second set of instructions.

Unfortunately for programmers, race conditions are not easy to identify. As Facebook software engineers Sam Blackshear and Peter O’Hearn noted in their blog post introducing RacerD, it would take a computer millions of years to spot a race condition in a program containing just 40 lines of code because of the incredible number of possible interactions that could take place within that program.

That’s why Facebook created RacerD, which is described as an automated static race condition detection tool that can significantly reduce the time it takes to flag potential problems in concurrent software programs.

The system works by scanning new code as it’s compiled, producing a report that identifies when possible race conditions might appear. O’Hearn said the tool should be able to find most race condition bugs, though it’s still a work in progress, so it may not catch them all.

Facebook’s Android team said it identified more than 1,000 race condition bugs with RacerD when implementing concurrency within the app’s news feed. That led to a 5 percent performance boost with the app, which it said is a significant improvement.

For now, RacerD is only compatible with the Java programming language, but Facebook said it intends to make it work with C++ as well.

Image: testbytes/pixabay

A message from John Furrier, co-founder of SiliconANGLE:

Your vote of support is important to us and it helps us keep the content FREE.

One click below supports our mission to provide free, deep, and relevant content.  

Join our community on YouTube

Join the community that includes more than 15,000 #CubeAlumni experts, including Amazon.com CEO Andy Jassy, Dell Technologies founder and CEO Michael Dell, Intel CEO Pat Gelsinger, and many more luminaries and experts.

“TheCUBE is an important partner to the industry. You guys really are a part of our events and we really appreciate you coming and I know people appreciate the content you create as well” – Andy Jassy

THANK YOU