COHERENT DEPENDENCE CLUSTERS 1 Syed Islam AGENDA Coherent

  • Slides: 22
Download presentation
COHERENT DEPENDENCE CLUSTERS 1 Syed Islam

COHERENT DEPENDENCE CLUSTERS 1 Syed Islam

AGENDA Coherent Clusters (Specialized Dependence Cluster) Visualization Tool for Dependence Clusters Mapping Source Code

AGENDA Coherent Clusters (Specialized Dependence Cluster) Visualization Tool for Dependence Clusters Mapping Source Code Constructs to Clusters Overlapping Clusters Program Comprehension / Maintenance Fault Prediction 2

DEPENDENCE CLUSTER A dependence cluster is a maximal set of program statements where each

DEPENDENCE CLUSTER A dependence cluster is a maximal set of program statements where each statement depends on all other. Minimal Slice 3

DEPENDENCE CLUSTER (SLICE-BASED) Two statements that mutually depend upon each other must be in

DEPENDENCE CLUSTER (SLICE-BASED) Two statements that mutually depend upon each other must be in each others slice. i j A Slice-Based Dependence Clusters is a maximal set of program statements all of which are in each others slice. 4

DEPENDENCE CLUSTER. . Remembering all the slices is too expensive. Approximation techniques were used

DEPENDENCE CLUSTER. . Remembering all the slices is too expensive. Approximation techniques were used Same Slice Cluster Same Slice-Size Cluster. 5

MSG -MONOTONE SLICE-SIZE GRAPH Calculate the Slice Sizes for each SDG vertex of a

MSG -MONOTONE SLICE-SIZE GRAPH Calculate the Slice Sizes for each SDG vertex of a program. Plot all slice sizes of the program in one graph in monotonically increasing order of the sizes. X axis: percentage of slices represented Y axis: normalised slice size 6

COHERENT CLUSTERS Same-Slice Dependence cluster have internal and external requirements. Statements of Clusters constructed

COHERENT CLUSTERS Same-Slice Dependence cluster have internal and external requirements. Statements of Clusters constructed from Backward Slices are all influenced by the same set of statements. (Backward-Slice Cluster) Statements of Clusters constructed from Forward Slices all influence the same set of statements. (Forward-Slice Cluster). A Coherent Cluster is a set of statements where each statement has the same backward slice and the 7 same forward slice.

Dependence Cluster Forward-Slice Backward-Slice Coherent Cluster WHAT FORMS A CLUSTER? x 1 2 5

Dependence Cluster Forward-Slice Backward-Slice Coherent Cluster WHAT FORMS A CLUSTER? x 1 2 5 3 4 y 8

SCG – SLICE/CLUSTER-SIZE GRAPH 9

SCG – SLICE/CLUSTER-SIZE GRAPH 9

SCG – SLICE/CLUSTER-SIZE GRAPH B-MSG F-MSG 10

SCG – SLICE/CLUSTER-SIZE GRAPH B-MSG F-MSG 10

SCG – SLICE/CLUSTER-SIZE GRAPH B-MCG F-MCG 11

SCG – SLICE/CLUSTER-SIZE GRAPH B-MCG F-MCG 11

SCG – SLICE/CLUSTER-SIZE GRAPH Coherent Clusters 12

SCG – SLICE/CLUSTER-SIZE GRAPH Coherent Clusters 12

RESULTS COHERENT CLUSTERS 13

RESULTS COHERENT CLUSTERS 13

14

14

FUNCTION MAPPING TO CLUSTER Tool Maps: source lines and files to clusters. functions represent

FUNCTION MAPPING TO CLUSTER Tool Maps: source lines and files to clusters. functions represent particular computation mapping functions to clusters. Initial Data: Multiple functions form a cluster. Multiple clusters within the same function. 15

APPROXIMATION CONSTRAINTS Calculate percentage of pair of nodes whose slices are the same; to

APPROXIMATION CONSTRAINTS Calculate percentage of pair of nodes whose slices are the same; to that of where the nodes in the pair are in each others slice. x and y, where nodes x and y are nodes of a pdg | { x, y : S(x) = S(y) }| | { x, y : x S(y) y S(x) }| S() – Backward Slice The algorithm runs in T(n) = O(n 3) hence 30 days BC – The results is 60%. 16

COHERENT CLUSTER DEPENDENCE GRAPH 1 2 5 3 4 What does this mean? 17

COHERENT CLUSTER DEPENDENCE GRAPH 1 2 5 3 4 What does this mean? 17 17

COHERENT CLUSTER DEPENDENCE GRAPH. . 1 2 5 3 4 Does this mean we

COHERENT CLUSTER DEPENDENCE GRAPH. . 1 2 5 3 4 Does this mean we are looking at a dependence cluster (or. . MDS)? 18

70. 43% 19

70. 43% 19

DAGSTUHL SEMINAR BEYOND PROGRAM SLICING Hypothesis 1: short program slices have fewer faults Hypothesis

DAGSTUHL SEMINAR BEYOND PROGRAM SLICING Hypothesis 1: short program slices have fewer faults Hypothesis 2: code common to many program slices has fewer faults Hypothesis 3: cliff faces in dependence clusters indicate faults 20

21

21

ONGOING WORK Complete implementation of the tool Mapping Source Code Constructs to Clusters Combining

ONGOING WORK Complete implementation of the tool Mapping Source Code Constructs to Clusters Combining Cluster – Larger Clusters Longitudinal study Faults Metrics 22