Abstract
Function versioning is an approach to addressing input-sensitivity of program optimizations. A major side effect of it is notable code size increase, which has been hindering its broad applications to large code bases and space-stringent environments. In this paper, we initiate a systematic exploration into the problem, providing answers to some fundamental questions: Given a space constraint, to which function we should apply versioning? How many versions of a function should we include in the final executable? Is the optimal selection feasible to do in polynomial time? This study proves selecting the best set of versions under a space constraint is NP-complete and proposes a heuristic algorithm named CHoGS which yields near optimal results in quadratic time. We implement the algorithm and conduct experiments through the IBM XL compilers. We observe significant performance enhancement with only slight code size increase; the results from CHoGS show factors of higher space efficiency than those from traditional hotness-based methods.
- P. Berube and J. N. Amaral. Benchmark design for robust profile-directed optimization. In Standard Performance Evaluation Corporation (SPEC) Workshop, 2007.Google Scholar
- P. Berube and J. N. Amaral. Benchmark design for robust prole-directed optimization. In Standard Performance Evaluation Corporation (SPEC) Workshop, 2007.Google Scholar
- J. Bilmes, K. Asanovic, C.-W. Chin, and J. Demmel. Optimizing matrix multiply using PHiPAC: A portable, highperformance, ANSI C coding methodology. In Proceedings of the ACM International Conference on Supercomputing, pages 340--347, 1997. Google Scholar
Digital Library
- D. Chen, N. Vachharajani, R. Hundt, S. wei Liao, V. Ramasamy, P. Yuan, W. Chen, and W. Zheng. Taming hardware event samples for fdo compilation. In International Symposium on Code Generation and Optimization (CGO), Toronto, Ontario, Canada, 2010. Google Scholar
Digital Library
- B. Childers, J. W. Davidson, and M. L. Soffa. Continuous compilation: A new approach to aggressive and adaptive code transformation. In International Parallel and Distributed Processing Symposium(IPDPS), Nice, France, 2003. Google Scholar
Digital Library
- P. fei Chuang, H. Chen, G. F. Hoflehner, D. M. Lavery, and W. chung Hsu. Dynamic prole driven code version selection. In the 11th Annual Workshop on the Interaction between Compilers and Computer Architecture, 2007.Google Scholar
- M. Frigo and S. G. Johnson. The design and implementation of FFTW3. Proceedings of the IEEE, 93(2):216--231, 2005.Google Scholar
Cross Ref
- S. L. Graham, P. B. Kessler, and M. K. Mckusick. Gprof: A call graph execution profiler. In SIGPLAN symposium on Compiler construction, pages 120--126, 1982. Google Scholar
Digital Library
- E.-J. Im, K. Yelick, and R. Vuduc. Sparsity: Optimization framework for sparse matrix kernels. Int. J. High Perform. Comput. Appl., 18(1):135--158, 2004. ISSN 1094-3420. . Google Scholar
Digital Library
- Y. Jiang, E. Zhang, K. Tian, F. Mao, M. Gethers, and X. Shen. Exploiting statistical correlations for proactive prediction of program behaviors. In International Symposium on Code Generation and Optimization (CGO), Toronto, Ontario, Canada, 2010. Google Scholar
Digital Library
- C. Jung, S. Rus, B. P. Railing, N. Clark, and S. Pande. Brainy: effective selection of data structures. In Proceedings of the 32nd ACM SIGPLAN conference on Programming language design and implementation, PLDI '11, pages 86--97, New York, NY, USA, 2011. ACM. Google Scholar
Digital Library
- J. Lau, M. Arnold, M. Hind, and B. Calder. Online performance auditing: Using hot optimizations without getting burned. In ACM SIGPLAN conference on Programming language design and implementation (PLDI), Ottawa, Canada, 2006. Google Scholar
Digital Library
- X. Li, M. J. Garzarn, and D. Padua. A dynamically tuned sorting library. In International Symposium on Code Generation and Optimization (CGO), Palo Alto, California, 2004. Google Scholar
Digital Library
- Y. Liu, E. Z. Zhang, and X. Shen. A cross-input adaptive framework for gpu programs optimization. In Proceedings of International Parallel and Distribute Processing Symposium (IPDPS), pages 1--10, 2009. Google Scholar
Digital Library
- M. Puschel, J. Moura, J. Johnson, D. Padua, M. Veloso, B. Singer, J. Xiong, F. Franchetti, A. Gacic, Y. Voronenko, K. Chen, R. Johnson, and N. Rizzolo. SPIRAL: code generation for DSP transforms. Proceedings of the IEEE, 93(2): 232--275, 2005.Google Scholar
Cross Ref
- M. Samadi, A. Hormati, M. Mehrara, J. Lee, and S. Mahlke. Adaptive input-aware compilation for graphics engines. In Proceedings of the 33rd ACM SIGPLAN Conference on Programming Language Design and Implementation, PLDI '12, pages 13--22, New York, NY, USA, 2012. ACM. ISBN 978-1-4503-1205-9. URL http://doi.acm.org/10.1145/2254064.2254067. Google Scholar
Digital Library
- X. Shen and F. Mao. Modeling relations between inputs and dynamic behavior for general programs. In Proceedings of the Workshop on Languages and Compilers for Parallel Computing, 2007.Google Scholar
- M. Sipser. Introduction to the Theory of Computation 2nd edition. Cengage Learning, Boston, Massachusetts, 1997.Google Scholar
- M. D. Smith. Overcoming the challenges to feedback-directed optimization. In the ACM SIGPLAN Workshop on Dynamic and Adaptive Compilation and Optimization( Dynamo), Boston, USA, 2000. Google Scholar
Digital Library
- N. Thomas, G. Tanase, O. Tkachyshyn, J. Perdue, N. M. Amato, and L. Rauchwerger. A framework for adaptive algorithm selection in stapl. In ACM SIGPLAN symposium on Principles and practice of parallel programming (PPoPP), Chicago, Illinois, USA, 2005. Google Scholar
Digital Library
- K. Tian, Y. Jiang, E. Zhang, and X. Shen. An input-centric paradigm for program dynamic optimizations. In ACM International Conference on Systems, Programming, Languages and Applications (OOPSLA), Reno/Tahoe, Nevada, USA, 2010. Google Scholar
Digital Library
- K. Tian, Y. Jiang, E. Zhang, and X. Shen. An input-centric paradigm for program dynamic optimizations. In ACM International Conference on Systems, Programming, Languages and Applications (OOPSLA), Reno/Tahoe, Nevada, USA, 2010. Google Scholar
Digital Library
- K. Tian, E. Zhang, and X. Shen. A step towards transparent integration of input-consciousness into dynamic program optimizations. In ACM International Conference on Systems, Programming, Languages and Applications (OOPSLA), Portland, Oregon, USA, 2011. Google Scholar
Digital Library
- K. Tian, E. Zhang, and X. Shen. A step towards transparent integration of input-consciousness into dynamic program optimizations. In ACM International Conference on Systems, Programming, Languages and Applications (OOPSLA), Portland, Oregon, USA, 2011. Google Scholar
Digital Library
- M. J. Voss and R. Eigenmann. High-level adaptive program optimization with adapt. In ACM SIGPLAN symposium on Principles and practice of parallel programming (PPoPP), Snowbird, Utah, USA, 2001. Google Scholar
Digital Library
- C. Wang and Z. Li. Parametric analysis for adaptive computation ofoading. In ACM SIGPLAN conference on Programming language design and implementation (PLDI), Washington, DC, USA, 2004. Google Scholar
Digital Library
- R. C. Whaley, A. Petitet, and J. Dongarra. Automated empirical optimizations of software and the ATLAS project. Parallel Computing, 27(1-2):3--35, 2001.Google Scholar
Digital Library
- B.Wu, Z. Zhao, X. Shen, Y. Jiang, Y. Gao, and R. Silvera. Exploiting inter-sequence correlations for program behavior prediction. In ACM International Conference on Systems, Programming, Languages and Applications (OOPSLA), Tucson, Arizona, USA, 2012. Google Scholar
Digital Library
- Z. Zhao, B. Wu, and X. Shen. Challenging the "embarrassingly sequential": Parallelizing finite state machine-based computations through principled speculation. In Proceedings of the 19th International Conference on Architectural Support for Programming Languages and Operating Systems, ASPLOS '14, pages 543--558, New York, NY, USA, 2014. ACM. ISBN 978-1-4503-2305-5. URL http://doi.acm.org/10.1145/2541940.2541989. Google Scholar
Digital Library
Index Terms
Space-efficient multi-versioning for input-adaptive feedback-driven program optimizations
Recommendations
Space-efficient multi-versioning for input-adaptive feedback-driven program optimizations
OOPSLA '14: Proceedings of the 2014 ACM International Conference on Object Oriented Programming Systems Languages & ApplicationsFunction versioning is an approach to addressing input-sensitivity of program optimizations. A major side effect of it is notable code size increase, which has been hindering its broad applications to large code bases and space-stringent environments. ...
Metadata efficiency in versioning file systems
FAST'03: Proceedings of the 2nd USENIX conference on File and storage technologiesVersioning file systems retain earlier versions of modified files, allowing recovery from user mistakes or system corruption. Unfortunately, conventional versioning systems do not efficiently record large numbers of versions. In particular, versioned ...
Versioning Version Trees: The Provenance of Actions that Affect Multiple Versions
IPAW 2016: Proceedings of the 6th International Workshop on Provenance and Annotation of Data and Processes - Volume 9672Change-based provenance captures how an entity is constructed; it can be used not only as a record of the steps taken but also as a guide during the development of derivative or new analyses. This provenance is captured as a version tree which stores a ...







Comments