Saleem Sabbagh & Najeeb Darawshy Supervisors: Mony Orbach, Technion & Ilia Averbouch, IBM Started at: Spring 2012 Duration: Semester.

Slides:



Advertisements
Similar presentations
Hybrid BDD and All-SAT Method for Model Checking Orna Grumberg Joint work with Assaf Schuster and Avi Yadgar Technion – Israel Institute of Technology.
Advertisements

Order encoding x i ↔ (X ≥ i)(X = 3) = [1,1,1,0,0] Problem (hard) Problem (hard) Solution CNF Encoding Finite Domain Problem Solving Model Constraint Model.
Dr. Rabie A. Ramadan Al-Azhar University Lecture 3
Saleem Sabbagh & Najeeb Darawshy Supervisors: Mony Orbach, Technion & Ilia Averbouch, IBM Started at: Winter 2012 Duration: Semester.
Dana Nau: Lecture slides for Automated Planning Licensed under the Creative Commons Attribution-NonCommercial-ShareAlike License:
UIUC CS 497: Section EA Lecture #2 Reasoning in Artificial Intelligence Professor: Eyal Amir Spring Semester 2004.
Proofs from SAT Solvers Yeting Ge ACSys NYU Nov
Max Cut Problem Daniel Natapov.
Experiment 2 PIC Program Execution & Built-In Self-Test.
Counting the bits Analysis of Algorithms Will it run on a larger problem? When will it fail?
Daniel Kroening and Ofer Strichman 1 Decision Procedures An Algorithmic Point of View SAT.
IBM Labs in Haifa © 2005 IBM Corporation Adaptive Application of SAT Solving Techniques Ohad Shacham and Karen Yorav Presented by Sharon Barner.
Conditional statements and Boolean expressions. The if-statement in Java (1) The if-statement is a conditional statement The statement is executed only.
EKT 221 : Digital 2 ASM.
Methods for SAT- a Survey Robert Glaubius CSCE 976 May 6, 2002.
Heuristics for Efficient SAT Solving As implemented in GRASP, Chaff and GSAT.
08/1 Foundations of AI 8. Satisfiability and Model Construction Davis-Putnam, Phase Transitions, GSAT Wolfram Burgard and Bernhard Nebel.
Ryan Kinworthy 2/26/20031 Chapter 7- Local Search part 1 Ryan Kinworthy CSCE Advanced Constraint Processing.
CSCE 121, Sec 200, 507, 508 Fall 2010 Prof. Jennifer L. Welch.
State-of-the-art in SAT solvers
Technion 1 Generating minimum transitivity constraints in P-time for deciding Equality Logic Ofer Strichman and Mirron Rozanov Technion, Haifa, Israel.
Quantum Search Heuristics: Tad Hogg’s Perspective George Viamontes February 4, 2002.
SAT Algorithms in EDA Applications Mukul R. Prasad Dept. of Electrical Engineering & Computer Sciences University of California-Berkeley EE219B Seminar.
Read Only Memory (ROM) Number of words Size of word A block diagram of a ROM consisting of k inputs and n outputs is shown below. The inputs provide the.
SAT Solver Math Foundations of Computer Science. 2 Boolean Expressions  A Boolean expression is a Boolean function  Any Boolean function can be written.
Compressed Instruction Cache Prepared By: Nicholas Meloche, David Lautenschlager, and Prashanth Janardanan Team Lugnuts.
Final Exam Review Instructor : Yuan Long CSC2010 Introduction to Computer Science Apr. 23, 2013.
ECE 101 An Introduction to Information Technology Digital Logic.
Matrix Multiplication on FPGA Final presentation One semester – winter 2014/15 By : Dana Abergel and Alex Fonariov Supervisor : Mony Orbach High Speed.
10/9/2015COSC , Lecture 51 Real-Time Systems, COSC , Lecture 5 Stefan Andrei.
1 Agenda Modeling problems in Propositional Logic SAT basics Decision heuristics Non-chronological Backtracking Learning with Conflict Clauses SAT and.
One Flip per Clock Cycle Martin Henz, Edgar Tan, Roland Yap.
1 The LPSAT Engine and its Application to Metric Planning Steve Wolfman University of Washington CS&E Advisor: Dan Weld.
Power-Aware RAM Processing for FPGAs December 9, 2005 Power-aware RAM Processing for FPGA Embedded Memory Blocks Russell Tessier University of Massachusetts.
Week 10Complexity of Algorithms1 Hard Computational Problems Some computational problems are hard Despite a numerous attempts we do not know any efficient.
FPGA PLB Evaluation using Quantified Boolean Satisfiability Andrew C. Ling M.A.Sc. Candidate University of Toronto Deshanand P. Singh Ph.D. Altera Corporation.
Explorations in Artificial Intelligence Prof. Carla P. Gomes Module Logic Representations.
jFuzz – Java based Whitebox Fuzzing
Fitting a Function to the Difficulty of Boolean Formulas Greg Dennis NMM Final Project.
First-Order Logic and Inductive Logic Programming.
Review of Propositional Logic Syntax
Tommy Messelis * Stefaan Haspeslagh Patrick De Causmaecker *
February 22-25, 2010 Designers Work Less with Quality Formal Equivalence Checking by Orly Cohen, Moran Gordon, Michael Lifshits, Alexander Nadel, and Vadim.
Finding Models for Blocked 3-SAT Problems in Linear Time by Systematical Refinement of a Sub- Model Gábor Kusper Eszterházy Károly.
272: Software Engineering Fall 2012 Instructor: Tevfik Bultan Lecture 9: Test Generation from Models.
Optimality FPGA Technology Mapping: A Study of Optimality Andrew C. Ling M.A.Sc. Candidate University of Toronto Deshanand P. Singh Ph.D. Altera Corporation.
1 Fundamentals of Computer Science Combinational Circuits.
Saleem Sabbagh & Najeeb Darawshy Supervisors: Mony Orbach, Technion & Ilia Averbouch, IBM Started at: Spring 2012 Duration: Semester.
Heuristics for Efficient SAT Solving As implemented in GRASP, Chaff and GSAT.
Satisfiability and SAT Solvers CS 270 Math Foundations of CS Jeremy Johnson.
Custom Computing Machines for the Set Covering Problem Paper Written By: Christian Plessl and Marco Platzner Swiss Federal Institute of Technology, 2002.
SAT Solving As implemented in - DPLL solvers: GRASP, Chaff and
Control units In the last lecture, we introduced the basic structure of a control unit, and translated our assembly instructions into a binary representation.
SAT Encodings for Sudoku Bug Catching in 2006 Fall Sep. 26, 2006 Gi-Hwon Kwon.
Saleem Sabbagh & Najeeb Darawshy Supervisors: Mony Orbach, Technion & Ilia Averbouch, IBM Started at: Winter 2012 Duration: Semester.
Knowledge Repn. & Reasoning Lecture #9: Propositional Logic UIUC CS 498: Section EA Professor: Eyal Amir Fall Semester 2005.
Dana Nau: Lecture slides for Automated Planning Licensed under the Creative Commons Attribution-NonCommercial-ShareAlike License:
1 Intro to AI Local Search. 2 Intro to AI Local search and optimization Local search: –use single current state & move to neighboring states Idea: –start.
Heuristics for Efficient SAT Solving As implemented in GRASP, Chaff and GSAT.
Class Exercise 1B.
Hybrid BDD and All-SAT Method for Model Checking
Michael Codish, Michael Frank, Amit Metodi
Introduction to MiniSAT
Heuristics for Efficient SAT Solving
SAT-Based Area Recovery in Technology Mapping
VLSI Programming 2IMN35 Lab 1 Questionnaire
13 Digital Logic Circuits.
Control units In the last lecture, we introduced the basic structure of a control unit, and translated our assembly instructions into a binary representation.
Lecture 23 NP-Hard Problems
Presentation transcript:

Saleem Sabbagh & Najeeb Darawshy Supervisors: Mony Orbach, Technion & Ilia Averbouch, IBM Started at: Spring 2012 Duration: Semester

 What is SAT  Reminder - description and goals  Memory Technique  GSAT  Flow diagram  Controller  Circuit diagram  Resources usage and times  Runtimes  Conclusions  Notes

 Boolean Satisfiability Problem  Given a Boolean propositional formula, does there exist assignment of values such that the formula becomes true?  e.g., given the formula f=(x1 ˅ x3 ˅ -x4) ˄ (x4) ˄ (x2 ˅ -x3) are there values of x1,x2,x3,x4 that produce f=‘1’

*Clock frequency is 50M [Hz]

 In the first project this was our “what’s next” slide.  Two approaches  Improving compilation times by:  Understanding Altera compilation algorithms to enable faster SAT-specific FPGA ready files.  Smart use of memory on FPGA to implement SAT.  Improving runtimes by designing smart sat solver instead of inefficient LFSR random generator

 Two memory entities  SAT is represented by ROM.  Based on the DE2’s M4K built in memory blocks.  We convert the DIMACS CNF SAT instance into a memory description file and put it in the memory.  The ROM address = variable’s number.  content of the address = representation of the clauses which the variable appears in.  Each clause is represented by a shift register that will save the number of variables that satisfy each clause according to the current assignment.

