Presentation is loading. Please wait.

Presentation is loading. Please wait.

Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Java.

Similar presentations


Presentation on theme: "Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Java."— Presentation transcript:

1 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Java Program Analysis Projects in Osaka University: Aspect-Based Slicing System ADAS and Ranked-Component Search System SPARS-J Reishi Yokomori, Takashi Ishio, Tetsuo Yamamoto, Makoto Matsushita, Shinji Kusumoto and Katsuro Inoue {yokomori, t-isio, t-yamamt, matusita, kusumoto, inoue}@ist.osaka-u.ac.jp

2 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Background Large scale software is difficult to debug. Especially, fault localization needs much cost since the place where a program crushed is not always close to the fault. Executed codes for one test case are usually small pieces of the program. Excluding automatically unrelated codes is effective for fault localization.

3 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Program Slicing Program Slicing extracts a slice of codes, which affects value of a specific variable. Program Slicing excludes unrelated codes to aid fault localization. a slice based on slice criteria ( 6, b ) 1: a = 5; 2: b = a + a; 3: if (b > 0) { 4: c = a; 5: } 6: d = b; 1: a = 5; 2: b = a + a; 3: if (b > 0) { 4: c = a; 5: } 6: d = b;

4 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Slice Calculation Process Phase 1: Extraction of dependence relations. Data Dependence Control Dependence Phase 2: Construction of Program Dependence Graph node: a statement. edge: a dependence relation Phase 3: Traversal of PDG traversal backward from a node corresponding a slice criteria 1: a = 1; 2: c = 4; 3: b = a; 1: a = 1; 2: c = 4; 3: b = a; a Data Dependence 4: if (a < 1) { 5: b = a; 6: } 4: if (a < 1) { 5: b = a; 6: } Control Dependence Program Dependence Graph slice criteria

5 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Dependence-Cache (DC) slicing using dynamic information In slice calculation process, observing program execution, and using information about statements actually executed is effective to decrease the slice size. which method is actually executed ? what type of object is accessed ? Dependence-Cache (DC) slicing has been proposed for use in a dynamic data dependence analysis and a static control dependence analysis to calculate accurate slices with lightweight costs.

6 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Implementation of dynamic analysis Although various ways exist in implementing the dynamic analysis, each one requires a high cost in implementation or in runtime. Aspect-oriented programming improves modularity of crosscutting concerns. Dynamic analysis is a typical crosscutting concern.

7 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Aspect-Oriented Dynamic Analysis and Slicing Calculation System: ADAS Debugging Support Tool using Program Slicing for Java Dynamic Analysis Aspect (written in AspectJ) Simple logging-like Implementation Lightweight Analysis less overhead: The aspect is linked to target program at compile time. coarse analysis: The aspect ignore local data and controls. Program Slicing System Program Slicing is an application using dynamic information. The prototype is implemented as Eclipse plug-in.

8 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Architecture and Use Case of ADAS Java Source Dynamic Analysis Aspect Java Bytecode Java VM AspectJ Dynamic Info. Slice Calculation Tool program slice Static Info. slice criteria 3.execute a test case 1.edit 4.slice calculation Static Analyzer 2.compile

9 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Demonstration

10 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Remark and Future Work ADAS supports debugging tasks Program slicing shows related code to a user. Dynamic information exclude unexecuted code. Dynamic Analysis Aspect is simple implementation, easy to maintain, customize. Future Work Extension of ADAS to calculate AspectJ slice, Improvement of Usability.

11 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Java Program Analysis Projects in Osaka University: Aspect-Based Slicing System ADAS and Ranked-Component Search System SPARS-J Reishi Yokomori, Takashi Ishio, Tetsuo Yamamoto, Makoto Matsushita, Shinji Kusumoto and Katsuro Inoue {yokomori, t-isio, t-yamamt, matusita, kusumoto, inoue}@ist.osaka-u.ac.jp

12 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Reuse of Software Components Reuse of software components is a technique of developing new software components by using the components developed in the past. Example of reusable components: source code, document ….. improves productivity and quality, and cuts down development cost as a result. However, reuse of components is not utilized effectively. A developer doesn’t know existence of desirable components. Although there are a lot of components, these components are not organized. In order to take advantage of reuse, it is required to share the knowledge of components.

13 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Motivation of Our Research We can get a lot of source codes easily through the Internet. Software development communities, such as SourceForge, release source code For promotion of exchanges of views and information between developers. Publishing companies of programming guide book open the example programs to the public. These source codes can be helpful as a source of knowledge about reusable components. A search engine for the components collected from the Internet is useful to reuse of components.

14 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 SPARS SPARS … Software Product Archiving, analyzing and Retrieving System Now, we are developing for Java codes. In SPARS, 1.Components (source codes) are collected from the Internet. 2.Components are analyzed syntactically. 3.A search engine is built based on the analysis information. In order to make a search engine user-friendly, The components used repeatedly are displayed on the higher rank of a search result. –The evaluation value of each component is calculated from the use relation between components. ( Component Rank ) Information of the component is displayed in an easy-to-understand way. –Source code –Other components which it uses –Similar components Katsuro Inoue, Reishi Yokomori, Hikaru Fujiwara, Tetsuo Yamamoto, Makoto Matsushita, Shinji Kusumoto: "Component Rank: Relative Significance Rank for Software Component Search", ICSE, Portland, OR, May 6, 2003.

15 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Structure of Repository Construction Subsystem Component Repository Ranker Searcher Query Parser Browser Parser Analyzer Java Source Files Formatter Word Repository Cluster Source Code Repository Retrieval Subsystem

16 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Demonstration

17 Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Summary and Future Work Summary We developed component search engine SPARS-J By ranking using Component Rank, retrieval of components used well is enabled easily. We expect a promotion of reuse by sharing of knowledge about component. Future Work Improvement in a performance of SPARS-J Improvement in a retrieval function Examination of the component information to display Evaluation of SPARS-J


Download ppt "Software Engineering Laboratory, Department of Computer Science, Graduate School of Information Science and Technology, Osaka University ICSE 2003 Java."

Similar presentations


Ads by Google