Identyfikatory
Warianty tytułu
Decomposition of Branching Instructions in a Code Optimization Process
Języki publikacji
Abstrakty
Tematem niniejszego artykułu była ocena możliwości ręcznej modyfikacji kodu źródłowego w celu optymalizacji czasu wykonania programu. W ramach projektu inżynierskiego zaproponowano autorskie techniki optymalizacyjne, wykorzystujące dekompozycję instrukcji rozgałęziających. Eksperymentalnie zbadano efektywność prezentowanej dekompozycji dla procesora z rodziny Intel x86, wykonującego operacje w sposób potokowy. W ramach niniejszej pracy przebadano kompilatory z rodziny Clang oraz GCC dla języka C i C++ oraz środowisko JVM.
The subject of this article was the manual modification of source code in order of reducing average execution time of certain repeated conditional move operations. This paper is concerned with proposed optimization by utilizing proper decomposition of branching instructions. This article described in detail conditional assignment operations as well as conditional operations and adequate CPU execution in regard of specific processor family architecture. Every discussed topic was supported with simplified comp diagrams. Experiments were conducted based of analysis of decompiled machine code and advanced analysis of CPU pipelining and branch predication mechanisms. Proposed optimized solutions were investigated based on processor from Intel x86 family. Examples of applications of mentioned code manipulations with adequate code snippets were presented with adequate performance analysis. As part of this work, the optimization capabilities of the Clang compiler for C and C++ were analysed and validated. Effectiveness of proposed optimization was experimentally tested also for compilers from collections GCC and for the most popular virtual machine environments such as JVM. Gathered cleared results were presented after carried out statistical analysis on column charts and in simplified tables.
Rocznik
Tom
Strony
7--26
Opis fizyczny
Bibliogr. 7 poz., tab., wykr.
Twórcy
autor
- Akademia Górniczo-Hutnicza, Katedra Biocybernetyki i Inżynierii Biomedycznej, Kraków, Polska
autor
- Akademia Górniczo-Hutnicza, Katedra Biocybernetyki i Inżynierii Biomedycznej, Kraków, Polska
Bibliografia
- [1] J. Loomis. (2008) Branch Instructions. [Online].
- http://www.johnloomis.org/microchip/pic32/calc/branch.html
- [2] S. Mittal, “A survey of techniques for dynamic branch prediction”, Concurrency and Computation: Practice and Experience Vol. 3, No. 1, p. e4666, 2019. [Online]. https://arxiv.org/pdf/1804.00261.pdf
- [3] CMOVcc–Conditional Move. [Online]. https://www.jaist.ac.jp/iscenternew/mpc/altix/altixdata/opt/intel/vtune/doc/users_guide/mergedProjects/analyzer_ec/mergedProjects/reference_olh/mergedProjects/instructions/instruct32_hh/vc35.htm
- [4] J. Huang, T.-C. Peng, “Analysis of x86 instruction set usage for DOS/Windows applications and its implication on superscalar design”, IEICE Transactions on Information and Systems Vol. 85, No. 6, pp. 929-939, 2002. [Online]. https://doi.org/10.1002/cpe.4666
- [5] A. Fog. The microarchitecture of Intel, AMD, and VIA CPUs. An optimization guide for assembly programmers and compiler makers. 2023 [Online]. https://www.agner.org/optimize/microarchitecture.pdf
- [6] S.A. Mahlke, R.E. Hank, J.E. McCormick, D.I. August, W.-W.W. Hwu, “A Comparison of Full and Partial Predicated Execution Support for ILP Processors”, SIGARCH Comput. Archit. News,Vol. 23, pp. 138-150, May 1995. [Online]. https://doi.org/10.1145/225830.225965
- [7] A. Piórkowski, M. Żupnik, “Loop optimization in managed code environments with expressions evaluated only once”, TASK Quarterly. Scientific Bulletin of Academic Computer Centre in Gdansk Vol. 14, No. 4, pp. 397-404, 2010. [Online]. https://bibliotekanauki.pl/articles/1955308.pdf
Typ dokumentu
Bibliografia
Identyfikator YADDA
bwmeta1.element.baztech-bb8066b3-18ef-4dce-b9fc-1f489a7fc2fa