为了解决代码测试系统测试C项目的时间开销较大这一问题,本文提出了一种基于缓存估算模型的性能优化方法。该方法向代码测试系统中引入了缓存技术,并且建立了缓存规模估算模型。不相似的C项目应用该模型计算出的缓存规模是不一样的。使用缓存规模估算模型后,代码测试系统文件缓存的规模能够随着C项目的改变而发生改变,具有动态变化的能力。缓存估算模型已在系统中实现,对4个开源C项目的测试结果表明:该优化方法能有效地提高代码测试系统测试C项目时的时间性能。
To solve the problem that it will take a lot of time when testing a Cproject using Code Testing System, this paper put forward a performance optimization method based on Cache Estimation Model. This method not only introduced cache to the Code Testing System, but also established Cache Estimation Model to calculate the size of the cache. Using this model, dissimilar Cprojects will get different cache size. After applying the Cache Estimation Model to the Code Testing System, the cache of the system has the ability to dynamically change its size. The experimental results of four open source Cprojects show that this method can do effectively improve the time performance of the Code Testing System.