The Impact of Java Applications at Microarchitectural Level from Branch Prediction Perspective

Adrian Florea, Arpad Gellert, Lucian N. Vințan, Marius N. Velțan


The portability, the object-oriented and distributed programming models, multithreading support and automatic garbage collection are features that make Java very attractive for application developers. The main goal of this paper consists in pointing out the impact of Java applications at microarchitectural level from two perspectives: unbiased branches and indirect jumps/calls, such branches limiting the ceiling of dynamic branch prediction and causing significant performance degradation. Therefore, accurately predicting this kind of branches remains an open problem. The simulation part of the paper mainly refers to determining the context length influence on the percentage of unbiased branches from Java applications, the prediction accuracy and the usage degree obtained using a Fast Path-Based Perceptron predictor. We realize a comparison with C/C++ application behavior from unbiased branches perspective. We also analyze some Java testing programs, built using design patterns or including inheritance, polymorphism, backtracking and recursivity, in order to determine the features of indirect branches, the arity of each indirect jump and the prediction accuracy using the Target Cache predictor.


object-oriented programs, branch prediction, indirect jumps/calls, unbiased branches, benchmarking

Full Text:



Gosling J., Java: a Tour of the Landscape, Sun Technology Days at a Glance, Frankfurt, Germany, 3-5 December, 2007.

Calder B., Grunwald D., Zorn B., Quantifying behavioral differences between C and C++ programs, Journal of Programming Languages, Volume 2, Issue 4, 1994, pp. 313-351.

Florea A., Vințan L., Mihu I.Z., Understanding and Predicting Indirect Branch Behavior, Studies in Informatics and Control, Volume13, Issue 1, March 2004, pp. 61-82, National Institute for Research and Development in Informatics, Bucharest.

Alpern B., Cocchi A., Fink S., Grove D., Lieber D., Efficient implementation of Java interfaces: Invoke interface considered harmless, In Proceedings of the 16th ACM SIGPLAN Conference on Object-Oriented Programming Systems, Languages and Applications, pp. 108-124, October 14-18, 2001, Tampa, Florida, USA.

Joao J.A., Mutlu O., Kim H., Agarwal R., Patt Y., Improving the Performance of Object-Oriented Languages with Dynamic Predication of Indirect Jumps, ACM SIGOPS Operating Systems Review, Volume 42, Issue 2, March 2008, pp. 80-90.

Vințan L., Gellert A., Florea A., Oancea M., Egan C. Understanding Prediction Limits through Unbiased Branches, Lecture Notes in Computer Science, Advances in Computer Systems Architecture, vol. 4186, pp. 480-487, 2006, Springer-Verlag Berlin.

Gellert A., Florea A., Vințan M., Egan C., Vințan L. Unbiased Branches: An Open Problem, Lecture Notes in Computer Science, Advances in Computer Systems Architecture, vol. 4697, pp. 16-27, 2007, Springer-Verlag Berlin / Heidelberg.

Radu C., Calborean H., Crapciu A., Gellert A., Florea A., An Interactive Graphical Trace-Driven Simulator for Teaching Branch Prediction in Computer Architecture, The 6th EUROSIM Congress on Modeling and Simulation, September 9-13, 2007, pp. 58 (6 pg.), Ljubljana, Slovenia.

SPEC JVM98 benchmarks,

Jiménez D. Fast Path-Based Neural Branch Prediction, Proceedings of the 36th Annual International Symposium on Microarchitecture, December 3-5, 2003, pp. 243-252, San Diego, CA, USA.

Freeman E., Freeman E., Sierra K., Bates B. Head First Design Patterns, O'Reilly Publishing House, First Edition, October 2004.

Veltan N.M. The Interaction of Java Programs at Microarchitectural Level from Branch Prediction Viewpoint (in Romanian), MSc Thesis, 'Lucian Blaga' University of Sibiu, Computer Science Department, Romania, 2008.

The University of Massachusetts Amherst and the University of Texas - Dynamic SimpleSscalar, 2004.

Lindholm T., Yellin F., The JavaTM Virtual Machine Specification, Sun Press Publishing Hall, 1999.

Chang P.Y., E. Hao, Y.N. Patt., Target Prediction for Indirect Jumps, Proceedings of the International Symposium on Computer Architecture, 1997.

Jiménez D., Lin C. Neural Methods for Dynamic Branch Prediction, ACM Transactions on Computer Systems, Vol. 20, Issue 4, November 2002, pp. 369-397, New York, USA.

Jiménez D., Idealized Piecewise Linear Branch Prediction, Journal of Instruction-Level Parallelism, Vol. 7, April, 2005, pp. 1-11.

Loh G. H., Jiménez D., Reducing the Power and Complexity of Path-Based Neural Branch Prediction, Proceedings of the 5th Workshop on Complexity Effective Design (WCED5), pp. 1-8, June 5, 2005, Madison, WI, USA.

