using Reverse Domination Bao Le, Hratch Mangassarian, Brian Keng, - - PowerPoint PPT Presentation

โ–ถ
using reverse domination
SMART_READER_LITE
LIVE PREVIEW

using Reverse Domination Bao Le, Hratch Mangassarian, Brian Keng, - - PowerPoint PPT Presentation

Propelling SAT-based Debugging using Reverse Domination Bao Le, Hratch Mangassarian, Brian Keng, Andreas Veneris University of Toronto Outline SAT-based Design Debugging Introduction Motivation and Previous Work Dominators and


slide-1
SLIDE 1

Propelling SAT-based Debugging using Reverse Domination

University of Toronto Bao Le, Hratch Mangassarian, Brian Keng, Andreas Veneris

slide-2
SLIDE 2

Outline

  • SAT-based Design Debugging
  • Motivation and Previous Work

Introduction

  • Dominators and Reverse Dominators
  • Non-Solution Implications from Reverse

Domination Relationships Non-Solution Implications

  • SAT Branching Scheme
  • Non-Solution Detection

SAT Branching Scheme for Early Non-Solution Learning

  • Experimental Results

Results and Final Remarks

slide-3
SLIDE 3

Outline

  • SAT-based Design Debugging
  • Domination Relationships

Introduction

  • Dominators and Reverse Dominators
  • Non-Solution Implications from Reverse

Domination Relationships Non-Solution Implications

  • SAT Branching Scheme
  • Non-Solution Detection

SAT Branching Scheme for Early Non-Solution Learning

  • Experimental Results

Results and Final Remarks

slide-4
SLIDE 4

SAT-based Design Debugging

Given an erroneous circuit, a counter example of length ๐‘™, and error cardinality ๐‘‚:

๏‚จ Goal: Return shortlist of potentially buggy RTL blocks (solutions) ๏‚ค Blocks that can be modified to fix counter-example ๏‚จ Procedure:

๏‚ค An error-select variable ๐‘“๐‘— is inserted at the outputs of each RTL block. ๏ฎ ๐‘“๐‘— = 1 disconnects block from fan-ins, making its outputs free variables ๏ฎ ๐‘“๐‘— = 0 does not modify the circuit ๏‚ค Enhanced circuit is replicated ๐‘™ times using time-frame expansion. ๏‚ค Initial state, primary inputs and outputs are constrained to expected behavior of

counter-example.

๏‚ค Each satisfying assignment to ๐‘“ = {๐‘“1, โ€ฆ , ๐‘“๐‘œ} is a debugging solution ๏‚ค The SAT solver must find all such assignments to ๐‘“ using blocking clauses.

slide-5
SLIDE 5

SAT-based Design Debugging

๏‚จ Example:

g1 g2 b1 b2 b3 b4 x1 x2 x3 x4 g3 g4 y2 y1

slide-6
SLIDE 6

SAT-based Design Debugging

g1 g2 b1 b2 b3 b4 x1 x2 x3 x4 g3 g4 y2 y1 g1 g2 b1 b2 b3 b4 x1 x2 x3 x4 g3 g4 y1 Time-frame 1 Time-frame 2 1 1 1 1 1 1 1 y2 e1 e2 e1 e3 e4 e1 e4 e3 e2

SAT Solver returns ๐‘“4 = 1 for ๐‘‚ = 1; therefore, block ๐‘4 (i.e. gate ๐‘•3) is the bug.

slide-7
SLIDE 7

SAT-based Design Debugging

๏‚จ SAT-based Design Debugging ๏‚ค Fault diagnosis and logic debugging using Boolean Satisfiability

[Smith, Veneris, Ali, Viglas-TCAD2005]

๏‚จ Large designs, long counter-examples pose a scalability

challenge even to modern SAT solvers.

๏‚จ Our contributions: ๏‚ค On-the-fly discovery of implied non-solution blocks using

reverse domination

๏‚ค Goal is to prune the search space of design debugging

๏ฎ 1.7x speed up in SAT solving time.

slide-8
SLIDE 8

Outline

  • SAT-based Design Debugging
  • Motivation and Previous Work

Introduction

  • Dominators and Reverse Dominators
  • Non-Solution Implications from Reverse

Domination Relationships Non-Solution Implications

  • SAT Branching Scheme
  • Non-Solution Detection

SAT Branching Scheme for Early Non-Solution Learning

  • Experimental Results

Results and Final Remarks

slide-9
SLIDE 9

Outline

  • SAT-based Design Debugging
  • Motivation and Previous Work

Introduction

  • Dominators and Reverse Dominators
  • Non-Solution Implications from Reverse

Domination Relationships Non-Solution Implications

  • SAT Branching Scheme
  • Non-Solution Detection

SAT Branching Scheme for Early Non-Solution Learning

  • Experimental Results

