Computer Science ›› 2020, Vol. 47 ›› Issue (9): 31-39.doi: 10.11896/jsjkx.200100075

• Computer Software • Previous Articles     Next Articles

Memory Leak Test Acceleration Based on Script Prediction and Reconstruction

LI Yin1,2, LI Bi-xin1   

  1. 1 School of Computer Science and Engineering,Southeast University,Nanjing 211189,China
    2 Jiangsu Automation Research Institute,Lianyungang,Jiangsu 222006,China
  • Received:2020-01-10 Published:2020-09-10
  • About author:LI Yin,born in 1988,master.His main research interests include bigdata,software reliability and software testing,etc.
    LI Bi-xin,born in 1969,Ph.D,professor.His main research interests include software analysis,testing and verification,and empirical software engineering,etc.

Abstract: Memory leak is a common defect in continuous working software,such as cloud applications,web service,middleware,etc.It can affect the stability of software applications,lead to run in bad performance and even crash.To clearly observe memory leaks,the test cases toward them need to execute longer time in order to generate significant memory pressure.The cost of memory leaks testing is expensive.If the execution orders of test cases are not optimized,we may waste lots of time on the test cases that are not likely to reveal faults before finding test cases that really containing memory leaks.This seriously reduces the efficiency of fault discovery.In order to make up for the shortcomings of the existing technology and solve the problems of the me-mory leak of Java Web program while running for a long time,which is not easy to find,diagnose and repair,this paper studies the memory leak detection technology,proposes the memory leak test script prediction method based on machine learning.The methodtrains and predicts the script with memory leak by building the memory feature model.Then,based on the training model,it predicts the risk value of script memory leak,and gives the corresponding parameter scores,to guide the subsequent script reorganization,can predict and obtain the function test script that is more likely to cause memory leak.At the same time,a script reorganization optimization method is proposed to improve its defect revealing ability.Priority testing of predicted and recombined scripts can accelerate the detection of leakage defects.Finally,a case study shows that the proposed framework has strong leak detection ability.The speed of defect detection of the optimized test script can be more than twice as fast as that of the common script,thus accelerating the exposure time of memory expansion problem,achieving the purpose of improving test efficiency and ensuring software quality.

Key words: Machine learning, Memory leak, Memory leak prediction model, Test script, test script reconstruction

CLC Number: 

  • TP311.5
