Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
abc
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
abc
Commits
8b881d23
Commit
8b881d23
authored
Jul 07, 2012
by
Alan Mishchenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Making 'pdr', &gla, &vta print correctly in batch mode.
parent
31d85e73
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
34 additions
and
10 deletions
+34
-10
src/aig/gia/giaAbsGla.c
+2
-0
src/aig/gia/giaAbsVta.c
+3
-0
src/aig/gia/giaMan.c
+2
-1
src/base/main/main.h
+1
-0
src/base/main/mainFrame.c
+2
-0
src/base/main/mainInt.h
+2
-2
src/misc/bar/bar.c
+8
-2
src/misc/extra/extraUtilProgress.c
+8
-2
src/proof/pdr/pdrInv.c
+3
-1
src/proof/ssw/sswRarity.c
+3
-2
No files found.
src/aig/gia/giaAbsGla.c
View file @
8b881d23
...
...
@@ -1618,6 +1618,8 @@ Vec_Int_t * Gla_ManUnsatCore( Gla_Man_t * p, int f, Vec_Int_t * vCla2Obj, sat_so
***********************************************************************/
void
Gla_ManAbsPrintFrame
(
Gla_Man_t
*
p
,
int
nCoreSize
,
int
nFrames
,
int
nConfls
,
int
nCexes
,
int
Time
)
{
if
(
Abc_FrameIsBatchMode
()
&&
nCoreSize
<=
0
)
return
;
Abc_Print
(
1
,
"%3d :"
,
nFrames
-
1
);
Abc_Print
(
1
,
"%4d"
,
Abc_MinInt
(
100
,
100
*
Gia_GlaAbsCount
(
p
,
0
,
0
)
/
(
p
->
nObjs
-
Gia_ManPoNum
(
p
->
pGia
)
+
Gia_ManCoNum
(
p
->
pGia
)
+
1
))
);
Abc_Print
(
1
,
"%6d"
,
Gia_GlaAbsCount
(
p
,
0
,
0
)
);
...
...
src/aig/gia/giaAbsVta.c
View file @
8b881d23
...
...
@@ -1226,6 +1226,9 @@ int Vta_ManAbsPrintFrame( Vta_Man_t * p, Vec_Int_t * vCore, int nFrames, int nCo
return
fChanges
;
}
if
(
Abc_FrameIsBatchMode
()
&&
!
vCore
)
return
fChanges
;
// Abc_Print( 1, "%5d%5d", pCountAll[0], pCountUni[0] );
Abc_Print
(
1
,
"%3d :"
,
nFrames
-
1
);
Abc_Print
(
1
,
"%4d"
,
Abc_MinInt
(
100
,
100
*
p
->
nSeenGla
/
(
Gia_ManRegNum
(
p
->
pGia
)
+
Gia_ManAndNum
(
p
->
pGia
)
+
1
))
);
...
...
src/aig/gia/giaMan.c
View file @
8b881d23
...
...
@@ -412,7 +412,8 @@ void Gia_ManPrintStats( Gia_Man_t * p, int fTents, int fSwitch )
printf
(
" and =%8d"
,
Gia_ManAndNum
(
p
)
);
printf
(
" lev =%5d"
,
Gia_ManLevelNum
(
p
)
);
printf
(
" cut =%5d"
,
Gia_ManCrossCut
(
p
)
);
printf
(
" mem =%5.2f Mb"
,
12
.
0
*
Gia_ManObjNum
(
p
)
/
(
1
<<
20
)
);
printf
(
" mem =%5.2f Mb"
,
1
.
0
*
(
sizeof
(
Gia_Obj_t
)
*
p
->
nObjs
+
sizeof
(
int
)
*
(
Vec_IntSize
(
p
->
vCis
)
+
Vec_IntSize
(
p
->
vCos
)))
/
(
1
<<
20
)
);
// printf( " mem =%5.2f Mb", 1.0*(sizeof(Gia_Obj_t)*p->nObjsAlloc + sizeof(int)*(Vec_IntCap(p->vCis) + Vec_IntCap(p->vCos)))/(1<<20) );
if
(
Gia_ManHasDangling
(
p
)
)
printf
(
" ch =%5d"
,
Gia_ManEquivCountClasses
(
p
)
);
if
(
fSwitch
)
...
...
src/base/main/main.h
View file @
8b881d23
...
...
@@ -104,6 +104,7 @@ extern ABC_DLL void * Abc_FrameReadManDd();
extern
ABC_DLL
void
*
Abc_FrameReadManDec
();
extern
ABC_DLL
char
*
Abc_FrameReadFlag
(
char
*
pFlag
);
extern
ABC_DLL
int
Abc_FrameIsFlagEnabled
(
char
*
pFlag
);
extern
ABC_DLL
int
Abc_FrameIsBatchMode
();
extern
ABC_DLL
int
Abc_FrameIsBridgeMode
();
extern
ABC_DLL
void
Abc_FrameSetBridgeMode
();
...
...
src/base/main/mainFrame.c
View file @
8b881d23
...
...
@@ -79,6 +79,8 @@ void Abc_FrameSetFlag( char * pFlag, char * pValue ) { Cmd_FlagUpdateVal
void
Abc_FrameSetCex
(
Abc_Cex_t
*
pCex
)
{
ABC_FREE
(
s_GlobalFrame
->
pCex
);
s_GlobalFrame
->
pCex
=
pCex
;
}
void
Abc_FrameSetNFrames
(
int
nFrames
)
{
ABC_FREE
(
s_GlobalFrame
->
pCex
);
s_GlobalFrame
->
nFrames
=
nFrames
;
}
int
Abc_FrameIsBatchMode
()
{
return
s_GlobalFrame
?
s_GlobalFrame
->
fBatchMode
:
0
;
}
int
Abc_FrameIsBridgeMode
()
{
return
s_GlobalFrame
?
s_GlobalFrame
->
fBridgeMode
:
0
;
}
void
Abc_FrameSetBridgeMode
()
{
if
(
s_GlobalFrame
)
s_GlobalFrame
->
fBridgeMode
=
1
;
}
...
...
src/base/main/mainInt.h
View file @
8b881d23
...
...
@@ -69,8 +69,8 @@ struct Abc_Frame_t_
Abc_Ntk_t
*
pNtkBestArea
;
// the current network
int
nSteps
;
// the counter of different network processed
int
fAutoexac
;
// marks the autoexec mode
int
fBatchMode
;
//
are we invoked in batch mode?
int
fBridgeMode
;
//
are we invoked in bridge mode?
int
fBatchMode
;
//
batch mode flag
int
fBridgeMode
;
//
bridge mode flag
// output streams
FILE
*
Out
;
FILE
*
Err
;
...
...
src/misc/bar/bar.c
View file @
8b881d23
...
...
@@ -144,7 +144,10 @@ void Bar_ProgressStop( Bar_Progress_t * p )
void
Bar_ProgressShow
(
Bar_Progress_t
*
p
,
char
*
pString
)
{
int
i
;
if
(
p
==
NULL
)
return
;
if
(
p
==
NULL
)
return
;
if
(
Abc_FrameIsBatchMode
()
)
return
;
if
(
pString
)
fprintf
(
p
->
pFile
,
"%s "
,
pString
);
for
(
i
=
(
pString
?
strlen
(
pString
)
+
1
:
0
);
i
<
p
->
posCur
;
i
++
)
...
...
@@ -171,7 +174,10 @@ void Bar_ProgressShow( Bar_Progress_t * p, char * pString )
void
Bar_ProgressClean
(
Bar_Progress_t
*
p
)
{
int
i
;
if
(
p
==
NULL
)
return
;
if
(
p
==
NULL
)
return
;
if
(
Abc_FrameIsBatchMode
()
)
return
;
for
(
i
=
0
;
i
<=
p
->
posTotal
;
i
++
)
fprintf
(
p
->
pFile
,
" "
);
fprintf
(
p
->
pFile
,
"
\r
"
);
...
...
src/misc/extra/extraUtilProgress.c
View file @
8b881d23
...
...
@@ -136,7 +136,10 @@ void Extra_ProgressBarStop( ProgressBar * p )
void
Extra_ProgressBarShow
(
ProgressBar
*
p
,
char
*
pString
)
{
int
i
;
if
(
p
==
NULL
)
return
;
if
(
p
==
NULL
)
return
;
if
(
Abc_FrameIsBatchMode
()
)
return
;
if
(
pString
)
fprintf
(
p
->
pFile
,
"%s "
,
pString
);
for
(
i
=
(
pString
?
strlen
(
pString
)
+
1
:
0
);
i
<
p
->
posCur
;
i
++
)
...
...
@@ -163,7 +166,10 @@ void Extra_ProgressBarShow( ProgressBar * p, char * pString )
void
Extra_ProgressBarClean
(
ProgressBar
*
p
)
{
int
i
;
if
(
p
==
NULL
)
return
;
if
(
p
==
NULL
)
return
;
if
(
Abc_FrameIsBatchMode
()
)
return
;
for
(
i
=
0
;
i
<=
p
->
posTotal
;
i
++
)
fprintf
(
p
->
pFile
,
" "
);
fprintf
(
p
->
pFile
,
"
\r
"
);
...
...
src/proof/pdr/pdrInv.c
View file @
8b881d23
...
...
@@ -50,6 +50,8 @@ void Pdr_ManPrintProgress( Pdr_Man_t * p, int fClose, clock_t Time )
int
i
,
ThisSize
,
Length
,
LengthStart
;
if
(
Vec_PtrSize
(
p
->
vSolvers
)
<
2
)
return
;
if
(
Abc_FrameIsBatchMode
()
&&
!
fClose
)
return
;
// count the total length of the printout
Length
=
0
;
Vec_VecForEachLevel
(
p
->
vClauses
,
vVec
,
i
)
...
...
@@ -78,7 +80,7 @@ void Pdr_ManPrintProgress( Pdr_Man_t * p, int fClose, clock_t Time )
for
(
i
=
ThisSize
;
i
<
70
;
i
++
)
Abc_Print
(
1
,
" "
);
Abc_Print
(
1
,
"%6d"
,
p
->
nQueMax
);
Abc_Print
(
1
,
"
%8.2f sec"
,
(
float
)(
Time
)
/
(
float
)(
CLOCKS_PER_SEC
)
);
Abc_Print
(
1
,
"
%10.2f sec"
,
1
.
0
*
Time
/
CLOCKS_PER_SEC
);
Abc_Print
(
1
,
"%s"
,
fClose
?
"
\n
"
:
"
\r
"
);
if
(
fClose
)
p
->
nQueMax
=
0
;
...
...
src/proof/ssw/sswRarity.c
View file @
8b881d23
...
...
@@ -20,6 +20,7 @@
#include "sswInt.h"
#include "src/aig/gia/giaAig.h"
#include "src/base/main/main.h"
ABC_NAMESPACE_IMPL_START
...
...
@@ -1074,7 +1075,7 @@ int Ssw_RarSignalFilter( Aig_Man_t * pAig, int nFrames, int nWords, int nBinSize
if
(
fMiter
&&
Ssw_RarManCheckNonConstOutputs
(
p
)
)
{
if
(
!
fVerbose
)
printf
(
"
\r
"
);
printf
(
"
%s"
,
Abc_FrameIsBatchMode
()
?
"
\n
"
:
"
\r
"
);
// printf( "Simulation asserted a PO in frame f: %d <= f < %d.\n", r * nFrames, (r+1) * nFrames );
Ssw_RarManPrepareRandom
(
nRandSeed
);
Abc_CexFree
(
pAig
->
pSeqModel
);
...
...
@@ -1108,7 +1109,7 @@ finish:
if
(
r
==
nRounds
&&
f
==
nFrames
)
{
if
(
!
fVerbose
)
printf
(
"
\r
"
);
printf
(
"
%s"
,
Abc_FrameIsBatchMode
()
?
"
\n
"
:
"
\r
"
);
printf
(
"Simulation did not assert POs in the first %d frames. "
,
nRounds
*
nFrames
);
Abc_PrintTime
(
1
,
"Time"
,
clock
()
-
clkTotal
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment