Baldwinian learning utilizing genetic and heuristic algorithms for logic synthesis and minimization of incompletely specified data with Generalized Reed–Muller (AND–EXOR) forms

Baldwinian learning utilizing genetic and heuristic algorithms for logic synthesis and minimization of incompletely specified data with Generalized Reed–Muller (AND–EXOR) forms

Journal of Systems Architecture 47 (2001) 477±489 www.elsevier.com/locate/sysarc Baldwinian learning utilizing genetic and heuristic algorithms for ...

126KB Sizes 0 Downloads 14 Views

Journal of Systems Architecture 47 (2001) 477±489

www.elsevier.com/locate/sysarc

Baldwinian learning utilizing genetic and heuristic algorithms for logic synthesis and minimization of incompletely speci®ed data with Generalized Reed±Muller (AND±EXOR) forms Karen M. Dill *, Marek A. Perkowski Department of Electrical Engineering, Portland State University, Portland, OR 97207, USA Accepted 12 November 2000

Abstract This research applies a new heuristic combined with a genetic algorithm (GA) to the task of logic minimization for incompletely speci®ed data, with both single and multi-outputs, using the Generalized Reed±Muller (GRM) equation form. The GRM equation type is a canonical expression of the Exclusive-Or Sum-of-Products (ESOPs) type, in which for every subset of input variables there exists not more than one term with arbitrary polarities of all variables. This AND±EXOR implementation has been shown to be economical, generally requiring fewer gates and connections than that of AND±OR logic. GRM logic is also highly testable, making it desirable for FPGA designs. The minimization results of this new algorithm tested on a number of binary benchmarks are given. This minimization algorithm utilizes a GA with a two-level ®tness calculation, which combines human-designed heuristics with the evolutionary process, employing Baldwinian learning. In this algorithm, ®rst a pure GA creates certain constraints for the selection of chromosomes, creating only genotypes (polarity vectors). The phenotypes (GRMs) are then learned in the environment and contribute to the GA ®tness (which is the total number of terms of the best GRM for each output), providing indirect feedback as to the quality of the genotypes (polarity vectors) but the genotype chromosomes (polarity vectors) remain unchanged. In this process, the improvement in genotype chromosomes (polarity vectors) is the product of the evolutionary processes from the GA only. The environmental learning is achieved using a human-designed GRM minimization heuristic. As much previous research has presented the merit of AND±EXOR logic for its high density and testability, this research is the ®rst application of the GRM (a canonical AND±EXOR form) to the minimization of incompletely speci®ed data. Ó 2001 Published by Elsevier Science B.V. Keywords: Incompletely speci®ed generalized Reed±Muller forms; AND±EXOR forms; Logic synthesis and minimization; Baldwinian learning; Genetic algorithms

1. Introduction

* Corresponding author. Tel.: +503-725-5411; fax: +503-7254882. E-mail addresses: [email protected] (K.M. Dill), [email protected] (M.A. Perkowski).

Natural systems are extremely well adapted to their environments. In nature the structure of all organisms has been designed to provide the capability of solving a multitude of complex problems for both survival and growth, through instinctual, experiential, and intellectual means.

1383-7621/01/$ - see front matter Ó 2001 Published by Elsevier Science B.V. PII: S 1 3 8 3 - 7 6 2 1 ( 0 0 ) 0 0 0 6 0 - 6

478

K.M. Dill, M.A. Perkowski / Journal of Systems Architecture 47 (2001) 477±489

Over the millennia, it is these capabilities that have proven an e€ective method of sustaining the existence and propagation of natural organisms. Even as environmental conditions change, it is the continuous adaptation of natural organisms adjusting to their environment, through evolutionary processes, which sustains life. As nature itself has proven its development of robust system design, the biologically inspired evolutionary process is here applied to the minimization of incompletely speci®ed digital hardware circuits in the Generalized Reed±Muller (GRM) form. Genetic Algorithm (GA) [15] techniques provide a means for applying the theory of evolution within an arti®cial system. The GA is a system that evolves problem parameters directly. Through a process of emergent intelligence, the GA formulates engineering solutions based on an accumulated knowledge of the problem and the merit of potential solutions. In recent years, the GA, as a machine learning technique, has been successfully applied to a wide range of engineering problems. However, with the realization of computer-designed algorithms, only limited research to date has applied these concepts to digital logic [11,13]. Our past experience has shown the GA application to logic minimization to have limitations of size, computation time, and solution optimality [7,8]. In comparison, several decades of research have contributed to the current human understanding and ecient implementation of systems for logic design and minimization. Most of the current human-aided design tools utilize AND±OR design implementations for both logic synthesis and minimization, for simplicity, readily available minimization tools, and because of historical reasons in the development of digital systems. However, since AND and EXOR components exist in most ASIC libraries, they can be employed either in a CLB of an FPGA or in a full custom VLSI design. While not as widely utilized for integrated circuit design as the AND±OR Sum-of-Product (SOP) logic, the Exclusive-Or Sum-of-Product (ESOP) form (the most general, unrestricted AND± EXOR logic form) compares favorably [40]:

