Automated Software Transplantation ( ISSTA 2015 ) Earl T. Mark - - PowerPoint PPT Presentation

automated software transplantation
SMART_READER_LITE
LIVE PREVIEW

Automated Software Transplantation ( ISSTA 2015 ) Earl T. Mark - - PowerPoint PPT Presentation

Automated Software Transplantation ( ISSTA 2015 ) Earl T. Mark Yue Alexandru Justyna Barr Harman Jia Marginean Petke CREST, University College London Justyna Petke Automated Software Transplantation Genetic Improvement of Software


slide-1
SLIDE 1

Justyna Petke — Automated Software Transplantation

Earl T. Barr Mark Harman Yue Jia Justyna Petke Alexandru Marginean CREST, University College London

Automated Software Transplantation

( ISSTA 2015 )

slide-2
SLIDE 2

Justyna Petke — Automated Software Transplantation

Memory Execution Time Energy New Feature Functionality Improvement

Error

Genetic Improvement of Software

geneticimprovementofsoftware.com

Functional Properties Non-functional Properties

slide-3
SLIDE 3

Justyna Petke — Automated Software Transplantation

slide-4
SLIDE 4

Justyna Petke — Automated Software Transplantation

Alexandru Marginean CREST, University College London

Automated Software Transplantation

( ISSTA 2015 )

Thank you

slide-5
SLIDE 5

Justyna Petke — Automated Software Transplantation

Video Player Start from scratch

Why Autotransplantation?

Check open source repositories Why not handle H.264? ~100 players

slide-6
SLIDE 6

Justyna Petke — Automated Software Transplantation

Automated Software Transplantation

Host Donor Organ Organ ENTRY

V

Organ Test Suite

Manual Work:

Organ Entry Organ’s Test Suite Implantation Point

slide-7
SLIDE 7

Justyna Petke — Automated Software Transplantation

μTrans

Host Donor Stage 1: Static Analysis Host Beneficiary Stage 2: Genetic Programming Stage 3: Organ Implantation Organ Test Suite

Implantation Point Organ Entry

slide-8
SLIDE 8

Justyna Petke — Automated Software Transplantation

Stage 1 — Static Analysis

Donor OE ENTRY

Vein Organ

Matching Table Dependency Graph Host Implantation Point Stm: x = 10; -> Decl: int x; Donor: int X -> Host: int A, B, C

slide-9
SLIDE 9

Justyna Petke — Automated Software Transplantation

Stage 2 — GP

S1 S2 S3 S4 S5 … Sn

Matching Table V3H V4H

Donor Variable ID Host Variable ID (set)

V1D V2D … V1H V2H V5H Individual

Var Matching Stateme nts

V1D V1H V2D V4H S1 S7 S73 M1: M2: … Genetic Programming