c Example CNF format file c p cnf Example.cnf DEPTH = 4 ; % Variables % WIDTH = 6 ; % Clauses*2 % ADDRESS_RADIX = DEC; DATA_RADIX = BIN; CONTENT BEGIN 0 : ; 1 : ; 2 : ; 3 : ; END; Example.mif For assignment 1101 Clause number 1’s shift register status will be:

GSAT(int Maxtries, int Variables) { For (i=1 to Maxtries) { V = a random instantiation of the variables; For (i = 1 to Variables) { p = variable – who’s negation yields largest increase in number of satisfied clauses; V = V with p flipped; } if (F(V) is true) return V; } *Take random variable in case of equality.

 Initialize random assignment  Total satisfied clauses = 20 (out of 21)  Flip each variable and see how many added satisfied clauses:  Variable 1 : 0 new satisfied clauses.  Variable 2 : -1 new satisfied clauses.  Variable 3 : -2 new satisfied clauses.  Variable 4 : 0 new satisfied clauses.  Variable 5 : 1 new satisfied clauses.  Maximum = variable 5, flip it.  Assignment =  Total satisfied clauses = 21 (out of 21) => SUCCESS!

New CNF instance Memory Description File FPGAResults Convert In System Memory Content Editor SignalTap Reset

Init Reset circuit Random Assignment Clauses Init Var by var run and save to shiftreg Flipping Flip variable value Sum satisfied clauses Advance var Maximum Increase attempts if max <= 0 Flip max var and save to shiftregFinish Output satisfying assignment var == total vars satisfied == total clauses attempts == allowed

 LEs: 20,562/33,216 (62%)  M4Ks: 102/105 (97%)  Registers: 8,355/34,593 (24%)  Compilation time: 4:12 minutes.

*Clock frequency is 12.5M [Hz] (compared to 50M [Hz])

 Runtime was reduced DRASTICALLY.  Due to GSAT implementation.  From data appears to be polynomial increase of 4 th order.  We expect the more the number of variables is the polynomial relationship will decrease, again due to a much harder locality problem.  Random runtimes for same instance due to initial random assignment.  Two degrees of freedom: total attempts, random bit.  can improve runtimes.  Compilation time = NO compilation time.  Use Quartus’s built-in In Memory Content Editor to change the SAT for all variables sizes.

 Tried two approaches for clauses representation in memory:  Encoded Clause Representation  For each variable, only clauses which the variable appears in are included in the memory and are represented by binary encode of the clause number.  Less memory usage, more LEs, alters sat, only 14 clauses per variable  special design (decoders, special software support).  Direct Clause Representation  All the clauses are included in the memory each is represented by two bits to indicate if the variables appears in it and what value satisfies it.  More memory usage, less LEs, doesn’t restrict design.  We have developed two Java based applications  SAT converter from cnf to mif format according to our clause representation.  SAT satisfying value asserter.  Currently our design supports 5-sat (5 variables per clause) only, can be increased with minimal effort.

 Support maximum of 200 variables and 860 clauses due to the limit of the M4Ks (of the DE2).  408Kb of memory was used.  To measure runtimes we have used benchmark SAT instances, as well as cpp based satisfiable/unsatisfiable SAT generator used in official SAT competitions which was used for runtimes analysis.  We have measured between 4 to 6 instances of SAT with the same variable number and took the average.  The standard deviation of the runtimes was of the same order of the average, meaning that the results vary a lot between instances due to the local minimum problem.

 Follow us please.

 Thank you!  Questions?