Functions realized by such circuits (ESOPs) can have fewer gates, fewer connections, and take up less area in VLSI and especially, FPGA realizations. They are also easily testable [14,28]. It was shown, both theoretically and experimentally [31,33±35,38] that ESOPs have on average smaller numbers of terms for both `worst case' and `average' Boolean functions. It was also shown that ESOPs and all their sub-families have their counterparts in logic with multi-valued inputs. . . Additionally, recently two-level AND±EXOR realizations (ESOPs) have even been proposed for the combinational logic portions of ®nite state machines, as they have proven more testable and can yield less area than two-level AND±OR implementations [21]. Thus, it can be concluded that the AND±EXOR implementation is in many applications superior to the AND±OR logic, for both its testable and economical characteristics [21,36,37,39]. AND±EXOR logic already serves as a good alternative basis for FPGA designs, by achieving denser logic than AND±OR implementations. Because any function of a certain number of inputs can be realized in a logic block of an FPGA, for example, the costs of realizing a 5-input OR and a 5-input EXOR in Xilinx technology are the same. (Note that FPGAs may use logic look-up tables to realize AND±EXOR combinations in multi-level circuits, thus avoiding the architectural design restrictions imposed by other AND±OR-based logical devices [44]. However, this is at the expense of not employing the two-level, AND±EXOR physical hardware implementation, which realizes the high testability quality of this class.) AND±EXOR logic has also been used in full custom VLSI chip design of data path logic, arithmetic circuits, controllers with embedded counters and adders, and easily testable circuits. For several industrial applications, specialized AND±EXOR tools serve for such designs as preprocessors for standard factorization and decomposition in EDA tools from commercial companies. It is interesting to note that binary AND± EXOR logic represents a special case of Galois Field logic [1,41], GF…k†, where the radix k ˆ 2.

K.M. Dill, M.A. Perkowski / Journal of Systems Architecture 47 (2001) 477±489

Thus, Galois logics can be viewed as a generalization or expansion of Boolean logic, as Galois Field mathematical operations are applicable for multi-valued logic values, over any ®nite ®eld. Hence, in this manner, the minimization technique presented herein may be expanded, in the future, for a multi-valued logic hardware or data mining application. Further, as two-level AND±EXOR logic is the most highly testable of all digital logics [26], it is a good candidate for engineering design [12,20,21,27,29,32]. A testing method for ESOP circuits, which include the GRM, FPRM, and PPRM forms, is given by Kalay et al. [20] as: . . .a simple, universal test set which detects all single stuck-at faults in the internal lines and the primary inputs/outputs of the realization. . . (the) circuit realization requires only two extra inputs for controllability and one extra output for observability. The cardinality of our test set for an n input circuit is …n ‡ 6† . . . This test set can also be very successfully applied to Built-in Self-Test (BIST) applications. Further, Kalay et al. [19] have also devised a twolevel design and minimal-universal test set for the more general Galois Field SOP (GFSOP) form GF(k r ). The GFSOP is analogous to the ESOP as the most general functional representation of its type. Thus, for both the binary and multi-valued logic cases, it is evident that the two-level AND± EXOR logic family is highly testable with a very limited number of test vectors. Concluding, currently basic research and CAD tool application to the various AND±EXOR forms is increasingly at the forefront of the logical research and development frontier, both in industry and academia. The AND±EXOR form has been developed into a complete hierarchy of Reed±Muller (RM) expansions, using the Shannon, Positive Davio, and Negative Davio Expansions [37]. This hierarchy is described with logic equation forms, trees, and decision diagrams [37]. The GRM form is the focus of this research. The GRM logic is a canonical expression (exhibiting a regular structure) which is a subset of the ESOP expression, in which

479

for every subset of input variables there exists at most one term with any polarities of variables. In other words, each term in the GRM is unique in both variable name and polarity. It is interesting to note that often GRM forms may produce results with the number of terms very close to that of exact minimum ESOPs [3,25,39,46]. GRM forms are also even more easily testable than the generalpurpose ESOPs [36]. Herein an original automated technique of GRM form logic minimization for incompletely speci®ed data is developed with evolutionary processes. But in this method, a multi-strategic approach is taken. Human expertise is combined with the genetic search mechanism, for the development of an ecient problem-solving expert system. The goal of using the GA for GRM minimization is simply to aid the human-designed logic minimization heuristic. Other research has shown the GRM equation form to be dicult to minimize for the case of completely speci®ed data, both using heuristics [4,5] and GAs [7,8]. However, an application combining heuristics and GAs has not been previously applied to the GRM minimization problem. Also there have been no applications of the GRM equation form for the minimization of incompletely speci®ed data. Hence, in summary, several concepts have contributed to this research. The GRM is a powerful form, for its canonical, economical (compact logic), and high testability properties. Several industrial companies are already using AND±EXOR logic (together with AND±OR logic). Thus, AND±EXOR logic should be applied not only to completely speci®ed data, but to incompletely speci®ed data as well, which is the more typical case for real-world applications. Logic synthesis and minimization with this form can be easily combined with the natural, evolutionary mechanisms employed by the simple (pure) GA. Together, all of these approaches are utilized by a logic minimization heuristic, which is based on human experience. This methodology is implemented with software and is the ®rst application of the GRM form for the synthesis and minimization of incompletely speci®ed data. This approach is applicable for traditional computer-

480

K.M. Dill, M.A. Perkowski / Journal of Systems Architecture 47 (2001) 477±489

automated digital design and synthesis, as well as o€-line Evolvable Hardware. But, it is also notable that, as the minimization technique is equally applicable for a large number of don't cares (strongly unspeci®ed data) and multi-valued logic, characteristic of real-world machine learning problems, it is also applicable to software applications such as Knowledge Discovery/Data Mining.

2. The GA with Baldwinian learning In this research, a GA with Baldwinian learning was employed. As di€erent types of hybrid GAs, a distinction must be made to better de®ne the di€erences between Lamarckian and Baldwinian learning. In the Lamarckian model, a local heuristic search is utilized to modify and improve the chromosomes [17]. ``Lamarckian evolution requires an inverse mapping from phenotype and environment to genotype'' [42]. In contrast, for Baldwinian learning the ``local search improves chromosomes' ®tnesses but the chromosomes themselves are not modi®ed'' [17]. Herein the GA with Baldwinian learning is adapted and illustrated for the problem of minimization of incompletely speci®ed data with GRM forms (see Fig. 1). In this problem context, a pure GA is utilized to generate polarity strings. Following the gen-