fitness(i) = (

1 3(1 + |T Xi| |T |

+ |T Pi|

|T | )

i ∈ IC i / ∈ IC

Weak Proxies: Does it execute test cases without crashing? Does it compile? Strong Proxies: Does it produce the correct output?

slide-10
SLIDE 10

Justyna Petke — Automated Software Transplantation

Host Organ Donor RQ1: Do we break the initial functionality? RQ2: Have we really added new functionality? RQ3: How about the computational effort? RQ4: Is autotransplantation useful?

Research Questions

Regression Tests Acceptance Tests

slide-11
SLIDE 11

Justyna Petke — Automated Software Transplantation

Research Questions

RQ1: Do we break the initial functionality? RQ3: How about the computational effort? RQ4: Is autotransplantation useful? RQ2: Have we really added new functionality? Empirical Study 15 Transplantations 300 Runs 5 Donors 3 Hosts Case Study: H.264 Encoding Transplantation

slide-12
SLIDE 12

Justyna Petke — Automated Software Transplantation

Validation

Regression Tests Augmented Regression Tests Donor Acceptance Tests Acceptance Tests Manual Validation RQ1.1 RQ1.2 RQ2 Host Beneficiary

slide-13
SLIDE 13

Justyna Petke — Automated Software Transplantation

Subjects Type Size KLOC Reg. Tests Organ Tests Idct Donor 2.3

  • 3-5

Mytar Donor 0.4

  • 4

Cflow Donor 25

  • 6-20

Webserver Donor 1.7

  • 3

TuxCrypt Donor 2.7

  • 4-5

Pidgin Host 363 88

  • Cflow

Host 25 21

  • SoX

Host 43 157

  • Case Study

x264 Donor 63

  • 5

VLC Host 422 27

  • Subjects

Minimal size: 0.4k Max size: 422k Average Donor:16k Average Host: 213k

C
  • n
s i s t e n t * C
  • m
p l e t e * W e l l D
  • c
u m e n t e d * E a s y t
  • R
e u s e *

*

E v a l u a t e d

* I S S T A *

A r t i f a c t

* A E C

slide-14
SLIDE 14

Justyna Petke — Automated Software Transplantation

Experimental Methodology and Setup

μSCALPEL Host Implantation Point Donor OE Organ Test Suite

Host Beneficiary

Implantation Point Organ

64 bit Ubuntu 14.10 16 GB RAM 8 threads

slide-15
SLIDE 15

Justyna Petke — Automated Software Transplantation Alexandru Marginean — Automated Software Transplantation Donor Host All Passed Regression Regression++ Acceptance Idct Pidgin 16 20 17 16 Mytar Pidgin 16 20 18 20 Web Pidgin 20 18 Cflow Pidgin 15 20 15 16 Tux Pidgin 15 20 17 16 Idct Cflow 16 17 16 16 Mytar Cflow 17 17 17 20 Web Cflow 17 Cflow Cflow 20 20 20 20 Tux Cflow 14 15 14 16 Idct SoX 15 18 17 16 Mytar SoX 17 17 17 20 Web SoX 17 Cflow SoX 14 16 15 14 Tux SoX 13 13 13 14 TOTAL 188/300 233/300 196/300 256/300 RQ1.1 RQ1.2 RQ2

Empirical Study RQ1,2

C
  • n
s i s t e n t * C
  • m
p l e t e * W e l l D
  • c
u m e n t e d * E a s y t
  • R
e u s e *

*

E v a l u a t e d

* I S S T A *

A r t i f a c t

* A E C

All Passed 188/300 Regression 233/300 RQ1.1 Regression++ 196/300 RQ1.2 Acceptance 256/300 RQ2

slide-16
SLIDE 16

Justyna Petke — Automated Software Transplantation Execution Time (minutes) Donor Host Idct Pidgin 5 7 97 Mytar Pidgin 3 1 65 Web Pidgin 8 5 160 Cflow Pidgin 58 16 1151 Tux Pidgin 29 10 574 Idct Cflow 3 5 59 Mytar Cflow 3 1 53 Web Cflow 5 2 102 Cflow Cflow 44 9 872 Tux Cflow 31 11 623 Idct SoX 12 17 233 Mytar SoX 3 1 60 Web SoX 7 3 132 Cflow SoX 89 53 74 Tux SoX 34 13 94 Total

Empirical Study RQ3

Average 334 (min)

  • Std. Dev.

Total 72 (hours) 10 (Average)

C
  • n
s i s t e n t * C
  • m
p l e t e * W e l l D
  • c
u m e n t e d * E a s y t
  • R
e u s e *

*

E v a l u a t e d

* I S S T A *

A r t i f a c t

* A E C

slide-17
SLIDE 17

Justyna Petke — Automated Software Transplantation

Case Study RQ4

Transplant Time & Test Suites Time (hours) Regression Regression++ Acceptance H.264 26 100% 100% 100%

C
  • n
s i s t e n t * C
  • m
p l e t e * W e l l D
  • c
u m e n t e d * E a s y t
  • R
e u s e *

*

E v a l u a t e d

* I S S T A *

A r t i f a c t

* A E C

VLC H264

within 26 hours performed a task that took developers an avg of 20 days of elapsed time

slide-18
SLIDE 18

Justyna Petke — Automated Software Transplantation

slide-19
SLIDE 19

Justyna Petke — Automated Software Transplantation

Automated Software Transplantation

H D O ENTRY

V

Organ’s Test Suite

Manual Work:

Organ Entry Organ’s Test Suite Implantation Point

Alexandru Marginean — Automated Software Transplantation

μTrans

Host Donor Stage 1: Static Analysis Host Beneficiary Stage 2: Genetic Programming Stage 3: Organ Implantation Organ’s Test Suite

Validation

Alexandru Marginean — Automated Software Transplantation

Regression Tests Augmented Regression Tests Host Beneficiary Donor Acceptance Tests Acceptance Tests Manual Validation RQ1.a RQ1.b RQ2 Subjects Type Size KLOC Reg. Tests Organ Test Suite Idct Donor 2.3

  • 3-5

Mytar Donor 0.4

  • 4

Cflow Donor 25

  • 6-20

Webserver Donor 1.7

  • 3

TuxCrypt Donor 2.7

  • 4-5

Pidgin Host 363 88

  • Cflow

Host 25 21

  • SoX

Host 43 157

  • Case Study

x264 Donor 63

  • 5

VLC Host 422 27

  • Subjects
  • Minimal size:

0.4k;

  • Max size: 422k;
  • Average Donor:

16k;

  • Average Host:

213k;

C
  • n
s i s t e n t * C
  • m
p l e t e * W e l l D
  • c
u m e n t e d * E a s y t
  • R
e u s e * *

E v a l u a t e d

* I S S T A *

A r t i f a c t

* A E C
slide-20
SLIDE 20

Justyna Petke — Automated Software Transplantation

Memory GECCO 2015 Execution Time EuroGP 2014 Energy GECCO 2015 New Feature ISSTA 2015 Functionality Improvement TEVC 2015

Error

Genetic Improvement of Software

geneticimprovementofsoftware.com

Functional Properties Non-functional Properties

slide-21
SLIDE 21

Justyna Petke — Automated Software Transplantation

Genetic Improvement

More information : crest.cs.ucl.ac.uk/cow/50/

50th CREST Open Workshop 30 & 31 Jan 2017

slide-22
SLIDE 22

Justyna Petke — Automated Software Transplantation

geneticimprovementofsoftware.com