[1] ŠOR V,SRIRAMAS N.Memory leak detection in Java:Taxonomy and classification of approaches[J].Journal of Systems and Software (JSS),2014,96:139-151.
[2] VALENTIM N A,MACEDO A,MATIASR.A SystematicMapping Review of the First 20 Years of Software Aging and Rejuvenation Research[C]//IEEE International Symposium on Software Reliability Engineering Workshops (ISSREW).2016.
[3] HEINE D L,LAM M S.A practical flow-sensitive and context-sensitive C and C++ memory leak detector[C]//ACM SIGPLAN Conference on Programming Language Design and Implementation (PLDI).2003.
[4] XIE Y,AIKEN A.Context- and path-sensitive memory leak detection[C]//13th ACM SIGSOFT International Symposium on Foundations of Software Engineering (FSE).2005:115-125.
[5] XU Z,ZHANG J,XU Z.Memory leak detection based on me-mory state transition graph[C]//Proceedings of the Asia-Pacific Software Engineering Conference (APSEC).2011:33-40.
[6] SUI Y,YE D,XUE J.Static memory leak detection using full-sparse value-flow analysis[C]//Proceedings of the International Symposium on Software Testing and Analysis.2012.
[7] LI Q,PAN M X,LIX D.Benchmark of tools for memory leak[J].Computer Science and Exploration,2010,4(1):29-35.
[8] JUMP M,MCKINLEY K S.Detecting memory leaks inma-naged languages with Cork[J].Software:Practice and Expe-rience,2010,40(1):1-22.
[9] MAXWELL E K,BACK G,RAMAKRISHNANN.Diagnosingmemory leaks using graph mining on heap dumps[C]//Procee-dings of the 16th ACM SIGKDD International Conference on Knowledge Discovery and Data Mining (KDD).2010:115-124.
[10] RAYSIDE D,MENDE L L.Object ownership profiling:a technique for finding and fixing memory leaks [C]//The 22nd IEEE/ACM International Conference on Automated Software Engineering (ASE).2007:194-203.
[11] ŠOR V,SRIRAMAS N,SALNIKOV-TARNOVSKI N.Memory leak detection in Plumbr.Software[M].Practice and Expe-rience (SPE),2014.
[12] CHILIMBI T,HAUSWIRTHM.Low-overhead memory leakdetection using adaptive statistical profiling[C]//The 11th International Conference on Architectural Support for Programming Languages and Operating Systems.2004.
[13] BOND M D,MCKINLEY K S.Bell:bit-encoding online memory leak detection[C]//The 12th International Conference on Architectural Support for Programming Languages and Operating Systems (ASPLOS).2006:61-72.
[14] XU G,ROUNTEV A.Precise memory leak detection for Java software using container profiling[J].ACM Transactions on Software Engineering and Methodology (TOSEM),2013,22(3):17.
[15] JUNG C,LEE S,RAMAN E,et al.Automated memory leak detection for production use[C]//International Conference on Software Engineering (ICSE).2014.
[16] LEE S,JUNG C,PANDES.Detecting memory leaks through introspective dynamic behavior modelling using machine learning[C]//International Conference on Software Engineering (ICSE).2014.
[17] JIA X X,WU J,JIN M Z,et al.Overviewon memory leak of Java program [J].Computer Research and Application,2006(9):1-4.
[18] SHAHRIAR H,NORTH S,MAWANG I E.Testing of Memory Leak in Android Applications[C]//International Symposium on High-Assurance Systems Engineering (HASE).2014.
[19] YAN D,YANG S,ROUNTEV A.Systematic testing for re-source leaks in Android applications[C]//24th International Symposium on Software Reliability Engineering (ISSRE).2013.
[20] GUNDECHA U.Selenium Testing Tools Cookbook (2 edition) [M].Packt Publishing,2015.
[21] BODDEN E.Invoke Dynamic support in Soot.ACM SIGPLAN[C]//International Workshop on the State of the Art in Java Program Analysis.2012:51-55.
[1] LENG Dian-dian, DU Peng, CHEN Jian-ting, XIANG Yang. Automated Container Terminal Oriented Travel Time Estimation of AGV [J]. Computer Science, 2022, 49(9): 208-214.
[2] NING Han-yang, MA Miao, YANG Bo, LIU Shi-chang. Research Progress and Analysis on Intelligent Cryptology [J]. Computer Science, 2022, 49(9): 288-296.
[3] LI Yao, LI Tao, LI Qi-fan, LIANG Jia-rui, Ibegbu Nnamdi JULIAN, CHEN Jun-jie, GUO Hao. Construction and Multi-feature Fusion Classification Research Based on Multi-scale Sparse Brain Functional Hyper-network [J]. Computer Science, 2022, 49(8): 257-266.
[4] ZHANG Guang-hua, GAO Tian-jiao, CHEN Zhen-guo, YU Nai-wen. Study on Malware Classification Based on N-Gram Static Analysis Technology [J]. Computer Science, 2022, 49(8): 336-343.
[5] HE Qiang, YIN Zhen-yu, HUANG Min, WANG Xing-wei, WANG Yuan-tian, CUI Shuo, ZHAO Yong. Survey of Influence Analysis of Evolutionary Network Based on Big Data [J]. Computer Science, 2022, 49(8): 1-11.
[6] CHEN Ming-xin, ZHANG Jun-bo, LI Tian-rui. Survey on Attacks and Defenses in Federated Learning [J]. Computer Science, 2022, 49(7): 310-323.
[7] LI Ya-ru, ZHANG Yu-lai, WANG Jia-chen. Survey on Bayesian Optimization Methods for Hyper-parameter Tuning [J]. Computer Science, 2022, 49(6A): 86-92.
[8] ZHAO Lu, YUAN Li-ming, HAO Kun. Review of Multi-instance Learning Algorithms [J]. Computer Science, 2022, 49(6A): 93-99.
[9] XIAO Zhi-hong, HAN Ye-tong, ZOU Yong-pan. Study on Activity Recognition Based on Multi-source Data and Logical Reasoning [J]. Computer Science, 2022, 49(6A): 397-406.
[10] YAO Ye, ZHU Yi-an, QIAN Liang, JIA Yao, ZHANG Li-xiang, LIU Rui-liang. Android Malware Detection Method Based on Heterogeneous Model Fusion [J]. Computer Science, 2022, 49(6A): 508-515.
[11] WANG Fei, HUANG Tao, YANG Ye. Study on Machine Learning Algorithms for Life Prediction of IGBT Devices Based on Stacking Multi-model Fusion [J]. Computer Science, 2022, 49(6A): 784-789.
[12] XU Jie, ZHU Yu-kun, XING Chun-xiao. Application of Machine Learning in Financial Asset Pricing:A Review [J]. Computer Science, 2022, 49(6): 276-286.
[13] LI Ye, CHEN Song-can. Physics-informed Neural Networks:Recent Advances and Prospects [J]. Computer Science, 2022, 49(4): 254-262.
[14] YAO Xiao-ming, DING Shi-chang, ZHAO Tao, HUANG Hong, LUO Jar-der, FU Xiao-ming. Big Data-driven Based Socioeconomic Status Analysis:A Survey [J]. Computer Science, 2022, 49(4): 80-87.
[15] ZHANG Ying-li, MA Jia-li, LIU Zi-ang, LIU Xin, ZHOU Rui. Overview of Vulnerability Detection Methods for Ethereum Solidity Smart Contracts [J]. Computer Science, 2022, 49(3): 52-61.
Viewed
Full text


Abstract

Cited

  Shared   
  Discussed   
No Suggested Reading articles found!