Fig. 1. GA with Baldwinian learning utilized for the minimization of incompletely speci®ed data with GRM forms.

eration of a population of polarity strings, several iterations using the heuristic logic minimization method construct some of the possible GRMs (which have the polarity described by their associated polarity string) that represent the incompletely speci®ed data set. (Note that for a completely speci®ed function there is a one-to-one mapping of polarity (genotype) to GRM form (phenotype). In contrast, for an incompletely speci®ed function, there are many GRM forms corresponding to a given polarity. Thus, the algorithm heuristically selects one of many phenotypes corresponding to a given genotype.) The best results (i.e., the GRM equations with the fewest terms) from several iterations of the heuristic method are then selected. The cost function is the total number of terms, in each of the best GRMs, for each of the multi-outputs. The summation of the cost functions from each of the outputs (counting duplicate terms only once), is then associated with the polarity as the ®tness value, for the GA. Following this assignment of ®tness values from the logic minimization heuristic, the GA proceeds with the standard evolutionary process. In the framework of the GA utilizing Baldwinian learning, the components of the application may be analyzed. The polarity strings can be considered genotypes, as they are essentially constraints for the selection of explicit GRM solutions (phenotypes). The GRM phenotypes, which describe the complete problem solution, are learned in the environment. In this model, the learned behavior is simulated by the applicationspeci®c heuristic. Herein, the iGRMMIN minimization algorithm acts as a local heuristic search mechanism, deriving optimum GRMs given polarity vectors. Because the ®tness of the GA is related to the total ®nal cost of the multi-output circuit, the GA parameters of the polarity vector chromosome (genotype) and the ®tness are indirectly linked to each of the GRMs (phenotypes). In the environment of the iGRMMIN minimization algorithm that creates new minimal GRMs, the polarity vector chromosomes in the GA are unaltered. Then through the evolutionary process of the pure GA, new polarity vectors are created.

K.M. Dill, M.A. Perkowski / Journal of Systems Architecture 47 (2001) 477±489

