On SNEIPL (software networks extractor) – a part of the SSQSA back end

Slides:



Advertisements
Similar presentations
Connected Components in Software Networks Miloš Savić, Mirjana Ivanović, Miloš Radovanović Department of Mathematics and Informatics Faculty of Science.
Advertisements

Extensions to Svetovid students’ submission environment Doni Pracner, Ivan Pribela, Mirjana Ivanović, Zoran Budimac.
On the concept of the course on software project management Mirjana Ivanović (Zoran Budimac) Faculty of Science, Department of Mathematics and Informatics.
Miloš Savić, Mirjana Ivanović, Miloš Radovanović
UML – Class Diagrams.
Software engineering for real-time systems
OOP in Java Nelson Padua-Perez Chau-Wen Tseng Department of Computer Science University of Maryland, College Park.
Tutorial 6 & 7 Symbol Table
1 The Design of Class Mechanism for MOBY. 2 Earlier Software designers have to choose between the following schemes for the development Earlier Software.
Object-Oriented Metrics
Semantic analysis Enforce context-dependent language rules that are not reflected in the BNF, e.g.a function must have a return statement. Decorate AST.
Criteria for good design. aim to appreciate the proper and improper uses of inheritance and appreciate the concepts of coupling and cohesion.
1 Complexity metrics  measure certain aspects of the software (lines of code, # of if-statements, depth of nesting, …)  use these numbers as a criterion.
PVK-Ht061 Contents Introduction Requirements Engineering Project Management Software Design Detailed Design and Coding Quality Assurance Maintenance.
Software Lifecycle A series of steps through which a software product progresses Lifetimes vary from days to months to years Consists of –people –overall.
SMIILE Finaly COBOL! and what else is new Gordana Rakić, Zoran Budimac.
XML –Query Languages, Extracting from Relational Databases ADVANCED DATABASES Khawaja Mohiuddin Assistant Professor Department of Computer Sciences Bahria.
CS 2511 Fall  Abstraction Abstract class Interfaces  Encapsulation Access Specifiers Data Hiding  Inheritance  Polymorphism.
OOP in Java Fawzi Emad Chau-Wen Tseng Department of Computer Science University of Maryland, College Park.
Advanced Topics in Software Engineering ATSE 2009 Topics, participants and results Gordana Rakic, Zoran Budimac.
UML Class Diagrams: Basic Concepts. Objects –The purpose of class modeling is to describe objects. –An object is a concept, abstraction or thing that.
The Unified Modeling Language (UML) Class Diagrams.
Protus 2.0: Ontology-based semantic recommendation in programming tutoring system Presentor: Boban Vesin Boban Vesin, Aleksandra Klašnja-Milićević Higher.
Do we need theoretical computer science in software engineering curriculum: an experience from Uni Novi Sad Bansko, August 28, 2013.
Software Metrics *** state of the art, weak points and possible improvements Gordana Rakić, Zoran Budimac Department of Mathematics and Informatics, Faculty.
C++ Code Analysis: an Open Architecture for the Verification of Coding Rules Paolo Tonella ITC-irst, Centro per la Ricerca Scientifica e Tecnologica
Paradigm Independent Software Complexity Metrics Dr. Zoltán Porkoláb Department of Programming Languages and Compilers Eötvös Loránd University, Faculty.
Object Oriented Analysis & Design & UML (Unified Modeling Language)1 Part V: Design The Design Workflow Design Classes Refining Analysis Relationships.
1 Software Engineering: A Practitioner’s Approach, 6/e Chapter 15b: Product Metrics for Software Software Engineering: A Practitioner’s Approach, 6/e Chapter.
The Procedure Abstraction, Part V: Support for OOLs Comp 412 Copyright 2010, Keith D. Cooper & Linda Torczon, all rights reserved. Students enrolled in.
1 UML Basic Training. UML Basic training2 Agenda  Definitions: requirements, design  Basics of Unified Modeling Language 1.4  SysML.
The CK Metrics Suite. Weighted Methods Per Class b To use this metric, the software engineer must repeat this process n times, where n is the number of.
The CK Metrics Suite. Weighted Methods Per Class b To use this metric, the software engineer must repeat this process n times, where n is the number of.
Software Engineering Research Group, Graduate School of Engineering Science, Osaka University 1 Evaluation of a Business Application Framework Using Complexity.
CSC3315 (Spring 2008)1 CSC 3315 Subprograms Hamid Harroud School of Science and Engineering, Akhawayn University
Object-Oriented Analysis and Design. Lesson 1: Introduction to Software Engineering.
1 Metrics and lessons learned for OO projects Kan Ch 12 Steve Chenoweth, RHIT Above – New chapter, same Halstead. He also predicted various other project.
An Automatic Software Quality Measurement System.
SOFTWARE DESIGN. INTRODUCTION There are 3 distinct types of activities in design 1.External design 2.Architectural design 3.Detailed design Architectural.
Measurement and quality assessment Framework for product metrics – Measure, measurement, and metrics – Formulation, collection, analysis, interpretation,
Introduction to Java Chapter 7 - Classes & Object-oriented Programming1 Chapter 7 Classes and Object-Oriented Programming.
Gordana Rakić, Zoran Budimac
SSQSA present and future Gordana Rakić, Zoran Budimac Department of Mathematics and Informatics Faculty of Sciences University of Novi Sad
Lecture 2: Review of Object Orientation. © Lethbridge/La ganière 2005 Chapter 2: Review of Object Orientation What is Object Orientation? Procedural.
Connecting Architecture Reconstruction Frameworks Ivan Bowman, Michael Godfrey, Ric Holt Software Architecture Group University of Waterloo CoSET ‘99 May.
UML Fundamental Elements. Structural Elements Represent abstractions in our system. Elements that encapsulate the system's set of behaviors. Structural.
 Description of Inheritance  Base Class Object  Subclass, Subtype, and Substitutability  Forms of Inheritance  Modifiers and Inheritance  The Benefits.
XSnippet: Mining For Sample Code Naiyana Tansalarak and Kajal Claypool Presented by: Shan Li CISC864.
Principles of programming languages 10: Object oriented languages
Review for Final, Fall 2010 Close book, Close notes
Object-Oriented Analysis and Design
Design Characteristics and Metrics
Systems Analysis and Design With UML 2
Towards a Multi-paradigm Complexity Measure
Unified Modeling Language
Section 11.1 Class Variables and Methods
Demeter Aspects Who We Are Aspectual Collaborations
TIM 58 Chapter 8: Class and Method Design
A Pluggable Tool for Measuring Software Metrics from Source Code
UML Class Diagrams: Basic Concepts
Mei-Huei Tang October 25, 2000 Computer Science Department SUNY Albany
Lecture 15 (Notes by P. N. Hilfinger and R. Bodik)
University of Houston-Clear Lake
Multiple Aspect Modeling of the Synchronous Language Signal
Object-Oriented Knowledge Representation
Analysis models and design models
The structure and evolution of scientific collaboration in eLib
Software Metrics SAD ::: Fall 2015 Sabbir Muhammad Saleh.
Design Yaodong Bi.
Chapter 8: Design: Characteristics and Metrics
Presentation transcript:

On SNEIPL (software networks extractor) – a part of the SSQSA back end Miloš Savić, Gordana Rakić, Zoran Budimac and Mirjana Ivanović Department of Mathematics and Informatics Faculty of Sciences University of Novi Sad

Content Introduction Extraction procedure GDN extraction Experiments and results Conclusion and future work 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 2

Introduction Sneipl: software networks extractor that uses eCST representation of source code Software networks: graphs reflecting dependencies among software entities (classes, functions, variables, etc.) SNEIPL Software Networks Extractor Independent of Programming Language Set of eCST trees Set of software networks 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 3

Introduction Output set of software networks function & variable level: static call graph “function  global variable” network class/module level: class/module collaboration network CCN/MCN restricted by specific type of coupling strong/weak aggregation, inheritance forest,… package level: package collaboration network vertical: hierarchy tree

Content Introduction Extraction procedure GDN extraction Experiments and results Conclusion and future work 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 5

Extraction procedure Sneipl uses unification model provided by eCST generator to extract GDN (General Dependency Network) Nodes in GDN corresponds to: PACKAGE_DECL (package/namespace/…) CONCRETE_UNIT_DECL (class/imp. module/…) INTERFACE_UNIT_DECL (interface/def. module/…) FUNCTION_DECL (method/function/…) TYPE_DECL (UDTs) ATTRIBUTE_DECL (class attr./global var./…) eCST universal nodes Following eCST universal nodes are used to form GDN links: IMPORT_DECL EXTENDS IMPLEMENTS INSTANTIATES VAR_DECL BLOCK_SCOPE FUNCTION_CALL ARGUMENT_LIST ARGUMENT FORMAL_PARAM_LIST PARAMETER_DECL TYPE NAME 11/7/2018 11:10:37 PM 6

Extraction procedure GDN link types: 1. REFERENCES USES CALLS and CONTAINS relations 2. REFERENCES subtypes: EXTENDS IMPLEMENTS GLOBAL_VAR LOCAL_VAR RET_TYPE FUNC_PARAM By simple GDN filtering software networks are obtained: static call graph filter: select all GDN nodes that are FUNCTION_DECL connected by CALLS links class/module collaboration network filter: select all GDN nodes that are CONCRETE_UNIT_DECL or INTERFACE_UNIT_DECL connected by REFERENCES links etc. 11/7/2018 11:10:37 PM 7

Content Introduction Extraction procedure GDN extraction Experiments and results Conclusion and future work 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 8

GDN extraction GDN is incrementally built in two phases: Phase 1 forms GDN nodes and CONTAINS links Phase 2 forms GDN links of other types GDN := emptyNetwork; (* phase 1 *) foreach eCST tree in inputSet: phase1Analyzer(currentTree, GDN) (* phase 2 *) foreach eCST tree in inputSet: phase2Analyzer(currentTree, GDN) 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 9

GDN extraction Analyzers in both phases traverse an eCST tree level-by-level realizing trigger - deduce - action mechanism Triggers: RED eCST universal nodes Deduce in phase 1: hierarchy of RED universal nodes in the eCST tree Deduce in phase 2: 1. hierarchy of RED and/or BLUE universal nodes in the eCST tree 2. import list (GDN nodes representing names visible outside an eCST tree that is currently analyzed) 3. relations among GDN nodes represented by GDN links Actions: 1. create one or more GDN nodes/links 2. populate import list 3. rewrite eCST sub-tree with one node 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 10

Phase 1 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 11

Phase 2 IMPORT_DECL: populates import list TYPE: creates REFERENCES links REFERENCES type: first hierarchically above BLUE NAME: creates USES links triggered only if in some FUNCTION_DECL  BLOCK_SCOPE FUNCTION_CALL: creates CALLS links REFERENCES links for C_U_D/I_U_D induce REFERENCES links for P_D CALLS and USES links can induce REFERENCES links for C_U_D/I_U_D and P_D 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 12

Phase 2 trigger : IMPORT_DECL deduce : imported C_U_D “A” from P_D “P” represented by the GDN node “P.A” action : add GDN node “P.A” to import list trigger: TYPE deduce: 1. “A” referenced in GDN “Q.C” scope 2. BLUE == ATTRIBUTE_DECL 3. “A” == C_U_D “P.A” action: “Q.C”  “P.A” (REFERENCES link) “Q.C”  “P.A” (GLOBAL_VAR link) “Q”  “P” (induced REFERENCES link) 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 13

FUNCTION_CALL deduce-action on FUNCTION_CALL trigger is postponed FUNCTION_CALL action rewrites FUNCTION_CALL sub-tree with function return type function call  function definition match: 1. first try using name and number of arguments 2. in the case of complex FUNCTION_CALL  NAME (“object.method”): perform RAPID TYPE ANALYSIS for NAME 3. if multiple candidates for function definition: perform RAPID TYPE ANALYSIS for ARGUMENT_LIST  ARGUMENTs 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 14

Content Introduction Extraction procedure GDN extraction Experiments and results Conclusion and future work 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 15

Experiments and results Student experiment: two equivalent programs written in Java and C# Extraction of networks from large-scale software systems written in: - Java (antlrworks, lucene, tomcat) - Modula-2 (mas, lumos) - Delphi (proprietary project) 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 16

Student experiment Structurally equivalent – the same hierarchy among entities (1 package, 5 classes, 1 interface, 25 methods) Semantically equivalent – realize the same functionality Only difference: written in different programming languages (Java/C#) SNEIPL extracted ISOMORPHIC software networks (as expected) 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 17

Delphi project – unit collaboration network #nodes = 465 #links = 816 avg-deg = 1.755 diameter = 7 SW = 2.446 CC = 0.154 max(in-degree) = 147 max(out-degree) = 140 max(tot-degree) = 148 Blue nodes: - AmcCountrySpecProc (147, 1, 148) - MainAmcBs (2, 140, 142) 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 18

Modula-2 algebra system - SCG #nodes = 3016 #links = 17450 avg-deg = 5.786 diameter = 12 SW = 3.586 CC = 0.086 max(in-degree) = 1132 max(out-degree) = 126 max(tot-degree) = 1134 Blue nodes: MasStor.Adv (1132, 2, 1134) MasStor.Comp (949, 4, 953) 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 19

tomcat-7.0.29 (java soft.) - CCN #nodes = 1384 #links = 4117 Giant WCC: #nodes = 1283 #links = 3937 avg-deg = 3.069 diameter = 16 SW = 5.839 CC = 0.146 max(in-deg) = 220 max(out-deg) = 55 max(tot-deg) = 220 blue node: org.apache.juli.logging.Log (220, 0, 220) 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 20

Content Introduction Extraction procedure GDN extraction Experiments and results Conclusion and future work 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 21

Conclusion and future work From a set of eCST trees is possible to extract software networks: - at different levels of abstraction - where trees represent software systems written in different programming languages - belonging to different programming paradigms Extracted software networks can be used to: - investigate organizational complexity and structural evolution of software systems under the framework of complex network theory - calculate software metrics such as CBO, NOC, DIT, RFC, LCOM and Henry-Kafura complexity (fan-in and fan-out) 11/7/2018 11:10:37 PM 11/7/2018 11:10:37 PM 22

On SNEIPL (software networks extractor) – a part of the SSQSA back end Miloš Savić, Gordana Rakić, Zoran Budimac and Mirjana Ivanović Department of Mathematics and Informatics Faculty of Sciences University of Novi Sad