Ignore:
Timestamp:
Jan 13, 2012, 6:32:51 PM (13 years ago)
Author:
cecile
Message:

Fault candidates OK

File:
1 edited

Legend:

Unmodified
Added
Removed
  • vis_dev/vis-2.3/src/debug/debugUtilities.c

    r41 r42  
    11#include "debug.h"
     2void printNodeArray(array_t * nodeArray)
     3{
     4  int i;
     5  Ntk_Node_t* node;
     6  arrayForEachItem(Ntk_Node_t *, nodeArray, i, node){
     7    printf("%s\n",Ntk_NodeReadName(node));
     8  }
     9
     10
     11}
     12
    213void printLatch(st_table* CoiTable)
    314{
     
    98109******************************************************************************/
    99110
    100 int Dbg_SatCheck(char * forceAssigName, char * cnfFileName
     111int Dbg_SatCheck(char * forceAssigName, char * cnfFileName,int verbose
    101112)
    102113{
     
    138149   sat_Main(cm);
    139150
     151if(verbose){
    140152   if(cm->status == SAT_UNSAT) {
    141153    if(cm->option->forcedAssignArr)
     
    154166    sat_FreeManager(cm);
    155167  }
     168}
    156169return cm->status;
    157170}
     
    192205
    193206}
     207/**Function********************************************************************
     208 
     209  Synopsis    [Return the default value of a Node]
     210
     211  Description [Given a table of a node , return its default value if it exists
     212  else -1   This function only work for binary gate with only one default
     213  value.]
     214  SideEffects []
     215
     216  SeeAlso     []
     217
     218******************************************************************************/
     219int Dbg_GetDefaultValue(Tbl_Table_t * table)
     220{
     221  Tbl_Entry_t * defEntry;
     222  int defIndex;
     223  lsList * rangeList;
     224  Tbl_TableForEachDefaultEntry(table,defEntry,defIndex)
     225  {
     226    rangeList = Tbl_EntryReadList(defEntry);
     227    int length = lsLength(rangeList);
     228    if ( length  != 1)
     229      return -1;
     230    Tbl_Range_t * range;
     231    int valDefault;
     232    lsGen gen;
     233    Tbl_EntryForEachValue(defEntry,valDefault,gen,range){
     234      return Tbl_RangeEnd(range);
     235    }
     236  }
     237}
     238
Note: See TracChangeset for help on using the changeset viewer.