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
1368a920
Commit
1368a920
authored
Aug 08, 2022
by
Alan Mishchenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improvements to command 'twoexact'.
parent
99b33e5d
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
37 additions
and
0 deletions
+37
-0
src/aig/miniaig/miniaig.h
+37
-0
src/sat/bmc/bmcMaj.c
+0
-0
No files found.
src/aig/miniaig/miniaig.h
View file @
1368a920
...
@@ -144,6 +144,18 @@ static Mini_Aig_t * Mini_AigStart()
...
@@ -144,6 +144,18 @@ static Mini_Aig_t * Mini_AigStart()
Mini_AigPush
(
p
,
MINI_AIG_NULL
,
MINI_AIG_NULL
);
Mini_AigPush
(
p
,
MINI_AIG_NULL
,
MINI_AIG_NULL
);
return
p
;
return
p
;
}
}
static
Mini_Aig_t
*
Mini_AigStartSupport
(
int
nIns
,
int
nObjsAlloc
)
{
Mini_Aig_t
*
p
;
int
i
;
assert
(
1
+
nIns
<
nObjsAlloc
);
p
=
MINI_AIG_CALLOC
(
Mini_Aig_t
,
1
);
p
->
nCap
=
2
*
nObjsAlloc
;
p
->
nSize
=
2
*
(
1
+
nIns
);
p
->
pArray
=
MINI_AIG_ALLOC
(
int
,
p
->
nCap
);
for
(
i
=
0
;
i
<
p
->
nSize
;
i
++
)
p
->
pArray
[
i
]
=
MINI_AIG_NULL
;
return
p
;
}
static
void
Mini_AigStop
(
Mini_Aig_t
*
p
)
static
void
Mini_AigStop
(
Mini_Aig_t
*
p
)
{
{
MINI_AIG_FREE
(
p
->
pArray
);
MINI_AIG_FREE
(
p
->
pArray
);
...
@@ -170,6 +182,31 @@ static int Mini_AigAndNum( Mini_Aig_t * p )
...
@@ -170,6 +182,31 @@ static int Mini_AigAndNum( Mini_Aig_t * p )
nNodes
++
;
nNodes
++
;
return
nNodes
;
return
nNodes
;
}
}
static
int
Mini_AigXorNum
(
Mini_Aig_t
*
p
)
{
int
i
,
nNodes
=
0
;
Mini_AigForEachAnd
(
p
,
i
)
nNodes
+=
p
->
pArray
[
2
*
i
]
>
p
->
pArray
[
2
*
i
+
1
];
return
nNodes
;
}
static
int
Mini_AigLevelNum
(
Mini_Aig_t
*
p
)
{
int
i
,
Level
=
0
;
int
*
pLevels
=
MINI_AIG_CALLOC
(
int
,
Mini_AigNodeNum
(
p
)
);
Mini_AigForEachAnd
(
p
,
i
)
{
int
Lel0
=
pLevels
[
Mini_AigLit2Var
(
Mini_AigNodeFanin0
(
p
,
i
))];
int
Lel1
=
pLevels
[
Mini_AigLit2Var
(
Mini_AigNodeFanin1
(
p
,
i
))];
pLevels
[
i
]
=
1
+
(
Lel0
>
Lel1
?
Lel0
:
Lel1
);
}
Mini_AigForEachPo
(
p
,
i
)
{
int
Lel0
=
pLevels
[
Mini_AigLit2Var
(
Mini_AigNodeFanin0
(
p
,
i
))];
Level
=
Level
>
Lel0
?
Level
:
Lel0
;
}
MINI_AIG_FREE
(
pLevels
);
return
Level
;
}
static
void
Mini_AigPrintStats
(
Mini_Aig_t
*
p
)
static
void
Mini_AigPrintStats
(
Mini_Aig_t
*
p
)
{
{
printf
(
"MiniAIG stats: PI = %d PO = %d FF = %d AND = %d
\n
"
,
Mini_AigPiNum
(
p
),
Mini_AigPoNum
(
p
),
Mini_AigRegNum
(
p
),
Mini_AigAndNum
(
p
)
);
printf
(
"MiniAIG stats: PI = %d PO = %d FF = %d AND = %d
\n
"
,
Mini_AigPiNum
(
p
),
Mini_AigPoNum
(
p
),
Mini_AigRegNum
(
p
),
Mini_AigAndNum
(
p
)
);
...
...
src/sat/bmc/bmcMaj.c
View file @
1368a920
This diff is collapsed.
Click to expand it.
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