test ii n.
Skip this Video
Loading SlideShow in 5 Seconds..
Test II 精读 PowerPoint Presentation
Download Presentation
Test II 精读

Loading in 2 Seconds...

  share
play fullscreen
1 / 18
Download Presentation

Test II 精读 - PowerPoint PPT Presentation

nathan
153 Views
Download Presentation

Test II 精读

- - - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript

  1. Test II 精读 廖钧

  2. Paper

  3. Background • Termination analysis • Determine whether a program will terminate • Correctness of an algorithm depends on termination • Test termination properties of programs • Can a test suite for a program be used profitably for constructing termination proofs?

  4. Problem • Generate a novel termination prover based on information derived from tests. (Called TpT) • What kind of program is TpT’s input? • How to define termination?

  5. Preliminaries • Define while programs • Input of TpT • Loop: L = while B do S over variables() • A program with loops

  6. Preliminaries • Define termination • Loop bound • () -> () • Linear expression = • If each loop has a loop bound, then termination

  7. Preliminaries • Generate log data from test inputs • Assume • Get two matrices • Machine learning Candidate loop bound Free invariant

  8. Preliminaries • Check loop bound • Add free_invariant and assert into program • Free_invariant can be ignored

  9. Algorithm • Input • While program • Test-Suite • Output • Loop bound

  10. Algorithm • Inner phase • Generate matrices A and C • “Off-the-self” quadratic programming to learn loop bounds • Fail: does not have integral coeffcients

  11. Algorithm • Validate phase • “Off-the-self checker” • Return counterexample(new tests) • Use new tests to next iteration

  12. Algorithm • Optimize • Round ??? • If a value between N-0.1 and N+0.1, round to N • Celling for positive and floor for negative • Can only make the bound looser??? • Example • [1.9,1,-1,0.95,0.24] -> [2,1,-1,1,1] • 2a + b – c + d + e • Partition • Loop does not have single bound • Different behavior for different inputs

  13. Evaluation • Micro-Benchmarks for termination • Oct: OCTANAL distribution • E.g. heapsort and bubblesort • Driver: Windows device drivers • Code fragments from them • Poly: POLYRANK distribution • http://www.eecs.qmul.ac.uk/~aziem/esop/polyrank/

  14. Evaluation • Windows Device Drivers • SDV-RP toolkit • Claim that other may have fail to prove termination

  15. Evaluation • They claim that • Prove 15% more benchmark • Inner phase of TpT is very efficient • Other technologies may have fail to prove termination

  16. Summary • Process • Prove more termination • Effeciency Prove termination while program and test suites Generate input for forming model Machine learning

  17. My opinion • All about algorithm • Many formulae • So many black box • Off-the-self, state-of-the-art????WTF

  18. Thank you