A java vs. c++ performance evaluation: a 3d modeling benchmark

  • Authors:
  • Luca Gherardi;Davide Brugali;Daniele Comotti

  • Affiliations:
  • DIIMM, University of Bergamo, Italy;DIIMM, University of Bergamo, Italy;DIIMM, University of Bergamo, Italy

  • Venue:
  • SIMPAR'12 Proceedings of the Third international conference on Simulation, Modeling, and Programming for Autonomous Robots
  • Year:
  • 2012

Quantified Score

Hi-index 0.00

Visualization

Abstract

Along the years robotics software and applications have been typically implemented in compiled languages, such as C and C++, rather than interpreted languages, like Java. This choice has been due to their well-known faster behaviors, which meet the high performance requirements of robotics. Nevertheless, several projects that implement robotics functionality in Java can be found in literature and different experiments conduced by computer scientists have proved that the difference between Java and C++ is not so evident. In this paper we report our work on quantifying the difference of performance between Java and C++ and we offer a set of data in order to better understand whether the performance of Java allows to consider it a valid alternative for robotics applications or not. We report about the execution time of a Java implementation of an algorithm originally written in C++ and we compare this data with the performance of the original version. Results show that, using the appropriate optimizations, Java is from 1.09 to 1.51 times slower than C++ under Windows and from 1.21 to 1.91 times under Linux.