Results and Final Remarks

slide-10
SLIDE 10

Dominators

๏‚จ Block ๐‘๐‘˜ is said to dominate block ๐‘๐‘— if any path from a node in

๐‘๐‘— to a primary output passes through a node in ๐‘๐‘˜.

b1

b2 b3 b4

slide-11
SLIDE 11

Dominators

๏‚จ Block ๐‘๐‘˜ is said to dominate block ๐‘๐‘— if any path from a node in

๐‘๐‘— to a primary output passes through a node in ๐‘๐‘˜.

b1 b2 b3 b4

slide-12
SLIDE 12

Dominators

๏‚จ Block ๐‘๐‘˜ is said to dominate block ๐‘๐‘— if any path from a node in

๐‘๐‘— to a primary output passes through a node in ๐‘๐‘˜.

b1 b2 b3 b4

b4 dominates b1

๏‚จ Theorem [Mangassarian, Veneris, Smith, Safarpour-ICCADโ€™11]: ๏‚ค If ๐‘๐‘˜ is a solution block, and ๐‘๐‘— dominates ๐‘๐‘˜, then ๐‘๐‘— is also a solution

block

slide-13
SLIDE 13

Dominators

๏‚จ Block ๐‘๐‘˜ is said to dominate block ๐‘๐‘— if any path from a node in

๐‘๐‘— to a primary output passes through a node in ๐‘๐‘˜.

b1 b2 b3 b4

No block dominates b2

slide-14
SLIDE 14

Reverse Dominators

๏‚จ A block ๐‘๐‘— is a reverse dominator of block ๐‘๐‘˜ if and

  • nly if ๐‘๐‘˜ dominates ๐‘๐‘—, denotes ๐‘๐‘—๐ธ-1๐‘๐‘˜.

Block b1 is a reverse dominator of b4

b1

b2 b3 b4

slide-15
SLIDE 15

Non-solution Implications

๏‚จ Theorem: ๏‚ค If ๐‘๐‘˜ is a non-solution block, and ๐‘๐‘—๐ธ-1๐‘๐‘˜, then ๐‘๐‘— is also a non-solution

block Definition: Block ๐‘๐‘— is a non-solution block iff ๐‘“๐‘— = 0 for all satisfying assignments.

If b4 is a non-solution block, b1 is also a non-solution block. But how would we know that b4 is a non-solution in the first place?

b1

b2 b3 b4

slide-16
SLIDE 16

Outline

  • SAT-based Design Debugging
  • Motivation and Previous Work

Introduction

  • Dominators and Reverse Dominators
  • Non-Solution Implications from Reverse

Domination Relationships Non-Solution Implications

  • SAT Branching Scheme
  • Non-Solution Detection

SAT Branching Scheme for Early Non-Solution Learning

  • Experimental Results

Results and Final Remarks

slide-17
SLIDE 17

Outline

  • SAT-based Design Debugging
  • Motivation and Previous Work

Introduction

  • Dominators and Reverse Dominators
  • Non-Solution Implications from Reverse

Domination Relationships Non-Solution Implications

  • SAT Branching Scheme
  • Non-Solution Detection

SAT Branching Scheme for Early Non-Solution Learning

  • Experimental Results

Results and Final Remarks

slide-18
SLIDE 18

SAT Branching Scheme

๏‚จ A decision tree in a SAT solver gives the order in which

variables are decided upon. Consider the decision tree:

UNSAT

r r = 1

slide-19
SLIDE 19

SAT Branching Scheme

๏‚จ A decision tree in a SAT solver gives the order in which

variables are decided upon. Consider the decision tree:

UNSAT

r r = 1 r = 0 for all satisfying assignment

slide-20
SLIDE 20

SAT Branching Scheme

๏‚จ A decision tree in a SAT solver gives the order in which

variables are decided upon. Consider the decision tree:

UNSAT

r r = 1 r = 0 for all satisfying assignment

If after analyzing r = 1, SAT Solver returns no satisfying assignment and starts analyzing r = 0, clearly r = 0 for any satisfying assignment (if one exists).

slide-21
SLIDE 21

Non-Solution Detection

๏‚จ What we have so far: UNSAT

r r = 1

slide-22
SLIDE 22

Non-Solution Detection

๏‚จ What about:

UNSAT

ei ei = 1

ei = 0 for all satisfying assignments bi is a non-solution block.

slide-23
SLIDE 23

Non-Solution Detection

๏‚จ In general, we can incrementally detect non-solution blocks. For

example:

UNSAT

e1 e1 = 1

UNSAT UNSAT

e2 ei ei = 1

  • ๐‘“2, โ€ฆ ๐‘“๐‘— are also detected as non-solution blocks even though they

are not the root of the decision tree. e2 = 1

