首页 | 本学科首页   官方微博 | 高级检索  
相似文献
 共查询到20条相似文献,搜索用时 0 毫秒
1.
用Z形式化描述程序切片   总被引:1,自引:0,他引:1  
程序切片是一种重要技术,已广泛地应用于软件工程的各个领域,如程序理解、维护、调试、测试、复用、度量等.虽然,越来越多的研究者致力于程序切片工作,然而由于缺少形式化方面的工作导致程序切片可能存在不一致性和模糊性.本文尝试着用Z语言来形式化描述程序切片,考虑了程序切片中诸如程序依赖图和程序切片算法等常用的方面.该形式化描述不仅能帮助人们正确地理解程序切片的含义,而且还能够从比较严格的意义上明确程序切片的应用领域.  相似文献   

2.
程序切片是一种重要的程序分析技术,广泛应用于程序的调试、测试与维护等领域。面向方面程序设计作为一种新的软件开发范型,能够实现横切关注点的模块化,其特有的语言元素和功能为切片增加了难度。从静态切片和动态切片两种类型,讨论了面向方面程序切片技术。在此基础上,提出了一种基于简化动态依赖图的面向方面程序切片方法,可以减少动态依赖图中节点和边的数量,生成准确的面向方面程序的动态切片,从而有助于人们更好地对面向方面程序进行分析和理解。  相似文献   

3.
Exception是一类特殊的对象,它在Java方法出错时被创建,并利用try/catch/finally机制抛出、处理异常。本文提出了一种合理的新方法,在系统依赖图中表示异常处理模块,利用图可迭性算法实现了Java程序切片。  相似文献   

4.
周婕  慕晓冬  王杰 《微机发展》2006,16(7):20-22
程序切片是一种程序分析技术,它主要应用在程序的调试和逆向工程。文中介绍了笔者设计并实现的一个C 程序切片系统。其中包括系统的总体框架,系统中使用的数据结构以及切片生成算法。本系统已经成功应用到了X型导弹指挥软件的故障诊断中。  相似文献   

5.
Slicing, Chopping, and Path Conditions with Barriers   总被引:2,自引:0,他引:2  
One of the critiques on program slicing is that slices presented to the user are hard to understand. This is mainly related to the problem that slicing dumps the results onto the user without any explanation. This work will present an approach that can be used to filter slices. This approach basically introduces barriers which are not allowed to be passed during slice computation. An earlier filtering approach is chopping which is also extended to obey such a barrier. The barrier variants of slicing and chopping provide filtering possibilities for smaller slices and better comprehensibility. The concept of barriers is then applied to path conditions, which provide necessary conditions under which an influence between the source and target criterion exists. Barriers make those conditions more precise.  相似文献   

6.
程序切片是一种重要的程序分析技术,随着并行技术在越来越多的程序中得到运用,需要将以往多用于顺序程序的程序切片技术也用于并发程序中。本文在文献[1,2]的基础上考虑到互斥机制作用,改进了原来的并发程序的切片算法,使之适用于互斥机制的并发程序。  相似文献   

7.
Slicing Software for Model Construction   总被引:8,自引:0,他引:8  
Applying finite-state verification techniques (e.g., model checking) to software requires that program source code be translated to a finite-state transition system that safely models program behavior. Automatically checking such a transition system for a correctness property is typically very costly, thus it is necessary to reduce the size of the transition system as much as possible. In fact, it is often the case that much of a program's source code is irrelevant for verifying a given correctness property.In this paper, we apply program slicing techniques to remove automatically such irrelevant code and thus reduce the size of the corresponding transition system models. We give a simple extension of the classical slicing definition, and prove its safety with respect to model checking of linear temporal logic (LTL) formulae. We discuss how this slicing strategy fits into a general methodology for deriving effective software models using abstraction-based program specialization.  相似文献   

8.
并发程序切片是并发程序分析的一种重要手段。针对多线程共享变量通信机制,在通过程序分析工具CodeSurfer获取程序基本信息的基础上构造程序可达图,生成以程序状态和语句二元组为节点的并发程序依赖图,实现了基于程序可达图的并发程序切片原型系统。初步实验结果表明,与传统的切片方法相比,采用基于程序可达图的并发程序切片方法,可有效地解决依赖关系不可传递问题,获得高精度的并发程序切片。  相似文献   

