{"title":"一种切片非结构化程序的新算法","authors":"M. Harman, S. Danicic","doi":"10.1002/(SICI)1096-908X(199811/12)10:6%3C415::AID-SMR180%3E3.0.CO;2-Z","DOIUrl":null,"url":null,"abstract":"Program slicing is an automatic program abstraction technique whose many applications include software maintenance, re-engineering and comprehension, all of which rely crucially upon the precision of the slicing algorithm used. When slicing is applied to maintenance problems, the programs to be sliced are typically legacy systems, often written in older, 'unstructured' programming styles. For slicing to be a useful tool to the software maintainer it is therefore important to have precise algorithms for slicing unstructured programs.Unfortunately the standard algorithms for slicing structured programs do not extend correctly to the unstructured paradigm, and currently proposed modifications to these standard algorithms produce either unnecessarily large slices or slices which are not true subsets of the original program from which they are constructed.This paper introduces a modification of Agrawal's algorithm for slicing unstructured programs, which overcomes these difficulties. The new algorithm produces thinner slices than any previously published algorithm while respecting both the semantic and syntactic constraints of slicing, (C) 1998 John Wiley & Sons, Ltd.","PeriodicalId":383619,"journal":{"name":"J. Softw. Maintenance Res. Pract.","volume":"85 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"1998-11-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"48","resultStr":"{\"title\":\"A new algorithm for slicing unstructured programs\",\"authors\":\"M. Harman, S. Danicic\",\"doi\":\"10.1002/(SICI)1096-908X(199811/12)10:6%3C415::AID-SMR180%3E3.0.CO;2-Z\",\"DOIUrl\":null,\"url\":null,\"abstract\":\"Program slicing is an automatic program abstraction technique whose many applications include software maintenance, re-engineering and comprehension, all of which rely crucially upon the precision of the slicing algorithm used. When slicing is applied to maintenance problems, the programs to be sliced are typically legacy systems, often written in older, 'unstructured' programming styles. For slicing to be a useful tool to the software maintainer it is therefore important to have precise algorithms for slicing unstructured programs.Unfortunately the standard algorithms for slicing structured programs do not extend correctly to the unstructured paradigm, and currently proposed modifications to these standard algorithms produce either unnecessarily large slices or slices which are not true subsets of the original program from which they are constructed.This paper introduces a modification of Agrawal's algorithm for slicing unstructured programs, which overcomes these difficulties. The new algorithm produces thinner slices than any previously published algorithm while respecting both the semantic and syntactic constraints of slicing, (C) 1998 John Wiley & Sons, Ltd.\",\"PeriodicalId\":383619,\"journal\":{\"name\":\"J. Softw. Maintenance Res. Pract.\",\"volume\":\"85 1\",\"pages\":\"0\"},\"PeriodicalIF\":0.0000,\"publicationDate\":\"1998-11-01\",\"publicationTypes\":\"Journal Article\",\"fieldsOfStudy\":null,\"isOpenAccess\":false,\"openAccessPdf\":\"\",\"citationCount\":\"48\",\"resultStr\":null,\"platform\":\"Semanticscholar\",\"paperid\":null,\"PeriodicalName\":\"J. Softw. Maintenance Res. Pract.\",\"FirstCategoryId\":\"1085\",\"ListUrlMain\":\"https://doi.org/10.1002/(SICI)1096-908X(199811/12)10:6%3C415::AID-SMR180%3E3.0.CO;2-Z\",\"RegionNum\":0,\"RegionCategory\":null,\"ArticlePicture\":[],\"TitleCN\":null,\"AbstractTextCN\":null,\"PMCID\":null,\"EPubDate\":\"\",\"PubModel\":\"\",\"JCR\":\"\",\"JCRName\":\"\",\"Score\":null,\"Total\":0}","platform":"Semanticscholar","paperid":null,"PeriodicalName":"J. Softw. Maintenance Res. Pract.","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1002/(SICI)1096-908X(199811/12)10:6%3C415::AID-SMR180%3E3.0.CO;2-Z","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 48
摘要
程序切片是一种自动程序抽象技术,它的许多应用包括软件维护、重新设计和理解,所有这些都依赖于所使用的切片算法的精度。当切片应用于维护问题时,要切片的程序通常是遗留系统,通常以较旧的“非结构化”编程风格编写。对于软件维护者来说,切片是一个有用的工具,因此有精确的算法来切片非结构化程序是很重要的。不幸的是,切片结构化程序的标准算法不能正确地扩展到非结构化范例,并且目前对这些标准算法提出的修改要么产生不必要的大切片,要么产生不是原始程序的真正子集的切片。本文对Agrawal算法进行了改进,克服了这些困难。新算法产生的切片比以前发表的任何算法都要薄,同时尊重切片的语义和语法约束,(C) 1998 John Wiley & Sons, Ltd。
Program slicing is an automatic program abstraction technique whose many applications include software maintenance, re-engineering and comprehension, all of which rely crucially upon the precision of the slicing algorithm used. When slicing is applied to maintenance problems, the programs to be sliced are typically legacy systems, often written in older, 'unstructured' programming styles. For slicing to be a useful tool to the software maintainer it is therefore important to have precise algorithms for slicing unstructured programs.Unfortunately the standard algorithms for slicing structured programs do not extend correctly to the unstructured paradigm, and currently proposed modifications to these standard algorithms produce either unnecessarily large slices or slices which are not true subsets of the original program from which they are constructed.This paper introduces a modification of Agrawal's algorithm for slicing unstructured programs, which overcomes these difficulties. The new algorithm produces thinner slices than any previously published algorithm while respecting both the semantic and syntactic constraints of slicing, (C) 1998 John Wiley & Sons, Ltd.