๐‘“1 = 0 for all satisfying assignment ๐‘“๐‘— = 0 for all satisfying assignment ๐‘“2 = 0 for all satisfying assignment

slide-24
SLIDE 24

Non-Solution Detection

๏‚จ Deciding on the error-select variables first forces the

SAT solver to learn about them faster

๏‚จ Pruning using non-solution implications can have a

stronger effect

slide-25
SLIDE 25

Algorithm Overview

๏‚จ Rearrange the order such that error select variables

๐‘“ appear first in the decision tree.

๏‚จ Extract learned non-solution blocks by inspecting the

decision tree.

๏‚จ Use reverse domination relationships to learn more

non-solution blocks. Add a blocking clause for each implied non-solution block.

slide-26
SLIDE 26

Outline

  • SAT-based Design Debugging
  • Motivation and Previous Work

Introduction

  • Dominators and Reverse Dominators
  • Non-Solution Implications from Reverse

Domination Relationships Non-Solution Implications

  • SAT Branching Scheme
  • Non-Solution Detection

SAT Branching Scheme for Early Non-Solution Learning

  • Experimental Results

Results and Final Remarks

slide-27
SLIDE 27

Outline

  • SAT-based Design Debugging
  • Motivation and Previous Work

Introduction

  • Dominators and Reverse Dominators
  • Non-Solution Implications from Reverse

Domination Relationships Non-Solution Implications

  • SAT Branching Scheme
  • Non-Solution Detection

SAT Branching Scheme for Early Non-Solution Learning

  • Experimental Results

Results and Final Remarks

slide-28
SLIDE 28

Experimental Results

๏‚จ Platform: i5 3.1Ghz, 8GB memory, 2 hour time-limit. ๏‚จ Benchmarks: Eight Opencores circuits and three industrial

  • designs. For each, several bugs are injected to generate

debugging instances.

๏‚จ We modified MiniSAT 2.2.0 to implement our techniques. ๏‚ค MiniSAT vs. dbgSAT ๏‚จ We compare to a state-of-the-art SAT-based debugger with

solution implications [Mangassarian, etal-ICCADโ€™11]:

slide-29
SLIDE 29

Experimental Results

Instance # of Nodes MiniSAT(s) Non-Sol(%) dbgSAT(s) Imp(x) rsdecoder1 13543 T/O 74% 6955.90 โˆž rsdecoder2 13564 33.35 58% 20.46 1.6x usb_funct1 35158 53.17 21% 45.46 1.2x usb_funct2 35350 134.46 32% 117.83 1.1x wb_dma1 191386 123.89 28% 97.26 1.3x wb_dma2 299838 49.14 41% 36.90 1.3x wb_dma3 299862 304.18 61% 182.09 1.7x vga1 89412 434.81 13% 172.51 2.5x vga2 89402 106.98 8.1% 147.95 0.7x ucrc_par 1056 7.97 0% 3.94 2.0x mem_ctrl1 48006 12.53 17% 24.67 0.5x mem_ctrl2 48006 11.76 0% 4.78 2.5x mips7891 30711 22.08 6% 13.51 1.6x

On average, 28% of non- Solution blocks are implied For rsdecoder, while MiniSAT times out, we are able to solve it in under two hours. For certain cases, only rearranging the order of variables improves the performance

slide-30
SLIDE 30

Experimental Results

Instance # of Nodes MiniSAT Non-Sol(%) dbgSAT Imp(x)

  • pen_sparc1

58399 48.45 44% 33.42 1.4x

  • pen_sparc2

64915 44.11 50% 39.39 1.1x Design1-1 499325 53.40 0.1% 25.08 2.1x Design1-2 499705 72.54 25% 38.27 1.9x Design1-3 499696 39.63 1% 31.69 1.3x Design1-4 499705 100.89 29% 45.69 2.2x Design1-5 499705 73.72 29% 27.04 2.7x Design2-1 45632 18.47 10% 14.59 1.3x Design2-2 203706 7.38 0.7% 4.23 1.7x Design2-3 2082 0.13 53% 0.08 1.6x Design3-1 5454 3.03 51% 2.07 1.6x Design3-2 2333 0.083 44% 0.07 1.2x Average 1.68x

23/25 cases show improvement

slide-31
SLIDE 31

Experimental Results

By pruning the search space for each SAT call, each SAT call now takes less time and hence we are able to find more solutions faster.

slide-32
SLIDE 32

Conclusions

๏‚จ Summary ๏‚ค Non-solution implications using reverse domination to prune the

search space of design debugging SAT calls.

๏‚ค A SAT branching scheme to detect non-solution early and enhance

non-solution implications.

๏‚จ Future Work ๏‚ค Study the error-select variablesโ€™ order to maximize the implications

(solution + non-solution).

๏‚ค Extend the work to higher cardinality.

slide-33
SLIDE 33

Questions/Discussions