Abstract
Data race is the most widespread in concurrent program defects. Aiming at the problems of false positives, false negatives and high overheads in the process of data race detection. A multithreaded programs data race detection method based on the XGBoost model was proposed. The hybrid detection algorithm based on the sim-hb relationship of the thread segment and the lockset algorithm is used to detect data race, identify implicit synchronization pairs and perform instruction-level filtering, and extract instruction features to construct the XGBoost dynamic detection model. Designed and implemented the multithreaded programs data race detection tool XGRace, and performed data race detection on the classic multithreaded programs SPLASH-2 benchmark suite and Parsec benchmark program 3.0. The results show that: compared with Djit+, Eraser, Thread Sanitizer and AIRaceTest, XGrace has an average of 19.7% lower false negatives rate and 6.2% lower false positives rate, while the time and memory overhead are reduced by 34.1% and 29.8% respectively, which provides an effective and accurate data race detection method for multithreaded programs.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Similar content being viewed by others
References
Su, X.H., Yu, Z., Wang, T.T.: A survey on exposing detecting and avoiding concurrency bugs. Chin. J. Comput. 38(11), 2215–2233 (2015)
Biswas, S., Cao, M., Zhang, M.: Lightweight data race detection for production runs. In: Proceedings of the 26th International Conference on Compiler Construction, pp. 11–21. ACM, New York (2017)
Sulzmann, M., Stadtmuller, K.: Efficient, near complete, and often sound hybrid dynamic data race prediction. In: Proceedings of the 17th International Conference on Managed Programming Languages and Runtimes, pp. 30–51. ACM, New York (2020)
Savage, S., Burrows, M., Nelson, G., Sobalvarro, P.: Eraser: a dynamic data race detector for multithreaded programs. ACM Trans. Comput. Syst. 15(4), 391–411 (1997)
Pozniansky, E., Schuster, A.: Efficient on-the-fly data race detection in multithreaded C++ programs. In: Proceedings of the Ninth ACM SIGPLAN Symposium on Principles and Practice of Parallel Programming, pp. 179–190. ACM, New York (2003)
Serebryany, K., Iskhodzhanov, T.: ThreadSanitizer: data race detection in practice. In: Proceedings of the Workshop on Binary Instrumentation and Applications, pp. 62–71. ACM, New York (2009)
Guo, Y., Cao, Y., Yang, Z.: AtexRace: across thread and execution sampling for in-house race detection. In: Proceedings of the 2017 11th Joint Meeting on Foundations of Software Engineering, pp. 315–325. ACM, New York (2017)
Sun, J Z., Yang, J W., Yang, Z J.: Random forest instruction level detection model for data race in multithreaded programs. J. Tsinghua Univ. (Sci. Technol.) 60(10), 804–813 (2020)
Chen, T., Guestrin, C.: XGBoost: a scalable tree boosting system. In: Proceedings of the 22nd ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, pp. 785–794. ACM, New York (2016)
Jannesari, A., Tichy, W.F.: Library-independent data race detection. IEEE Trans. Parallel Distrib. Syst. 25(10), 2606–2616 (2014)
Luk, C.K., Cohn, R., Muth, R.: Pin: building customized program analysis tools with dynamic instrumentation. ACM SIGPLAN Not. 40(6), 190–200 (2005)
ARNAB DAS.arnabd88.[CP/DK] (2017). https://github.com/arnabd88
Badr, M., Jerger, N E.: Fast and accurate performance analysis of synchronization. In: Proceedings of the 9th International Workshop on Programming Models and Applications for Multicores and Manycores, pp. 31–40. ACM, New York (2018)
Rauber, T., Runger, G., Stachowski, M.: Model-based optimization of the energy efficiency of multi-threaded applications. Sustain. Comput. Inform. Syst. 22(1), 44–61 (2019)
Acknowledgment
This work was supported by the Key R&D Projects of Shaanxi Province (Grant No. 2020GY-010), the Postgraduate Innovation Fund Project of Xi’an University of Posts and Telecommunications (Grant No. CXJJLY2019072).
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2022 The Author(s), under exclusive license to Springer Nature Switzerland AG
About this paper
Cite this paper
Sun, J., Shan, L., Shu, X. (2022). XGBoost Dynamic Detection for Data Race in Multithreaded Programs. In: Xie, Q., Zhao, L., Li, K., Yadav, A., Wang, L. (eds) Advances in Natural Computation, Fuzzy Systems and Knowledge Discovery. ICNC-FSKD 2021. Lecture Notes on Data Engineering and Communications Technologies, vol 89. Springer, Cham. https://doi.org/10.1007/978-3-030-89698-0_128
Download citation
DOI: https://doi.org/10.1007/978-3-030-89698-0_128
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-030-89697-3
Online ISBN: 978-3-030-89698-0
eBook Packages: Intelligent Technologies and RoboticsIntelligent Technologies and Robotics (R0)