3. Example of minimization for incompletely speci®ed data with GRM forms An example of the minimization heuristic for incompletely speci®ed data with GRM forms is ®rst given, followed by the complete algorithm description in Section 4. The principle of this algorithm is to consecutively select product groups, denoted as gi , and exor them with the function. Thus, recursively using the logic principle, f ˆ gi  ftail ) ftail ˆ gi  f , the realization of the function f is obtained as an exor of all selected gi product groups. This is a greedy method of solving the even±odd covering problem that works well when a good heuristic for selecting consecutive product groups (gi ) is provided. Herein, the heuristic selection of cubes is based on minimizing the cost function. In this application, the additional constraint also exists that all product groups gi are consistent with the polarity vector (genotype). Example 1. Given is the 2-output function (f1 …a; b; c†; f2 …a; b; c†) from Fig. 2. Assuming a minterm representation of the ON/ OFF set and a term-wise polarity …1; …a0 †; …b†; …c0 †; …a; b†; …a; c†; …b; c0 †; …a; b; c0 ††, a table (Table 1) is created with coecients (cubes) as columns and minterms of functions f1 and f2 as rows. (a) Building the table (Table 1): The ON/OFF (minterms) column is initialized to the function output values given in the truth table, where the `abc' values indicate the function input states necessary to produce these speci®ed outputs. The term-wise polarity set (from the GA) indicates the particular polarities chosen and these coecients head the rows. Assuming a ˆ 1, the costs of the coecients are calculated as: cost ˆ …N1 N0 † ‡ 1=…N1 ‡ N0 †.

Fig. 2. The 2-output function (f1 …a; b; c†; f2 …a; b; c†) used in Example 1.

481

(b) Iteration process: 1. Select the cube (column) of highest cost, indicating the best grouping for cube selection. In the case of cubes with equal cost, the selection among these cubes is random. (Note that larger problems often have many choices with equal costs.) Include the cube as an exor term in the function. (If the cube has been consecutively selected two times (cancelled-out) within the current iteration, then a new cube is randomly selected from the set of all cubes. This allows for the algorithm to jump out of a repetitive selection (loop) of the local maximum within the iteration, and thus continue working towards a solution, while adding some diversity.) 2. In the table (Table 1), complement the elements of the ON/OFF (minterms) set that are associated with the selected cube. (These are the ON/OFF (minterms) set elements in the rows where a 1 exists in the column of the selected cube.) This corresponds to exoring this cube with the data and appending it to the solution. 3. If all terms in the ON/OFF (minterms) set are 0, then the function construction is completed. Otherwise, calculate the new costs and repeat steps 1±3. (c) Repetition and new polarity vectors: For a given polarity vector (i.e., 1; a0 ; b; c0 ; ab; ac; bc0 ; abc0 ), n iterations for each function (f1 and f2 ) are conducted. (For this research n ˆ 3.) If the total function cost (number of terms in both functions) has not improved, then a new polarity vector is selected by the GA. The iterative heuristic minimization process then begins again. 4. The iGRMMIN algorithm for approximate minimizations of the Generalized Reed±Muller form for incompletely speci®ed data Few authors [16,22,30,43,48] have considered the problem of Positive-polarity Reed±Muller (PPRM) form minimization for single-output incompletely speci®ed functions. However, with the exception of Zilic and Vranesic [48], the algorithms are very inecient for functions that have a large number of don't cares, as the algorithm complexity increases with the amount of unspeci®ed data.

482

K.M. Dill, M.A. Perkowski / Journal of Systems Architecture 47 (2001) 477±489

Table 1 Building the table for Example 1a ON/OFF F1 1!0 1!0 1 ! 0! 1! 0 0 ! 1! 0 0

abc 000 011 110

a0

1 1 1 1

010 111

Iterations 1±3 Cost-1 Cost-2 Cost-3 Cost-4

1 1 1

1.20 )0.80 )2.80 )2.80

c0

b

1.33 1.33 )0.66 )2.66

1 1 1 1 0.25 )1.75 )1.75 )1.75

ab

ac

bc0

abc0

1

1

1 1 1

1.33 )0.66 )0.66 )0.66

1 1 0.50 )1.50 )1.50 0.50

1 0.00 0.00 0.00 0.00

1

0.50 )1.50 0.50 0.50

2.00 0.00 0.00 2.00

f1 ˆ abc0  a0  bc0  abc0 ˆ a0  bc0 F2 1!0 1!0 0 0 ! 1! 0 0 Iterations 1±3 Cost-1 Cost-2

010 111 000 110 101

1 1

)0.80 )2.80

1 1

0.50 )1.50

1 1 1

1.33 )0.66

1 1 1

)0.66 )0.66

1 1

0.50 0.50

1 1 0.50 )1.50

1 1

1

0.50 0.50

0.00 2.00

f2 ˆ b  abc0 a Note that it can be observed that by exoring the selected cubes in the functions f1 and f2 , with that of the K-maps given in Fig. 2 (respectively), that the resulting minterms are zero.

Moreover, all these algorithms cannot be adapted to the GRM form, which is quite di€erent from that of the PPRM form. For completely speci®ed data, the GRM equation form has been proven dicult to minimize, as no exact minimization method (other than a nearly exhaustive search) has been devised. (Similarly, Miller and Thomson [24] give an exhaustive search algorithm for the FPRM form.) But exhaustive search methods are time consuming, making an e€ective, and high-quality, approximate minimization method very attractive. (Previously, GAs have been utilized for FPRM optimization [10,23].) Several attempts were made by the authors [6±8,47] to develop a purely evolutionary (i.e., GA with no human-designed heuristics) approach to the minimization of GRM forms. As no application-speci®c knowledge was incorporated for [6±8] the results were remarkable as they

compared favorably with that of the heuristic algorithms designed by human experts [4,5]. But this was only the case for small, completely speci®ed functions with a single output. Debnath and Sasao [4,5] developed a more widely applicable heuristic method (capable of handling functions with a large number of variables and multi-outputs), but this technique was also applicable only to completely speci®ed functions. The minimization of incompletely speci®ed functions is well known to be more dicult than the minimization of the completely speci®ed form. For instance, Chang and Falkowski [2] developed a FPRM minimization algorithm for a small percentage of don't cares. On the other hand, Zakrevskij [45]developed a minimization algorithm for FPRMs that is ecient only for a high percentage of don't cares. Similarly, it is most dicult to minimize incompletely speci®ed functions with

K.M. Dill, M.A. Perkowski / Journal of Systems Architecture 47 (2001) 477±489

ESOPs that have 5±95% don't cares. It can thus be predicted, for GRMs also, that the minimization of few (<5%) or very many (>95%) don't cares is easier than the case of a medium amount of don't cares. The iGRMMIN minimization algorithm performs well for all categories. As may be recalled, while more restrictive than the ESOP expression, the GRM equation form incorporates the Fixed-polarity Reed±Muller (FPRM) and PPRM forms. The GRM is a canonical expression that allows complete freedom as to the polarity of each term, but there is at most one product term for every subset of variables. The GRM expansion of an n-variable function is shown as: f ˆ a0  a1 X1      an Xn  a12 X1 X2  a13 X1 X3      an…n

1† Xn Xn 1

     a12n X1 X2    Xn ;

where X can be expressed either as a positive literal xi or a negative literal x0i ; X ˆ …X  d†; d ˆ 0=1 for positive/negative polarity ;ai ˆ coecient of Xi , and can be 0 or 1. The goal of the iGRMMIN minimization algorithm [47] is to develop a method for minimizing the number of terms in the GRM expression. The minimization search space, examining the di€erent polarities, is very large, since for a binary (completely speci®ed) n-variable function there are n2n 1 literals and 2n2^…n 1† polarities. The incompletely speci®ed case has the same number of literals and polarities, but minimization is more dicult and the problem must be viewed di€erently. This is because for a given polarity of GRM, there exists only one expression (form) for a completely speci®ed function, but many expressions for incompletely speci®ed functions. To calculate the quasi-minimum GRM form for a given polarity, the iGRMMIN minimization algorithm creates a table with all GRM coecients for this polarity as columns and all ON/ OFF minterms as rows. The cubes in various output functions are repeated as separate rows, one for each function. The set of the selected columns represents the exor realization of all the product terms for the output functions. ON minterms are marked as active by setting the value of ¯ag ON to 1. Minterms with ¯ag ON ˆ 0 are

483

treated as OFF-minterms. Initially the cells of the table are set to 0. Wherever a minterm matches a coecient, a 1 is set in a cell at the intersection of the minterm's row and coecient column in the table. The matching of a minterm and a coecient (product of literals, represented as a cube) indicates a relation in which all literals from the coecient have the same polarity as their corresponding literals in the minterm. For instance, coecient b0 c matches minterm 001X 1 ˆ a0 b0 ce. For all columns that have at least one 1 in some of the rows, the cost is calculated. The column Cbest with the highest Column_Cost is selected. The coecient cube Coef …Cbest † corresponding to Cbest is next exored from these output functions f j , j ˆ 1; . . . ; r for which exoring the minterm corresponding to this column with function f j would bring an improvement in its estimated cost. This is done based on the numbers of 1's and 0's in f j . If there are no better groups available, any matching cube is applied. The cost of the cube selected for the solution is calculated across all output functions f i . The Column Cost…columns † is de®ned as Column Cost…columns † ˆ a …N1 N0 † ‡ 1=…N1 ‡ N0 †, where a is a weighting coecient and N1=0 indicates the number of 1's or 0's. Note that this formula was chosen as a heuristic means for selecting ecient groups. The …N1 N0 † portion assigns a better cost to cubes with many 1's and few 0's. Whereas following the selection of these groups, the selection of small groups is encouraged with the fractional portion of the Column_Cost formula. The a term serves as a balance between these two goals. Herein the even/odd covering problem is heuristically attacked, ®rst selecting the largest groups of 1's, then selecting smaller cubes for the remainder of the terms to be covered. This process aims to iteratively select the best groups, selecting cubes and then successively exoring them with the original function, to create more 0's (simpler functions) for the remaining necessary cover. The exoring operation converts some of the ON-minterms to OFF-minterms, and vice versa. This is done by activating and deactivating the ¯ags for each cube. Each ON-minterm covered by a Coef …Cbest † cube in the header of the selected column Cbest is converted to an OFF-minterm.

484

K.M. Dill, M.A. Perkowski / Journal of Systems Architecture 47 (2001) 477±489

Each OFF-minterm covered by a selected column is converted to an ON-minterm (¯ag ON is set to 1). All cubes selected for the output function f j , j ˆ 1; . . . ; r, are triggered for this function. It means that in the ®rst selection, the cube is recorded for this function (by triggering the respective bit from 0 to 1) and any next selection of the same cube triggers the respective bit in Coef_Set . An even number of selections means no selection and an odd number of selections means a single selection. For every new selected product group, the contents of the table's cells are modi®ed accordingly. The procedure is repeated until no more ON-minterms remain in the table. The cost of the solution_Coef_Set is calculated incrementally with the selection of new product groups. The iGRMMIN minimization algorithm performs the GRM minimization; it ®nds the Coef_Setv and fitnessv of the o€spring's polarity Polarityv and stores them together in the GRMtriplet. Details of the minimization algorithm are presented in the following. New polarities are generated by the GA. Algorithm iGRMMIN(Polarityv , ON/OFF sets of minterms) 1. Create a table with coecients of polarity as columns and all ON/OFF (minterms) cubes of the multi-output function ff1 ; . . . ; fr g as rows (repeated for each function in which they stand). Set all cells of the table to zeros. 2. New_ON_minterms :ˆ ON. solution_Coef_Set :ˆ 0. solution_cost(solution_Coef_Set) :ˆ 0. For every new minterm from New_ON_minterms mark with a value of 1 in the table every intersection of a column that matches this minterm. 3. For each column Ci that has at least one 1, calculate Column Cost…Ci †. 4. Select column Cbest with the highest value of Column_Cost. If several columns have equally high cost, Cbest , then select randomly from this set of columns. 5. Mark for Cbest those cubes in output functions f j (marked functions) that have the highest Column_Cost.

6. For each output function f j that includes a cube marked in step 5 do: f j :ˆ f j  Coef …Cbest †: The exoring creates sets New_ON_minterms and New_OFF_minterms. Activate and modify sets ON and OFF in the table accordingly. 7. Update the solution_Coef_Set by triggering the bit of cube Cbest in the marked output functions f j of the solution_Coef_Set. min cost :ˆ cost…solution Coef Set†: If the same cube is selected consecutively, randomly choose a new cube from the set of all cubes and goto step 3. (The probabilistic selection is done to avoid looping and also creates more diversity in the search.) 8. If there still exist some minterms with a value of 1 in the ON/OFF set goto step 3. 9. Iterate steps 2±8 for n iterations. 10. Return a GRM-triplet: …Coef Setv ; Polarityv ; fitnessv †.

5. Benchmarks A test suite was constructed utilizing MCNC, completely speci®ed, binary benchmarks. As no incompletely speci®ed benchmarks were readily available, the benchmarks were adapted for these purposes. Using a random selector, 25%, 50%, 75%, and 95% of the benchmark output data was changed to don't cares. These test ®les are available at www.ee.pdx.edu/polo/function/MCNC_incompletely_speci®ed.

6. Results For the iGRMMIN software, the initial GRM polarity is partially obtained from the CGRMIN program run on the completely speci®ed benchmark. (The CGRMIN program is restrictive, as it minimizes only FPRM logic equations. As the GRM form is less restrictive, the GRM equations should always be reduced to less than or equal the number of terms of an equivalent FPRM

Inputs

7 7 5 5 4 8 6 4 6 4 5 5

Benchmark

5x01 5x7 bw01 bw19 f21 f56 misex22 misex42 misex56 newcwp rd53 squar5

1 1 1 1 1 1 1 1 1 5 3 8

6 2 5 2 2 2 4 2 3 10 25 23

25% g2 g1 g1 g1 g1 g1 g1 g1 g1 g2 g5 g1

00:03:30.22 00:03:26.43 00:00:10.79 00:00:10.13 00:00:02.97 00:11:19.65 00:00:44.49 00:00:02.60 00:00:43.29 00:00:11.87 00:00:32.21 00:01:23.25

4 2 2 2 1 2 4 1 2 7 12 21

50% g1 g1 g4 g1 g1 g1 g2 g1 g1 g1 g1 g2

00:02:44.26 00:02:42.29 00:00:07.17 00:00:07.08 00:00:00.91 00:09:21.97 00:00:34.44 00:00:00.84 00:00:30.33 00:00:03.84 00:00:17.22 00:00:41.62

3 2 1 1 1 2 1 1 2 3 4 10

75%

Outputs Percentage don't cares (format: terms, generation, run-time (hh:mm:ss)

Table 2 iGRMMIN minimization results for benchmarks with varying amounts of don't cares, population size 50

g1 g1 g1 g1 g1 g1 g1 g1 g1 g1 g1 g1

00:00:58.32 00:01:05.96 00:00:00.91 00:00:00.99 00:00:00.20 00:05:35.27 00:00:01.76 00:00:00.14 00:00:03.08 00:00:00.48 00:00:02.26 00:00:06.41

2 1 1 1 1 2 1 1 1 2 2 5

95% g1 g1 g1 g1 g1 g1 g1 g1 g1 g4 g3 g2

00:00:02.01 00:00:01.77 00:00:00.16 00:00:00.14 00:00:00.07 00:00:16.90 00:00:00.47 00:00:00.15 00:00:00.49 00:00:00.16 00:00:00.35 00:00:00.80

K.M. Dill, M.A. Perkowski / Journal of Systems Architecture 47 (2001) 477±489 485

486

K.M. Dill, M.A. Perkowski / Journal of Systems Architecture 47 (2001) 477±489

equation.) The remainder of the initial polarity vector is speci®ed randomly. The GA produces all subsequent GRM polarities through the evolutionary process. In the iGRMMIN software implementation, a simple GA was executed, to act on the polarity strings, described as a vector string. The GA processes consisted of the three genetic operators: reproduction, crossover, and mutation. Reproduction was performed with Tournament Selection, crossover was performed at a rate of 0.6, and mutation was set at 0.001. For the multi-output benchmarks, the tests were conducted with a population size of 50, run for 5 generations. For the single-output benchmarks, the tests were conducted with a population size of 100, run for 20 generations. The larger benchmarks were also tested with a population of size 25. (The size of population and number of generations run were arbitrarily selected.) Finally, 10% of the starting population was `seeded' [6,18], with the CGRM (FPRM) representation obtained from the CGRMIN program run on the benchmark. This ensures

