Synthesis of the Optimal 4-bit Reversible Circuits Dmitri Maslov (spkr) University of Waterloo Waterloo, ON, Canada Oleg GolubitskySean Falconer Stanford.

Slides:



Advertisements
Similar presentations
Trends in Memory Computing. Changes in memory technology Once upon a time, computers could not store very much data. The first electronic memory storage.
Advertisements

The Assembly Language Level
Realization of Incompletely Specified Reversible Functions Manjith Kumar Ying Wang Natalie Metzger Bala Iyer Marek Perkowski Portland Quantum Logic Group.
©Silberschatz, Korth and Sudarshan12.1Database System Concepts Chapter 12: Indexing and Hashing Basic Concepts Ordered Indices B+-Tree Index Files B-Tree.
Algorithms Today we will look at: what we mean by efficiency in programs why efficiency matters what causes programs to be inefficient? will one algorithm.
I/O-Algorithms Lars Arge January 31, Lars Arge I/O-algorithms 2 Random Access Machine Model Standard theoretical model of computation: –Infinite.
Distributed Computations
A Transformation Based Algorithm for Reversible Logic Synthesis D. Michael Miller Dmitri Maslov Gerhard W. Dueck Design Automation Conference, 2003.
DARPA Scalable Simplification of Reversible Circuits Vivek Shende, Aditya Prasad, Igor Markov, and John Hayes The Univ. of Michigan, EECS.
Quantum Computation and Error Correction Ali Soleimani.
Reversible Circuit Synthesis Vivek Shende & Aditya Prasad.
Classical and Quantum Circuit Synthesis An Algorithmic Approach.
Using Secondary Storage Effectively In most studies of algorithms, one assumes the "RAM model“: –The data is in main memory, –Access to any item of data.
1 External Sorting for Query Processing Yanlei Diao UMass Amherst Feb 27, 2007 Slides Courtesy of R. Ramakrishnan and J. Gehrke.
An Arbitrary Two-qubit Computation in 23 Elementary Gates or Less Stephen S. Bullock and Igor L. Markov University of Michigan Departments of Mathematics.
Distributed Computations MapReduce
Quantum Counters Smita Krishnaswamy Igor L. Markov John P. Hayes.
assumes basic arithmetic
Buying a Laptop. 3 Main Components The 3 main components to consider when buying a laptop or computer are Processor – The Bigger the Ghz the faster the.
Digital Graphics and Computers. Hardware and Software Working with graphic images requires suitable hardware and software to produce the best results.
Tutorial 6 Memory Management
DIGITAL COMPONENTS By Sohaib.
HOW TO SOLVE IT? Algorithms. An Algorithm An algorithm is any well-defined (computational) procedure that takes some value, or set of values, as input.
Introduction to Hardware. What is binary? We use the decimal (base 10) number system Binary is the base 2 number system Ten different numbers are used.
1. Memory Manager 2 Memory Management In an environment that supports dynamic memory allocation, the memory manager must keep a record of the usage of.
1 Cost Metrics for Reversible and Quantum Logic Synthesis Dmitri Maslov 1 D. Michael Miller 2 1 Dept. of ECE, McGill University 2 Dept. of CS, University.
COMPUTER HARDWARE Computer hardware is the physical construction of the computer system, the areas we can touch. The hardware is the construction inside.
Efficient Minimal Perfect Hash Language Models David Guthrie, Mark Hepple, Wei Liu University of Sheffield.
Data Structures & Algorithms and The Internet: A different way of thinking.
Optimal Client-Server Assignment for Internet Distributed Systems.
The Four Parts of a Computer. Definition of a Computer A computer is an electronic device used to process data, converting the data into information that.
OBJECTIVES  Explain why a computer represents data in the form of binary  Explain the terms related to data storage: bit, byte, character, word  Calculate.
MapReduce M/R slides adapted from those of Jeff Dean’s.
Modern Navigation Thomas Herring
Inside your computer. Hardware Review Motherboard Processor / CPU Bus Bios chip Memory Hard drive Video Card Sound Card Monitor/printer Ports.
COMPUTER HARDWARE Computer hardware is the physical construction of the computer system, the areas we can touch. The hardware is the construction inside.
Hashing Sections 10.2 – 10.3 CS 302 Dr. George Bebis.
March 23 & 28, Hashing. 2 What is Hashing? A Hash function is a function h(K) which transforms a key K into an address. Hashing is like indexing.
The Evolution Of Personal Home Computers 1980-Current TRS 80 Model 4P By Joshua Brutzkus.
1.00 Computer Basics 1.01 Classify computer component. 1 Primary sources of information and images: GCFLearnFree.org, Microsoft Digital Learning E-Learning.
Physical Database Design Purpose- translate the logical description of data into the technical specifications for storing and retrieving data Goal - create.
Computer Systems. Bits Computers represent information as patterns of bits A bit (binary digit) is either 0 or 1 –binary  “two states” true and false,
1 CSCD 326 Data Structures I Hashing. 2 Hashing Background Goal: provide a constant time complexity method of searching for stored data The best traditional.
1 Lecture 4 Post-Graduate Students Advanced Programming (Introduction to MATLAB) Code: ENG 505 Dr. Basheer M. Nasef Computers & Systems Dept.
Know what a computer is used for Understand the difference between hardware and software Be able to describe the way that data is stored in a computer.
University of Michigan Electrical Engineering and Computer Science 1 Cost Sensitive Modulo Scheduling in a Loop Accelerator Synthesis System Kevin Fan,
Unit C-Hardware & Software1 GNVQ Foundation Unit C Bits & Bytes.
 System Requirements are the prerequisites needed in order for a software or any other resources to execute efficiently.  Most software defines two.
