abc-master
|
Go to the source code of this file.
Data Structures | |
struct | saucy_stats |
struct | saucy_graph |
struct | coloring |
struct | sim_result |
struct | saucy |
Macros | |
#define | REFINE_BY_SIM_1 0 |
#define | REFINE_BY_SIM_2 0 |
#define | BACKTRACK_BY_SAT 1 |
#define | SELECT_DYNAMICALLY 0 |
#define | CLAUSE_DECAY 0.9 |
#define | MAX_LEARNTS 50 |
Functions | |
static int * | ints (int n) |
static int * | zeros (int n) |
static char * | bits (int n) |
static char * | getVertexName (Abc_Ntk_t *pNtk, int v) |
static int * | generateProperInputVector (Abc_Ntk_t *pNtk, struct coloring *c, Vec_Int_t *randomVector) |
static int | ifInputVectorsAreConsistent (struct saucy *s, int *leftVec, int *rightVec) |
static int | ifOutputVectorsAreConsistent (struct saucy *s, int *leftVec, int *rightVec) |
static Vec_Ptr_t ** | findTopologicalOrder (Abc_Ntk_t *pNtk) |
static void | getDependencies (Abc_Ntk_t *pNtk, Vec_Int_t **iDep, Vec_Int_t **oDep) |
static struct saucy_graph * | buildDepGraph (Abc_Ntk_t *pNtk, Vec_Int_t **iDep, Vec_Int_t **oDep) |
static struct saucy_graph * | buildSim1Graph (Abc_Ntk_t *pNtk, struct coloring *c, Vec_Int_t *randVec, Vec_Int_t **iDep, Vec_Int_t **oDep) |
static struct saucy_graph * | buildSim2Graph (Abc_Ntk_t *pNtk, struct coloring *c, Vec_Int_t *randVec, Vec_Int_t **iDep, Vec_Int_t **oDep, Vec_Ptr_t **topOrder, Vec_Int_t **obs, Vec_Int_t **ctrl) |
static Vec_Int_t * | assignRandomBitsToCells (Abc_Ntk_t *pNtk, struct coloring *c) |
static int | Abc_NtkCecSat_saucy (Abc_Ntk_t *pNtk1, Abc_Ntk_t *pNtk2, int *pModel) |
static struct sim_result * | analyzeConflict (Abc_Ntk_t *pNtk, int *pModel, int fVerbose) |
static void | bumpActivity (struct saucy *s, struct sim_result *cex) |
static void | reduceDB (struct saucy *s) |
static int | print_automorphism_ntk (FILE *f, int n, const int *gamma, int nsupp, const int *support, char *marks, Abc_Ntk_t *pNtk) |
static int | print_automorphism_ntk2 (FILE *f, int n, const int *gamma, int nsupp, const int *support, char *marks, Abc_Ntk_t *pNtk) |
static int | print_automorphism_quiet (FILE *f, int n, const int *gamma, int nsupp, const int *support, char *marks, Abc_Ntk_t *pNtk) |
static int | array_find_min (const int *a, int n) |
static void | swap (int *a, int x, int y) |
static void | sift_up (int *a, int k) |
static void | sift_down (int *a, int n) |
static void | heap_sort (int *a, int n) |
static void | insertion_sort (int *a, int n) |
static int | partition (int *a, int n, int m) |
static int | log_base2 (int n) |
static int | median (int a, int b, int c) |
static void | introsort_loop (int *a, int n, int lim) |
static void | introsort (int *a, int n) |
static int | do_find_min (struct coloring *c, int t) |
static int | find_min (struct saucy *s, int t) |
static void | set_label (struct coloring *c, int index, int value) |
static void | swap_labels (struct coloring *c, int a, int b) |
static void | move_to_back (struct saucy *s, struct coloring *c, int k) |
static void | data_mark (struct saucy *s, struct coloring *c, int k) |
static void | data_count (struct saucy *s, struct coloring *c, int k) |
static int | check_mapping (struct saucy *s, const int *adj, const int *edg, int k) |
static int | add_conterexample (struct saucy *s, struct sim_result *cex) |
static int | is_undirected_automorphism (struct saucy *s) |
static int | is_directed_automorphism (struct saucy *s) |
static void | add_induce (struct saucy *s, struct coloring *c, int who) |
static void | fix_fronts (struct coloring *c, int cf, int ff) |
static void | array_indirect_sort (int *a, const int *b, int n) |
static int | at_terminal (struct saucy *s) |
static void | add_diffnon (struct saucy *s, int k) |
static void | remove_diffnon (struct saucy *s, int k) |
static void | add_diff (struct saucy *s, int k) |
static int | is_a_pair (struct saucy *s, int k) |
static int | in_cell_range (struct coloring *c, int ff, int cf) |
static void | add_pair (struct saucy *s, int k) |
static void | eat_pair (struct saucy *s, int k) |
static void | pick_all_the_pairs (struct saucy *s) |
static void | clear_undiffnons (struct saucy *s) |
static void | fix_diff_singleton (struct saucy *s, int cf) |
static void | fix_diff_subtract (struct saucy *s, int cf, const int *a, const int *b) |
static void | fix_diffs (struct saucy *s, int cf, int ff) |
static void | split_color (struct coloring *c, int cf, int ff) |
static void | split_common (struct saucy *s, struct coloring *c, int cf, int ff) |
static int | split_left (struct saucy *s, struct coloring *c, int cf, int ff) |
static int | split_init (struct saucy *s, struct coloring *c, int cf, int ff) |
static int | split_other (struct saucy *s, struct coloring *c, int cf, int ff) |
static int | print_partition (struct coloring *left, struct coloring *right, int n, Abc_Ntk_t *pNtk, int fNames) |
static int | refine_cell (struct saucy *s, struct coloring *c, int(*refine)(struct saucy *, struct coloring *, int)) |
static int | maybe_split (struct saucy *s, struct coloring *c, int cf, int ff) |
static int | ref_single_cell (struct saucy *s, struct coloring *c, int cf) |
static int | ref_singleton (struct saucy *s, struct coloring *c, const int *adj, const int *edg, int cf) |
static int | ref_singleton_directed (struct saucy *s, struct coloring *c, int cf) |
static int | ref_singleton_undirected (struct saucy *s, struct coloring *c, int cf) |
static int | ref_nonsingle_cell (struct saucy *s, struct coloring *c, int cf) |
static int | ref_nonsingle (struct saucy *s, struct coloring *c, const int *adj, const int *edg, int cf) |
static int | ref_nonsingle_directed (struct saucy *s, struct coloring *c, int cf) |
static int | ref_nonsingle_undirected (struct saucy *s, struct coloring *c, int cf) |
static void | clear_refine (struct saucy *s) |
static int | refine (struct saucy *s, struct coloring *c) |
static int | refineByDepGraph (struct saucy *s, struct coloring *c) |
static int | backtrackBysatCounterExamples (struct saucy *s, struct coloring *c) |
static int | refineBySim1_init (struct saucy *s, struct coloring *c) |
static int | refineBySim1_left (struct saucy *s, struct coloring *c) |
static int | refineBySim1_other (struct saucy *s, struct coloring *c) |
static int | refineBySim2_init (struct saucy *s, struct coloring *c) |
static int | refineBySim2_left (struct saucy *s, struct coloring *c) |
static int | refineBySim2_other (struct saucy *s, struct coloring *c) |
static int | check_OPP_only_has_swaps (struct saucy *s, struct coloring *c) |
static int | check_OPP_for_Boolean_matching (struct saucy *s, struct coloring *c) |
static int | double_check_OPP_isomorphism (struct saucy *s, struct coloring *c) |
static int | descend (struct saucy *s, struct coloring *c, int target, int min) |
static int | select_smallest_max_connected_cell (struct saucy *s, int start, int end) |
static int | descend_leftmost (struct saucy *s) |
static int | zeta_fixed (struct saucy *s) |
static void | select_dynamically (struct saucy *s, int *target, int *lmin, int *rmin) |
static void | select_statically (struct saucy *s, int *target, int *lmin, int *rmin) |
static int | descend_left (struct saucy *s) |
static int | find_representative (int k, int *theta) |
static void | update_theta (struct saucy *s) |
static int | theta_prune (struct saucy *s) |
static int | orbit_prune (struct saucy *s) |
static void | note_anctar_reps (struct saucy *s) |
static void | multiply_index (struct saucy *s, int k) |
static int | backtrack_leftmost (struct saucy *s) |
static int | backtrack_other (struct saucy *s) |
static void | rewind_coloring (struct saucy *s, struct coloring *c, int lev) |
static void | rewind_simulation_vectors (struct saucy *s, int lev) |
static int | do_backtrack (struct saucy *s) |
static int | backtrack_loop (struct saucy *s) |
static int | backtrack (struct saucy *s) |
static int | backtrack_bad (struct saucy *s) |
void | prepare_permutation_ntk (struct saucy *s) |
static void | prepare_permutation (struct saucy *s) |
void | unprepare_permutation_ntk (struct saucy *s) |
static void | unprepare_permutation (struct saucy *s) |
static int | do_search (struct saucy *s) |
void | saucy_search (Abc_Ntk_t *pNtk, struct saucy *s, int directed, const int *colors, struct saucy_stats *stats) |
void | saucy_free (struct saucy *s) |
struct saucy * | saucy_alloc (Abc_Ntk_t *pNtk) |
static void | print_stats (FILE *f, struct saucy_stats stats) |
static void | getDependenciesDummy (Abc_Ntk_t *pNtk, Vec_Int_t **iDep, Vec_Int_t **oDep) |
void | saucyGateWay (Abc_Ntk_t *pNtkOrig, Abc_Obj_t *pNodePo, FILE *gFile, int fBooleanMatching, int fLookForSwaps, int fFixOutputs, int fFixInputs, int fQuiet, int fPrintTree) |
Variables | |
int | NUM_SIM1_ITERATION |
int | NUM_SIM2_ITERATION |
#define BACKTRACK_BY_SAT 1 |
Definition at line 35 of file abcSaucy.c.
#define CLAUSE_DECAY 0.9 |
Definition at line 43 of file abcSaucy.c.
#define MAX_LEARNTS 50 |
Definition at line 44 of file abcSaucy.c.
#define REFINE_BY_SIM_1 0 |
CFile****************************************************************
FileName [abcSaucy.c]
SystemName [ABC: Logic synthesis and verification system.]
PackageName [Symmetry Detection Package.]
Synopsis [Finds symmetries under permutation (but not negation) of I/Os.]
Author [Hadi Katebi]
Affiliation [University of Michigan]
Date [Ver. 1.0. Started - April, 2012.]
Revision [No revisions so far]
Comments []
Debugging [There are some part of the code that are commented out. Those parts mostly print the contents of the data structures to the standard output. Un-comment them if you find them useful for debugging.]
Definition at line 33 of file abcSaucy.c.
#define REFINE_BY_SIM_2 0 |
Definition at line 34 of file abcSaucy.c.
#define SELECT_DYNAMICALLY 0 |
Definition at line 36 of file abcSaucy.c.
Definition at line 3177 of file abcSaucy.c.
|
static |
Definition at line 521 of file abcSaucy.c.
|
static |
Definition at line 665 of file abcSaucy.c.
|
static |
Definition at line 641 of file abcSaucy.c.
Definition at line 591 of file abcSaucy.c.
|
static |
Definition at line 688 of file abcSaucy.c.
|
static |
Definition at line 3139 of file abcSaucy.c.
|
static |
Definition at line 295 of file abcSaucy.c.
|
static |
Definition at line 612 of file abcSaucy.c.
Definition at line 2852 of file abcSaucy.c.
|
static |
Definition at line 635 of file abcSaucy.c.
|
static |
Definition at line 2109 of file abcSaucy.c.
|
static |
Definition at line 2125 of file abcSaucy.c.
|
static |
Definition at line 1981 of file abcSaucy.c.
|
static |
Definition at line 2096 of file abcSaucy.c.
|
static |
Definition at line 2003 of file abcSaucy.c.
Definition at line 1158 of file abcSaucy.c.
|
static |
Definition at line 201 of file abcSaucy.c.
|
static |
Definition at line 2806 of file abcSaucy.c.
|
static |
Definition at line 2948 of file abcSaucy.c.
|
static |
Definition at line 3015 of file abcSaucy.c.
|
static |
Definition at line 3095 of file abcSaucy.c.
Definition at line 497 of file abcSaucy.c.
Definition at line 1539 of file abcSaucy.c.
Definition at line 1503 of file abcSaucy.c.
|
static |
Definition at line 1102 of file abcSaucy.c.
|
static |
Definition at line 717 of file abcSaucy.c.
Definition at line 488 of file abcSaucy.c.
Definition at line 479 of file abcSaucy.c.
Definition at line 1625 of file abcSaucy.c.
|
static |
Definition at line 1803 of file abcSaucy.c.
|
static |
Definition at line 1700 of file abcSaucy.c.
|
static |
Definition at line 2062 of file abcSaucy.c.
|
static |
Definition at line 438 of file abcSaucy.c.
|
static |
Definition at line 2246 of file abcSaucy.c.
Definition at line 1582 of file abcSaucy.c.
|
static |
Definition at line 697 of file abcSaucy.c.
|
static |
Definition at line 444 of file abcSaucy.c.
|
static |
Definition at line 1848 of file abcSaucy.c.
Definition at line 2706 of file abcSaucy.c.
|
static |
Definition at line 726 of file abcSaucy.c.
Definition at line 759 of file abcSaucy.c.
|
static |
Definition at line 782 of file abcSaucy.c.
|
static |
Definition at line 603 of file abcSaucy.c.
|
static |
Definition at line 2866 of file abcSaucy.c.
Definition at line 2733 of file abcSaucy.c.
Definition at line 2791 of file abcSaucy.c.
|
static |
Definition at line 2692 of file abcSaucy.c.
|
static |
Definition at line 346 of file abcSaucy.c.
|
static |
Definition at line 2896 of file abcSaucy.c.
|
static |
Definition at line 2928 of file abcSaucy.c.
|
static |
Definition at line 681 of file abcSaucy.c.
|
static |
Definition at line 360 of file abcSaucy.c.
|
static |
Definition at line 431 of file abcSaucy.c.
|
static |
Definition at line 415 of file abcSaucy.c.
|
static |
Definition at line 199 of file abcSaucy.c.
|
static |
Definition at line 675 of file abcSaucy.c.
|
static |
Definition at line 578 of file abcSaucy.c.
|
static |
Definition at line 549 of file abcSaucy.c.
|
static |
Definition at line 389 of file abcSaucy.c.
Definition at line 955 of file abcSaucy.c.
|
static |
Definition at line 400 of file abcSaucy.c.
Definition at line 465 of file abcSaucy.c.
|
static |
Definition at line 1972 of file abcSaucy.c.
|
static |
Definition at line 1934 of file abcSaucy.c.
|
static |
Definition at line 1906 of file abcSaucy.c.
|
static |
Definition at line 373 of file abcSaucy.c.
|
static |
Definition at line 707 of file abcSaucy.c.
|
static |
Definition at line 2197 of file abcSaucy.c.
void prepare_permutation_ntk | ( | struct saucy * | s | ) |
Definition at line 2155 of file abcSaucy.c.
|
static |
Definition at line 220 of file abcSaucy.c.
|
static |
Definition at line 255 of file abcSaucy.c.
|
static |
Definition at line 289 of file abcSaucy.c.
|
static |
Definition at line 886 of file abcSaucy.c.
|
static |
Definition at line 2673 of file abcSaucy.c.
|
static |
Definition at line 3111 of file abcSaucy.c.
|
static |
Definition at line 1053 of file abcSaucy.c.
Definition at line 996 of file abcSaucy.c.
Definition at line 1089 of file abcSaucy.c.
Definition at line 1096 of file abcSaucy.c.
Definition at line 961 of file abcSaucy.c.
|
static |
Definition at line 968 of file abcSaucy.c.
Definition at line 983 of file abcSaucy.c.
Definition at line 990 of file abcSaucy.c.
Definition at line 1115 of file abcSaucy.c.
|
static |
Definition at line 926 of file abcSaucy.c.
Definition at line 1149 of file abcSaucy.c.
Definition at line 1208 of file abcSaucy.c.
Definition at line 1262 of file abcSaucy.c.
Definition at line 1320 of file abcSaucy.c.
Definition at line 1368 of file abcSaucy.c.
Definition at line 1408 of file abcSaucy.c.
Definition at line 1452 of file abcSaucy.c.
|
static |
Definition at line 651 of file abcSaucy.c.
Definition at line 2037 of file abcSaucy.c.
|
static |
Definition at line 2049 of file abcSaucy.c.
Definition at line 2574 of file abcSaucy.c.
void saucy_free | ( | struct saucy * | s | ) |
Definition at line 2489 of file abcSaucy.c.
void saucy_search | ( | Abc_Ntk_t * | pNtk, |
struct saucy * | s, | ||
int | directed, | ||
const int * | colors, | ||
struct saucy_stats * | stats | ||
) |
Definition at line 2311 of file abcSaucy.c.
void saucyGateWay | ( | Abc_Ntk_t * | pNtkOrig, |
Abc_Obj_t * | pNodePo, | ||
FILE * | gFile, | ||
int | fBooleanMatching, | ||
int | fLookForSwaps, | ||
int | fFixOutputs, | ||
int | fFixInputs, | ||
int | fQuiet, | ||
int | fPrintTree | ||
) |
Definition at line 3246 of file abcSaucy.c.
|
static |
Definition at line 1736 of file abcSaucy.c.
|
static |
Definition at line 1666 of file abcSaucy.c.
|
static |
Definition at line 1788 of file abcSaucy.c.
|
static |
Definition at line 450 of file abcSaucy.c.
|
static |
Definition at line 329 of file abcSaucy.c.
|
static |
Definition at line 313 of file abcSaucy.c.
|
static |
Definition at line 799 of file abcSaucy.c.
Definition at line 814 of file abcSaucy.c.
Definition at line 843 of file abcSaucy.c.
Definition at line 828 of file abcSaucy.c.
Definition at line 864 of file abcSaucy.c.
|
static |
Definition at line 305 of file abcSaucy.c.
|
static |
Definition at line 457 of file abcSaucy.c.
|
static |
Definition at line 1889 of file abcSaucy.c.
|
static |
Definition at line 2236 of file abcSaucy.c.
void unprepare_permutation_ntk | ( | struct saucy * | s | ) |
Definition at line 2209 of file abcSaucy.c.
|
static |
Definition at line 1863 of file abcSaucy.c.
|
static |
Definition at line 200 of file abcSaucy.c.
|
static |
Definition at line 1730 of file abcSaucy.c.
int NUM_SIM1_ITERATION |
Definition at line 39 of file abcSaucy.c.
int NUM_SIM2_ITERATION |
Definition at line 40 of file abcSaucy.c.