that the results are never worse than the starting data. As is common with GA applications run-times are long, due to the amount of data processing that occurs as the genetic operators are applied, and are also proportional to the population size. However, while testing with smaller population sizes is quicker, overall the results can be worse due to a lack of genetic diversity. (Humandesigned heuristics generally have much shorter run-times, but at the expense of longer software development time.) Also due to the nature of the GA, the minimization of large circuits ( >17 inputs and outputs combined) presents problems of both memory usage and excessive run-times, making it dicult to minimize large circuits. The iGRMMIN program was tested with the benchmark test suite described in Section 3, utilizing 25%, 50%, 75%, and 95% don't cares. The results of testing the software, over a test suite of benchmarks are given in Tables 2 and 3. The best results for the conducted tests are given and the experimental conditions are noted. Also when

Table 3 iGRMMIN minimization results over a number of benchmarksa Benchmark

Inputs

Outputs

Terms

Generation

Run-time

con175 con195 rd7375 rd7395 5xp175 5xp195 rd8475 rd8495 log8mod75 log8mod95 misex195 dc295 clip95 rd84275 rd84295 rd84475 rd84495 9sym95 sao2175 sao2195 misex6475 misex6495

7 7 7 7 7 7 8 8 8 8 8 8 9 8 8 8 8 9 10 10 10 10