Onlinedeeneislam.blogspot.com1 Design and Analysis of Algorithms Slide # 1 Download From
Computer Performance. Hard Drive - HDD Stores your files, programs, and information. If it gets full, you can’t save any more. Measured in bytes (KB,
State Representation of State Space Searching Alan Tam Siu Lung
Introduction to Hardware. What is binary? We use the decimal (base 10) number system Binary is the base 2 number system Ten different numbers are used.
On the Ability of Graph Coloring Heuristics to Find Substructures in Social Networks David Chalupa By, Tejaswini Nallagatla.
 Input - A device, such as a keyboard, used to enter information into a computer  Output - Electronic or electromechanical equipment connected to.
Operating Systems, Winter Semester 2011 Practical Session 9, Memory 1.
BDD-based Synthesis of Reversible Logic for Large Functions Robert Wille Rolf Drechsler DAC’09 Presenter: Meng-yen Li.
1 5. Abstract Data Structures & Algorithms 5.6 Algorithm Evaluation.
Trends in Memory Computing.
UBUNTU INSTALLATION
Mohammad Gh. Alfailakawi, Imtiaz Ahmad, Suha Hamdan
Introduction to Algorithms
Review Graph Directed Graph Undirected Graph Sub-Graph
Fredkin/Toffoli Templates for Reversible Logic Synthesis
Advanced Associative Structures
Objective of This Course
Introduction to Quantum logic (2)
Introduction to Hardware
Logical Computer System
Specifications Clean & Match
Computer Science. The CPU The CPU is made up of 3 main parts : Cache ALU Control Unit.
Presentation transcript:

Synthesis of the Optimal 4-bit Reversible Circuits Dmitri Maslov (spkr) University of Waterloo Waterloo, ON, Canada Oleg GolubitskySean Falconer Stanford University Stanford, CA Google Inc. Waterloo, ON, Canada

Basic Definitions NOT CNOT Toffoli-4 Toffoli Reversible circuit is a string of gates. Reversible n- bit function is a permutation of 2 n elements. page 1/15

Problem Synthesize optimal 4-bit reversible circuits, i.e., containing minimal number of gates. Complexity -- There are 16!=20,922,789,888,000 reversible functions. -- There 32 gates. -- An average optimal circuit requires gates. :: 20,922,789,888,000 * log 2 32 * bits > 100 TB. Murphy, David. "Western Digital Launches World-First 2TB Hard Drive". PC World. Retrieved page 2/15

Importance Library for physicists interested in performing a small experiment, but having very limited control over their system. page 3/15 Indispensable for peep-hole optimization methods. Peep- hole optimizations are an important part of any modern compiler. Mathematical curiosity. Computing the value of Shannon’s complexity function. L(3)=8, L(4)=[14,17], L(5)=?

Solution Rough complexity analysis -- space: -- time: Denote 16!=N (formally, N:=2 n !). Next, reduce these complexity figures to something manageable. page 4/15

Solution Rough complexity analysis -- space: -- time: Synthesize and save only halves of all optimal circuits. An optimal circuit for any function may be found by searching for both of its halves. Optimization 1 page 5/15

Solution Rough complexity analysis -- space: -- time: soft Store optimal halves in a hash table. Optimization 2 Actual complexity is closer to -- space: -- time: soft page 6/15

Solution Simultaneous input/output relabeling does not change optimality of a circuit. Thus, we store a single (canonical--- binary string with least lexicographic order) representative. Optimization 3 In practice, there are almost 24=4! different relabelings, reducing the storage complexity by a factor of almost 24, and helping to reduce runtime. page 7/15

Solution If an optimal circuit is found for a function f, an optimal circuit for the inverse function, f -1, can be obtained by reversing the optimal circuit for f. Optimization 4 In practice, random f frequently differs from f -1 resulting in the reduction of storage requirement by an additional factor of almost 2, and helping to further reduce the runtime. page 8/15

Performance k789 Size Memory usage256 MB2 GB32 GB Load factor Parameters of the linear hash table storing canonical representatives. Using a high performance server with 16 AMD Opteron 2300 MHz processors, 64 GB RAM, and Seagate Barracuda ES2 SCSI 7200 RPM HDD running Linux it took 10,549 seconds (under 3 hours) to synthesize all optimal circuits with up to 9 gates. page 9/15

Performance SizeFunctions 1417, ,371, ,110, ,051, , ,861 85, Synthesis of 10,000,000 random functions (Fisher-Yates shuffle over Mersenne twister random number generator) took 104, seconds (about 29 hours) of user time with the maximal memory usage of GB. Loading optimal circuits with up to 9 gates into RAM took 1111 seconds. On average, it took only seconds to synthesize an optimal circuit. A 5400-RPM HDD access time may be expected to be on the order of 0.01— 0.02 seconds. page 10/15

Performance Distribution of the number of functions requiring a circuit of a specified size (gate count). page 11/15

Performance Distribution of the number of linear functions requiring a circuit of a specified size (gate count). It took under 2 seconds to synthesize all these circuits. page 12/15 SizeFunctions , , , , ,182 46, WA: Total: 322,560

Performance page 13/15

Future directions Larger circuits -- There are 80 transformations resulting from the application of all possible Toffoli-type gates on 5 bits *(log 2 80)/5!/2 ~ 7.1 billion bits, fits into RAM memory =12. Meaning, it is reasonable to expect that extending the search for optimal 4-bit reversible circuits will allow to find optimal 5-bit reversible circuits with up to 12 gates. page 14/15

Future directions Optimal circuits using other cost metrics This search can be easily extended to account for other cost metrics: Weighted gate count optimal circuits---organize breadth first search such that a gate with cost G is assigned to a circuit of cost C at the iteration number G+C. Depth optimal circuits---choose a different set of elementary transformations, e.g., circuit NOT(a)CNOT(b,c) is now an elementary transformation. Depth optimal weighted gate circuits---combine previous two modifications. page 15/15

END Questions?

2 10 != page __/__ Classically: 2 10 !/(Lifespan_of_universe_in_Planck_time_units * Estimated_number_of_atoms) ~ universes!

Work in progress Synthesize all optimal 4-bit circuits -- Store circuits with up to 9 gates as we do it now. -- Store a bit vector (~250 GB) for canonical representatives of circuits with 10, 11, 12, 13, and 14 gates, one at a time. -- Use a minimal number of uploads/downloads of parts of each of such vectors into RAM. page __/__