Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
skip to main content
article
Free access

Corpus-based static branch prediction

Published: 01 June 1995 Publication History
  • Get Citation Alerts
  • Abstract

    Correctly predicting the direction that branches will take is increasingly important in today's wide-issue computer architectures. The name program-based branch prediction is given to static branch prediction techniques that base their prediction on a program's structure. In this paper, we investigate a new approach to program-based branch prediction that uses a body of existing programs to predict the branch behavior in a new program. We call this approach to program-based branch prediction, evidence-based static prediction, or ESP. The main idea of ESP is that the behavior of a corpus of programs can be used to infer the behavior of new programs. In this paper, we use a neural network to map static features associated with each branch to the probability that the branch will be taken. ESP shows significant advantages over other prediction mechanisms. Specifically, it is a program-based technique, it is effective across a range of programming languages and programming styles, and it does not rely on the use of expert-defined heuristics.
    In this paper, we describe the application of ESP to the problem of branch prediction and compare our results to existing program-based branch predictors. We also investigate the applicability of ESP across computer architectures, programming languages, compilers, and run-time systems. Averaging over a body of 43 C and Fortran programs, ESP branch prediction results in a miss rate of 20%, as compared with the 25% miss rate obtained using the best existing program-based heuristics.

    References

    [1]
    R. Alverson, D. Callahan, D. Cummings, B. Koblenz, A. Porterfield, and B. Smith. The tera computer system. In International Conference on Supercomputing, pages 1-6, June 1990.
    [2]
    Vasanth Balasundaram, Geoffrey Fox, Ken Kennedy, and Ulrich Kremer. A static performance estimator to guide data partitioning decisions. In Third ACM SIGPLAN Symposium on Principles & Practice of Parallel Programming, pages 213-223, July 199 I.
    [3]
    Thomas Ball and James R. Larus. Branch prediction for free. In Proceedings of the SIGPLAN'93 Conference on Programming Language Design and Implementation, pages 300-313, June 1993.
    [4]
    M. Berry. The Perfect Club Benchmarks: Effective performance evaluation of supercomputers. The International Journal of Supercomputer Applications, 3(3):5-40, Fall 1989.
    [5]
    Brad Calder and Dirk Grunwald. Fa~at & accurate instruction fetch and branch prediction. In 21st Annual International Symposium on Computer Architecture, pages 2-11. ACM, April 1994.
    [6]
    Brad Calder and Dirk Grunwald. Reducing branch costs via branch alignment. In Six International Conference on Architectural Support for Programming Languages and Operating Systems, pages 242-251. ACM, 1994.
    [7]
    Brad Calder, Dirk Grunwald, and Benjamin Zorn. Quantifying behavioral differences between C and C++ programs. Journal of Programming Languages, 2(4), 1995. Also available as University of Colorado Technical Report CU-CS-698-94.
    [8]
    P. P. Chang and W. W. Hwu. Profile-guided automatic inline expansion for C programs. Software Practice and Experience, 22(5):349-376, 1992.
    [9]
    P. P. Chang, S. A. Mahlke, and W. W. Hwu. Using profile information to assist classic compiler code optimizations. Software Practice and Experience, 21(12):1301-1321, 1991.
    [10]
    A.P. Dempster, A generalization of bayesian inference. Journal of the Royal Statistical Society, 30:205-247,1968.
    [11]
    J. A. Fisher and S. M. Freudenberger. Predicting conditional branch directions from previous runs of a program. In Proceedings of the Fifth International Conference on Architectural Support for Programming Languages and Operating Systems (ASPLOS-V), pages 85-95, Boston, Mass., October 1992. ACM.
    [12]
    Joseph A. Fisher. Trace scheduling: A technique for global microcode compaction. IEEE Transactions on Computers, C- 30(7):478-490, July 1981.
    [13]
    Wen-mei W. Hwu and Pohua P. Chang. Achieving high instruction cache performance with an optimizing compiler. In 16thAnnual International Symposium on Computer Architecture, pages 242-251. ACM, 1989.
    [14]
    Scott McFarling and John Hennessy. Reducing the cost of branches. In 13th Annual International Symposium of Computer Architecture, pages 396-403. Association for Computing Machinery, 1986.
    [15]
    Judea Pearl. Probabilistic Reasoning in Intelligent Systems: Networks of Plausible Inference. Morgan Kaufmann, San Mateo, CA, 1988.
    [16]
    D.E. Rumelhart, G. E. Hinton, and R J. Williams. Parallel distributed processing: Explorations in the microstructure of cognition. Volume h Foundations, chapter Learning internal representations by error propagation, pages 318-362. MIT Press/Bradford Books, Cambridge, MA, 1986. D. E. Rumelhart and J. L. Mc- Clelland, editors.
    [17]
    G. Shafer. A Mathematical Theory of Evidence. Princeton University Press, Princeton, NJ, 1976.
    [18]
    J.E. Smith. A study of branch prediction strategies. In 8thAnnual international Symposium of Computer Architecture, pages 135- 148. ACM, 1981.
    [19]
    P. Smolensky, M. C. Mozer, and D. E. Rumelhart, editors. Mathemattcal perspectives on neural networks. Erlbaum, 1994. In press.
    [20]
    Amitabh Srivastava and Alan Eustace. ATOM: A system for building customized program analysis tools. In Proceedings of the SIGPLAN'94 Conference on Programming Language Design and lmplementatton, pages 196-205. ACM, 1994.
    [21]
    Tim A. Wagner, Vance Maverick, Susan Graham, and Michael Harrison. Accurate static estimators for program optimization. In Proceedings of the SIGPLAN'94 Conjerence on Programming Language Design and Implementation, pages 85-96, Orlando, Florida, June 1994. ACM.
    [22]
    Youfeng Wu and James R. tams. Static branch frequency and program profile analysis. In 27th International Symposium on Microarchitecture, San Jose, Ca, November 1994. IEEE.
    [23]
    Tse-Yu Yeh and Yale N. Patt. A comparison of dynamic branch predictors that use two levels of branch history. In 20th Annual International Symposium on Computer Architecture, pages 257- 266, San Diego, CA, May 1993. ACM.

    Cited By

    View all
    • (2018)Balancing the learning ability and memory demand of a perceptron-based dynamically trainable neural networkThe Journal of Supercomputing10.1007/s11227-018-2374-x74:7(3211-3235)Online publication date: 1-Jul-2018
    • (2004)A garbage collection policy based on empirical behaviorInformation Sciences: an International Journal10.1016/j.ins.2003.05.014167:1-4(129-146)Online publication date: 2-Dec-2004
    • (2003)An alternative to branch predictionACM SIGARCH Computer Architecture News10.1145/882105.88210931:3(20-29)Online publication date: 1-Jun-2003
    • Show More Cited By

    Recommendations

    Comments

    Information & Contributors

    Information

    Published In

    cover image ACM SIGPLAN Notices
    ACM SIGPLAN Notices  Volume 30, Issue 6
    June 1995
    327 pages
    ISSN:0362-1340
    EISSN:1558-1160
    DOI:10.1145/223428
    Issue’s Table of Contents
    • cover image ACM Conferences
      PLDI '95: Proceedings of the ACM SIGPLAN 1995 conference on Programming language design and implementation
      June 1995
      335 pages
      ISBN:0897916972
      DOI:10.1145/207110
    Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

    Publisher

    Association for Computing Machinery

    New York, NY, United States

    Publication History

    Published: 01 June 1995
    Published in SIGPLAN Volume 30, Issue 6

    Check for updates

    Qualifiers

    • Article

    Contributors

    Other Metrics

    Bibliometrics & Citations

    Bibliometrics

    Article Metrics

    • Downloads (Last 12 months)55
    • Downloads (Last 6 weeks)6

    Other Metrics

    Citations

    Cited By

    View all
    • (2018)Balancing the learning ability and memory demand of a perceptron-based dynamically trainable neural networkThe Journal of Supercomputing10.1007/s11227-018-2374-x74:7(3211-3235)Online publication date: 1-Jul-2018
    • (2004)A garbage collection policy based on empirical behaviorInformation Sciences: an International Journal10.1016/j.ins.2003.05.014167:1-4(129-146)Online publication date: 2-Dec-2004
    • (2003)An alternative to branch predictionACM SIGARCH Computer Architecture News10.1145/882105.88210931:3(20-29)Online publication date: 1-Jun-2003
    • (2003)Two-level branch prediction using neural networksJournal of Systems Architecture: the EUROMICRO Journal10.1016/S1383-7621(03)00095-X49:12-15(557-570)Online publication date: 1-Dec-2003
    • (2002)Possibilities of Optimal Execution of Parallel Programs Containing Simple and Iterated Loops on Heterogeneous Parallel Computational Systems with Distributed MemoryProgramming and Computing Software10.1023/A:101370760064328:1(28-40)Online publication date: 1-Jan-2002
    • (2002)A study of dynamic memory management in C++ programsComputer Languages, Systems and Structures10.1016/S0096-0551(02)00015-228:3(237-272)Online publication date: 1-Oct-2002
    • (2001)Dynamic branch prediction using neural networksProceedings Euromicro Symposium on Digital Systems Design10.1109/DSD.2001.952279(178-185)Online publication date: 2001
    • (2001)A study of the allocation behavior of C++ programsJournal of Systems and Software10.1016/S0164-1212(00)00122-957:2(107-118)Online publication date: 22-Jun-2001
    • (2001)Branch Prediction Using Profile DataEuro-Par 2001 Parallel Processing10.1007/3-540-44681-8_57(386-394)Online publication date: 17-Aug-2001
    • (2013)Store-Load-Branch (SLB) predictorProceedings of the 2013 IEEE 19th International Symposium on High Performance Computer Architecture (HPCA)10.1109/HPCA.2013.6522307(59-70)Online publication date: 23-Feb-2013
    • Show More Cited By

    View Options

    View options

    PDF

    View or Download as a PDF file.

    PDF

    eReader

    View online with eReader.

    eReader

    Get Access

    Login options

    Media

    Figures

    Other

    Tables

    Share

    Share

    Share this Publication link

    Share on social media