The article by Mark Weiser from the University of Maryland explores the use of program slicing as a debugging technique by programmers. Programmers often break down large programs into smaller, coherent pieces, but they also use a concept called *slices*—sets of statements related by their flow of data—when debugging unfamiliar programs. Slices are not necessarily textually contiguous but can be scattered throughout the program.
The study aims to test the hypothesis that programmers construct mental slices when debugging, contrasting it with the contiguous chunk hypothesis. The experiment involves experienced Algol-W programmers debugging three programs: TALLY, EVADE, and PAYROLL. After debugging, participants were asked to recognize code fragments from the programs, including relevant slices, irrelevant slices, and jumbled code.
The results show that participants recognized relevant slices significantly more often than irrelevant slices or jumbled code. However, there was no significant difference in recognition rates between relevant slices and contiguous code. The study suggests that slicing is particularly useful for debugging unstructured or poorly designed programs, as it helps in understanding the program's state and flow of control.
The implications of the findings include the potential practical use of automatic slicers for interactive debugging and program complexity analysis. The article also discusses the limitations of the study, such as the difficulty of recognizing slices and the need for more challenging programs to elicit slicing behavior.The article by Mark Weiser from the University of Maryland explores the use of program slicing as a debugging technique by programmers. Programmers often break down large programs into smaller, coherent pieces, but they also use a concept called *slices*—sets of statements related by their flow of data—when debugging unfamiliar programs. Slices are not necessarily textually contiguous but can be scattered throughout the program.
The study aims to test the hypothesis that programmers construct mental slices when debugging, contrasting it with the contiguous chunk hypothesis. The experiment involves experienced Algol-W programmers debugging three programs: TALLY, EVADE, and PAYROLL. After debugging, participants were asked to recognize code fragments from the programs, including relevant slices, irrelevant slices, and jumbled code.
The results show that participants recognized relevant slices significantly more often than irrelevant slices or jumbled code. However, there was no significant difference in recognition rates between relevant slices and contiguous code. The study suggests that slicing is particularly useful for debugging unstructured or poorly designed programs, as it helps in understanding the program's state and flow of control.
The implications of the findings include the potential practical use of automatic slicers for interactive debugging and program complexity analysis. The article also discusses the limitations of the study, such as the difficulty of recognizing slices and the need for more challenging programs to elicit slicing behavior.