2 2 3 3 10 10 4 4 5 5 7 7 5 1 1 1 1 1 1 1 1 1

10 4 20 4 56 11 79 9 88 13 15 9 19 19 3 9 2 2 7 1 1 1

g1 g1 g2 g1 g3 g1 g2 g1 g1 g1 g1 g2 g1 g2 g1 g1 g1 g1 g2 g1 g1 g1

00:01:09.15* 00:00:04.97 00:01:50.52* 00:00:06.59* 00:05:01.52* 00:00:26.75 00:20:30.71 00:00:36.16 00:30:12.22 00:01:08.73 00:04:08.00 00:00:24.55* 00:08:40.06 00:06:23.65 00:00:04.67* 00:03:08.79* 00:00:18.79 00:02:11.47* 01:53:55.23 00:15:39.01 00:53:55.89* 00:07:56.95

a

Note that a * indicates a population of size 25, otherwise the population is of size 50.

K.M. Dill, M.A. Perkowski / Journal of Systems Architecture 47 (2001) 477±489

equivalent results were obtained with di€erent population sizes, the test with the shortest runtime is given. The format lists the number of terms after minimization, the generation in which the results were obtained, and the run-time (hours:minutes:seconds). Tests were conducted using a Pentium II, 333 MHz, personal computer. Since there are no other GRM minimization software packages applicable to incompletely speci®ed data, no comparisons can be made in this regard. Comparison with FPRM and ESOP solutions can be found in [9]. 7. Conclusion Herein a GA utilizing Baldwinian learning, to incorporate both a human-designed logic heuristic and a pure GA, is applied to illustrate iGRMMIN, the ®rst algorithm that minimizes incompletely speci®ed data with GRM forms. As the AND±EXOR logic is generally more economical than AND±OR logic, requiring fewer logic gates and interconnections, it is often a good alternative form for logic design. (Recall that modern EDA tools ®rst decompose the circuit to AND±OR and AND±EXOR realizable blocks). The GRM forms were selected for this research since they are a good trade-o€ between cost and high testability [21]. The software implementation of the iGRMMIN minimization algorithm was tested over a number of benchmarks. Since incompletely speci®ed benchmarks are not available, they were constructed. Starting with completely speci®ed MCNC benchmarks, a given percentage of outputs were randomly selected for changing to don't cares. These new benchmarks are available from our research group's web site at www.ee.pdx.edu/polo/ function/MCNC_incompletely_speci®ed. Minimization test results are given for benchmarks containing 25%, 50%, 75%, and 95% don't cares. Since no other minimization software for incompletely speci®ed data with GRMs exists, no comparisons are made. The future extension of this new algorithm to multi-valued logic, using Galois Field algebra [1,41], is possible. Additional methods for the im-