Burger D., Austin T., The SimpleScalar Tool Set, Version 2.0, University of Wisconsin Madison, USA, Computer Science Department, Technical Report no. 1342, June, 1997.

Bowers K. R., Kaeli D., Characterizing the SPEC JVM98 benchmarks on the Java virtual machine, Technical Report, Northeastern University, ECE Department, Computer Architecture Group, 1998, pp. 1-20, Boston, Massachusetts, USA.

Florea A., The dynamic values prediction in the next generation microprocessors (in Romanian), MatrixRom Publishing House, 2005, Bucharest.

Tao Li, Lizy K. John, Adapting Branch-Target Buffer to Improve the Target Predictability of Java Code, ACM Transactions on Architecture and Code Optimization, Volume 2, Issue 2, June 2005, pp. 109-130.

Florea A., Vințan L., Advanced techniques for improving indirect branch prediction accuracy, Proceedings of 19th European Conference on Modelling and Simulation, June 2005, pp. 750-759, Riga, Latvia.

Florea A., Radu C., Calborean H., Crapciu A., Gellert A., Vințan L., Designing an Advanced Simulator for Unbiased Branches Prediction, Proceedings of 9th International Symposium on Automatic Control and Computer Science, ISSN 1843-665X, Iasi, 2007.


Copyright (c) 2017 Adrian Florea, Arpad Gellert, Lucian N. Vințan, Marius N. Velțan

Creative Commons License
This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.

CC-BY-NC  License for Website User

Articles published in IJCCC user license are protected by copyright.

Users can access, download, copy, translate the IJCCC articles for non-commercial purposes provided that users, but cannot redistribute, display or adapt:

  • Cite the article using an appropriate bibliographic citation: author(s), article title, journal, volume, issue, page numbers, year of publication, DOI, and the link to the definitive published version on IJCCC website;
  • Maintain the integrity of the IJCCC article;
  • Retain the copyright notices and links to these terms and conditions so it is clear to other users what can and what cannot be done with the  article;
  • Ensure that, for any content in the IJCCC article that is identified as belonging to a third party, any re-use complies with the copyright policies of that third party;
  • Any translations must prominently display the statement: "This is an unofficial translation of an article that appeared in IJCCC. Agora University  has not endorsed this translation."

This is a non commercial license where the use of published articles for commercial purposes is forbiden. 

Commercial purposes include: 

  • Copying or downloading IJCCC articles, or linking to such postings, for further redistribution, sale or licensing, for a fee;
  • Copying, downloading or posting by a site or service that incorporates advertising with such content;
  • The inclusion or incorporation of article content in other works or services (other than normal quotations with an appropriate citation) that is then available for sale or licensing, for a fee;
  • Use of IJCCC articles or article content (other than normal quotations with appropriate citation) by for-profit organizations for promotional purposes, whether for a fee or otherwise;
  • Use for the purposes of monetary reward by means of sale, resale, license, loan, transfer or other form of commercial exploitation;

    The licensor cannot revoke these freedoms as long as you follow the license terms.

[End of CC-BY-NC  License for Website User]

INTERNATIONAL JOURNAL OF COMPUTERS COMMUNICATIONS & CONTROL (IJCCC), With Emphasis on the Integration of Three Technologies (C & C & C),  ISSN 1841-9836.

IJCCC was founded in 2006,  at Agora University, by  Ioan DZITAC (Editor-in-Chief),  Florin Gheorghe FILIP (Editor-in-Chief), and  Misu-Jan MANOLESCU (Managing Editor).

Ethics: This journal is a member of, and subscribes to the principles of, the Committee on Publication Ethics (COPE).

Ioan  DZITAC (Editor-in-Chief) at COPE European Seminar, Bruxelles, 2015:

IJCCC is covered/indexed/abstracted in Science Citation Index Expanded (since vol.1(S),  2006); JCR2018: IF=1.585..

IJCCC is indexed in Scopus from 2008 (CiteScore2018 = 1.56):

Nomination by Elsevier for Journal Excellence Award Romania 2015 (SNIP2014 = 1.029): Elsevier/ Scopus

IJCCC was nominated by Elsevier for Journal Excellence Award - "Scopus Awards Romania 2015" (SNIP2014 = 1.029).

IJCCC is in Top 3 of 157 Romanian journals indexed by Scopus (in all fields) and No.1 in Computer Science field by Elsevier/ Scopus.


 Impact Factor in JCR2018 (Clarivate Analytics/SCI Expanded/ISI Web of Science): IF=1.585 (Q3). Scopus: CiteScore2018=1.56 (Q2); Editors-in-Chief: Ioan DZITAC & Florin Gheorghe FILIP.