9.
程序切片是一种程序分析技术,它通过把程序减少到只包含与某个特定计算相关的那些语句来分析程序,过程间切片作为图形可达性问题时,需要扩展过程内切片所用的程序依赖图(PDG)成系统依赖图(SDG),然后利用两阶段图形可达性算法计算比较精确的切片,目前程序切片技术的研究以面向对象程序切片为主,文中讨论了一种合适面向对象程序的分层切片方法,并综合分层切片方法和两阶段图形可达性算法提出了一种简化的计算面向对象程序过程间切片的算法。  相似文献   

10.
JAVA语言是目前一种主要的面向对象编程语言,由于JAVA语言复杂的结构,使得对JAVA程序进行程序切片非常困难.本文提出一种层次的构造JAVA系统依赖图的算法,基于JAVA程序本身的层次结构,自顶向下构造系统依赖图,然后基于构造的系统依赖图,用一种改进的两阶段算法得到JAVA程序切片.  相似文献   

11.
传统程序切片技术在计算BPEL程序切片时会产生切片不完备问题,为此,提出一种基于程序依赖图的BPEL静态程序切片技术。该技术根据BPEL语言的特点,通过建立BPEL程序依赖图,计算BPEL程序切片。案例分析表明,该技术能够获得更加全面的程序切片,从而可以帮助软件工程人员更好地测试、调试和维护BPEL程序。  相似文献   

12.
Program Slicing is a well-known decomposition technique that transforms a large program into a smaller one that contains only statements relevant to the computation of a selected function. In this paper, we present two novel predicate-based dynamic slicing algorithms for message passing programs. Unlike more traditional slicing criteria that focus only on parts of the program that influence a variable of interest at a specific position in the program, a predicate focuses on those parts of the program that influence the predicate. The dynamic predicate slices capture some global requirements or suspected error properties of a distributed program and computes all statements that are relevant. The presented algorithms differ from each other in their computational approaches (forward versus backward) and in the granularity of information they provide. A proof of correctness of these algorithms is provided. Through the introduction of dominant states and dominant events, critical statement executions are identified that change the value of the global predicate. Under this formulation, optimizing dynamic predicate slicing becomes a meaningful goal as well. Finally, we present how predicate slices can be applied to support comprehension tasks for analyzing and maintaining distributed programs.  相似文献   

13.
切片工具是平面设计软件自带的一个平面图像切割工具,将美工效果图转换为网页效果图的一个重要的工具,在互联网高度发展的今天,平面设计软件与网页制作软件相结合,设计与制作网页已经成为主流。着重讲解切片工具的作用与优点、切割网页的原则,以及使用案例解释使用切片制作网页。  相似文献   

14.
一种系统依赖图的面向对象扩充方案   总被引:3,自引:0,他引:3  
提出一种对传统的系统依赖图进行面向对象扩充的方案.把传统的系统依赖图和类依赖子图、类层次子图相结合,从而构成了适合描述面向对象程序的面向对象系统依赖图.详细说明了对系统依赖图进行面向对象语法、语义扩充的过程,同时给出了构造面向对象系统依赖图的一般算法以及应用分析.  相似文献   

15.
动态程序切片技术是一种重要的程序分析技术,在软件分析、测试与调试过程中有着广泛的应用。给出一种基于前向计算的动态程序切片方法,该方法首先在对当前执行语句进行定义使用分析的基础上计算该语句定义变量的影响集,其次计算该语句的直接动态依赖关系,最后计算当前执行语句中变量的动态切片。根据该方法设计并实现了一个Java动态程序切片系统,基于一组基准测试程序开展了切片实验,并与已有的切片方法进行了比较。实验结果表明,该方法可以得到比较精确的动态程序切片结果。  相似文献   