487

provement of the heuristic generation of GRMs are presented in [9].

References [1] J.R. Batisda, Field Extensions and Galois Theory, Cambridge University Press, New York, 1984. [2] C.H. Chang, B.J. Falkowski, Adaptive exact optimisation of minimally testable FPRM expansions, IEE Proc. ± Comput. Digit. Tech. 145 (6) (1998) 385. [3] M. Cohn, Inconsistent canonical forms of switching functions, IRE Trans. Electron. Comput. 11 (1962) 284±285. [4] D. Debnath, T. Sasao, GRMIN: a heuristic simpli®cation algorithm for generalized Reed±Muller expressions, in: IFIP WG 10.5, Proceedings of the Workshop on Applications of the Reed±Muller Expansion in Circuit Design, 27±29 August 1995, Makuhari, Chiba, Japan. [5] D. Debnath, T. Sasao, GRMIN2: a heuristic simpli®cation algorithm for generalised Reed±Muller expressions, IEE Proc. ± Comput. Digit. Tech. 143 (6) (1996). [6] K.M. Dill, Growing digital circuits: logic synthesis and minimization with genetic operators, M.S. Thesis, Department of Electrical and Computer Engineering, Oregon State University, June 1997. [7] K.M. Dill, M.A. Perkowski, Evolutionary minimization of generalized Reed±Muller forms, in: Proceedings of the International Conference on Computational Intelligence and Multimedia 1998 (ICCIMA'98), Monash University, Churchill, Vic, Australia, 9±11 February 1998. [8] K.M. Dill, M.A. Perkowski, Minimization of generalized Reed±Muller forms with a genetic algorithm, in: Proceedings of Genetic Programming '97, July 1997, Stanford University, CA. [9] K.M. Dill, Ph.D. Dissertation, Department of Electrical Engineering, Portland State University, forthcoming. [10] R. Drechsler, B. Becker, N. Gockel, A genetic algorithm for minimization of ®xed polarity Reed±Muller expressions, in: Proceedings of the International Conference on Arti®cial Neural Networks and Genetic Algorithms, Ales, 1995, pp. 392±395. [11] R. Drechsler, Evolutionary algorithms for computer aided design of integrated circuits, in: Proceedings of the International Symposium On IC-Technology, Systems, and Applications, Singapore, 1997, pp. 302±311. [12] R. Drechsler, H. Hengster, H. Schaefer, J. Hartmann, B. Becker, Testability of 2-level AND/EXOR circuits, J. Electron. Testing, Theory Appl. (JETTA) 1999. [13] R. Drechsler, Evolutionary Algorithms for VLSI CAD, Kluwer Academic Publishers, Dordrecht, 1998. [14] H. Fujiwara, Logic Testing and Design for Testability, Computer Science Series, MIT Press, Cambridge, MA, 1986. [15] D.E. Goldberg, Genetic Algorithms in Search Optimization and Machine Learning, Addison-Wesley, New York, 1989.

488

K.M. Dill, M.A. Perkowski / Journal of Systems Architecture 47 (2001) 477±489

[16] D.H. Green, Families of Reed±Muller canonical forms, Int. J. Electron. 70 (1991) 259±280. [17] B.A. Julstrom, Comparing Darwinian, Baldwinian, and Lamarckian search in a genetic algorithm for the 4-cycle problem, in: S. Brave, A.S. Wu (Eds.), Late Breaking Papers at the 1999 Genetic and Evolutionary Computation Conference, GECCO'99, 14±17 July 1999, Orlando, FL, pp. 134±138. [18] B.A. Julstrom, Seeding the population: improved performance in a genetic algorithm for the rectilinear steiner problem, in: E. Deaton, D. Oppenheim, J. Urban, H. Berghel (Eds.), Applied Computing 1994: Proceedings of the 1994 ACM Symposium on Applied Computing, SAC'94, 6±8 March 1994, Phoenix, AZ, Association for Computing Machinery, New York, pp. 222±226. [19] U. Kalay, D.V. Hall, M.A. Perkowski, Easily testable multiple-valued Galois Field Sum-of-Products circuits, J. Multiple-Valued Logic, January 1999, accepted. [20] U. Kalay, M. Perkowski, D. Hall, A minimal universal test set for self test of EXOR-Sum-of-Products circuits, IEEE Trans. Comput., July 1999, accepted. [21] U. Kalay, N. Venkataramaiah, A. Mishchenko, D. Hall, M. Perkowski, Highly testable ®nite state machines based on EXOR logic, in: Proceedings of the Seventh IEEE Paci®c Rim Conference on Communications, Computers, and Signal Processing, Victoria, BC, Canada, 23±25 August 1999. [22] L. McKenzie, A.E.A. Almaini, J.F. Miller, P. Thompson, Optimization of Reed±Muller logic functions, Int. J. Electron. 75 (3) (1993) 451±466. [23] J.F. Miller, H. Luchian, P.V.G. Bradbeer, P.J. Barclay, Using a genetic algorithm for optimizing ®xed polarity Reed±Muller expansions of Boolean functions, Int. J. Electron. 76 (1994) 601±609. [24] J.F. Miller, P. Thomson, A highly ecient exhaustive search algorithm for optimizing canonical Reed±Muller expansions of Boolean functions, Int. J. Electron. 76 (1994) 37±56. [25] M. Perkowski, L. Csanky, A. Sarabi, I. Schafer, Minimization of mixed-polarity AND/XOR forms, in: Proceedings of the IEEE International conference on computer design, ICCD'92, 11±13 October 1992, Boston, MA, 1992, pp. 32±36. [26] M. Perkowski, L. Jozwiak, R. Drechsler, A canonical AND/EXOR form that includes both the Generalized Reed±Muller forms and Kronecker Reed±Muller forms, in: Proceedings of the Reed±Muller 1997 Conference, Oxford University, UK, September 1997, pp. 219±233. [27] M. Perkowski, U. Kalay, D. Hall, A. Shahjahan, Rectangular covering factorization of ESOPs into scan-based levelized circuits with universal test set, in: Proceedings of Reed±Muller `99, University of Victoria, Victoria, BC, Canada, 20±21 August 1999. [28] D.K. Pradhan, Fault-tolerant Computing: Theory and Techniques, vol. 1, Prentice-Hall, Upper Saddle River, NJ, 1987.

[29] S.M. Reddy, Easily testable realizations for logic functions, IEEE Trans. Comput. 21 (1972) 1183±1188. [30] M.W. Riege, P.W. Besslich, Low-complexity synthesis of incompletely speci®ed multiple-output mod-2 sums, IEE Proc. E 139 (4) (1992) 355±362. [31] J.V. Salmon, E.P. Pitty, M.S. Abramson, Syntactic translation and logic synthesis in gatemap, IEE Proceedings, Part E 136 (4) (1989) 321±328. [32] A. Sarabi, M. Perkowski, Design for testability properties of AND/XOR networks, in: IFIP WG10.5, Proceedings of the Workshop on Applications of the Reed±Muller Expansion in Circuit Design, 1993, pp. 147±153. [33] A. Sarabi, M.A. Perkowski, Fast exact and quasi-minimal minimization of highly testable ®xed-polarity AND/XOR canonical networks, in: Proceedings of the 1992 IEEE Design Automation Conference, June 1992, pp. 30±35. [34] T. Sasao, A transformation of multiple-valued input twovalued output functions and its application to simpli®cation of Exclusive-Or Sum-of-Products expresions, in: Proceedings of the International Symposium on Multivalued Logic, 1991 (ISMVL-91), May 1991, pp. 270±279. [35] T. Sasao, P. Besslich, On the complexity of MOD-2 sum PLAs, IEEE Trans. Comput. 39 (2) (1990) 262±266. [36] T. Sasao, Easily testable realizations for generalized Reed± Muller expressions, IEEE Trans. Comput. 46 (6) (1997) 709±716. [37] T. Sasao, Logic Synthesis and Optimization, Kluwer Academic Publishers, Norwell, MA, 1993. [38] T. Sasao, On the complexity of some classes of AND± EXOR expressions, IEICE Technical Report FTS 91-35, October 1991. [39] J. Saul, Logic synthesis for arithmetic circuits using the Reed±Muller representation, in: Proceedings of the European Conference on Design Automation, 1992, pp. 109± 113. [40] N. Song, Minimization of exclusive sum of products expressions for multiple-valued input incompletely speci®ed functions, Master of Science Thesis, Portland State University, Portland, OR, 1993. [41] I. Stewart, Galois Theory, second ed., Chapman & Hall, New York, 1989. [42] P. Turney, Myths and legends of the Baldwin e€ect, in: Proceedings of the Workshop on Evolutionary Computing and Machine Learning at the 13th International Conference on Machine Learning, ICML'96, Bari, Italy, pp. 135± 142. [43] D. Varma, E.A. Trachtenberg, Computation of Reed± Muller expansions of incompletely speci®ed boolean functions from reduced representations, IEE Proc. E 138 (2) (1991) 85±92. [44] W. Wan, M.A. Perkowski, A new approach to the decomposition of incompletely speci®ed functions based on graph-coloring and local transformations and its application to FPGA mapping, in: Proceedings of the IEEE EURO-DAC'92, European Design Automation Conference, 7±10 September 1992, Hamburg, Germany, pp. 230±235.

K.M. Dill, M.A. Perkowski / Journal of Systems Architecture 47 (2001) 477±489 [45] A. Zakrevskij, Minimum polynomial implementation of systems of incompletely speci®ed Boolean functions, in: IFIP WG 10.5, Proceedings of the Workshop on Applications of the Reed±Muller Expansion in Circuit Design, 27±29 August 1995, Makuhari, Chiba, Japan. [46] H. Wu, M.A. Perkowski, X. Zeng, N. Zhuang, Generalized partially-mixed-polarity Reed±Muller expansion and its fast computation, IEEE Trans. Comput. 45 (9) (1996) 1084±1088.

489

[47] X. Zeng, M. Perkowski, K. Dill, A. Sarabi, Approximate minimization of generalized Reed±Muller forms, in: IFIP WG 10.5, Proceedings of the Workshop on Applications of the Reed±Muller Expansion in Circuit Design, 27±29 August 1995, Makuhari, Chiba, Japan. [48] Z. Zilic, Z. Vranesic, A multiple-valued Reed±Muller transform for incompletely speci®ed functions, IEEE Trans. Comput. 44 (8) (1995) 1012±1020.