16.
基于模型的测试是软件测试中一个重要分支,但随着模型规模的增大,测试用例生成也变得越来越困难.扩展有限状态机(extended finite state machine, EFSM)是一种广泛应用的模型,它是对有限状态机(finite state machine,FSM)的扩展,能够更精确地刻画软件系统的动态行为.对EFSM模型的测试主要包含2个部分:测试迁移路径的生成和覆盖测试迁移路径的测试数据的生成.基于搜索的方法已被应用于测试数据的生成.为了提高在大规模EFSM模型中测试用例生成的效率,在前期对EFSM模型非终止性研究新型依赖性分析和切片技术的基础上,提出了基于EFSM模型不定型切片的测试用例生成方法和测试用例补全方法.通过2个案例分析得出:基于模型切片可以更加准确地生成可行路径和提高测试强度.基于7个基准EFSM模型的实验结果表明,在大多数情况下,在切片上生成测试用例的效率都比在原模型上高.  相似文献   

17.
Although the slicing of programs written in a high-level language has been widely studied in the literature, relatively few papers have been published on the slicing of binary executable programs. The lack of existing solutions for the latter is really hard to understand since the application domain for slicing binaries is similar to that for slicing high-level languages. Furthermore, there are special applications of the slicing of programs without source code like source code recovery, code transformation and the detection of security critical code fragments. In this paper, in addition to describing the method of interprocedural static slicing of binaries, we discuss how the set of the possible targets of indirect call sites can be reduced by dynamically gathered information. Our evaluation of the slicing method shows that, if indirect function calls are extensively used, both the number of edges in the call graph and the size of the slices can be significantly reduced.Ákos Kiss obtained his M.Sc. in Computer Science from the University of Szeged in 2000. He is currently working on his Ph.D. thesis and his chosen field of research is the analysis and optimization of binary executables. He was the chief programmer of a code compaction project which sought to reduce ARM binaries. He is also interested in GCC and in open source developmentJudit Jász obtained her M.Sc. in Computer Science recently from the University of Szeged and is currently a Ph.D student. Her main research interest is adapting slicing methods—originally intended for high-level languages—to binary executables. She is also actively working on improving the GCC compiler.Tibor Gyimóthy is the head of the Software Engineering Department at the University of Szeged in Hungary. His research interests include program comprehension, slicing, reverse engineering and compiler optimization. He has published over 60 papers in these areas and was the leader of several software engineering R&D projects. He is the Program Co-Chair of the 21th International Conference on Software Maintenance, which will be held in Budapest, Hungary in 2005.  相似文献   

18.
一种基于模块单子语义的动态程序切片方法   总被引:2,自引:0,他引:2  
提出一种基于程序模块单子语义的新动态切片方法--模块单子动态切片.首先通过单子转换器,将切片这一类计算抽象成独立于具体语言的实体:切片单子转换器.然后,将该切片转换器作为模块加载到实际程序中,并给出相应的模块单子动态切片算法.据此,可直接在抽象语法结构上计算动态切片,不必记录程序执行历史;相应单子切片器也无需显式地构造诸如依赖图的中间结构.这种模块化抽象机制使得文中的动态切片算法具有很强的可扩展性和重用性.  相似文献   

19.
一种分析和理解程序的方法--程序切片   总被引:21,自引:0,他引:21  
程序切片是一种分析和理解程序的技术,是通过对源程序中每个兴趣点分别计算切片来达到对程序的分析和理解。程序中某个兴趣点的程序切片不仅与该点定义和使用变量有关,而且与影响该变量的值的语名和谓词以及受该变量的值影响的语名的谓词有关。文中详细阐述了程序切片技术的研究与进展情况,并对目前存在各种程序切片方法和工具进行了比较;简单介绍了文中提出的面向对象的分层切片方法及其算法的思想;最后分析了程序切片技术目前  相似文献   

20.
恶意代码检测技术作为网络空间安全的重要研究问题之一,无论是传统的基于规则的恶意代码检测方法,还是基于机器学习的启发式恶意代码检测方法,首先都需要自动化或人工方式提取恶意代码的结构、功能和行为特征.随着网络攻防的博弈,恶意代码呈现出隐形化、多态化、多歧化特点,如何正确而有效的理解恶意代码并提取其中的关键恶意特征是恶意代码...  相似文献   

设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司  京ICP备09084417号