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
6bff2986
Commit
6bff2986
authored
Jan 17, 2012
by
Alan Mishchenko
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
New hierarchy manager.
parent
940d5d66
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
72 additions
and
1 deletions
+72
-1
src/base/abc/abcHieNew.c
+0
-0
src/base/abci/abc.c
+72
-1
No files found.
src/base/abc/abcHieNew.c
View file @
6bff2986
This diff is collapsed.
Click to expand it.
src/base/abci/abc.c
View file @
6bff2986
...
...
@@ -329,6 +329,7 @@ static int Abc_CommandAbc9Get ( Abc_Frame_t * pAbc, int argc, cha
static
int
Abc_CommandAbc9Put
(
Abc_Frame_t
*
pAbc
,
int
argc
,
char
**
argv
);
static
int
Abc_CommandAbc9Read
(
Abc_Frame_t
*
pAbc
,
int
argc
,
char
**
argv
);
static
int
Abc_CommandAbc9ReadBlif
(
Abc_Frame_t
*
pAbc
,
int
argc
,
char
**
argv
);
static
int
Abc_CommandAbc9ReadCBlif
(
Abc_Frame_t
*
pAbc
,
int
argc
,
char
**
argv
);
static
int
Abc_CommandAbc9Write
(
Abc_Frame_t
*
pAbc
,
int
argc
,
char
**
argv
);
static
int
Abc_CommandAbc9Ps
(
Abc_Frame_t
*
pAbc
,
int
argc
,
char
**
argv
);
static
int
Abc_CommandAbc9PFan
(
Abc_Frame_t
*
pAbc
,
int
argc
,
char
**
argv
);
...
...
@@ -788,6 +789,7 @@ void Abc_Init( Abc_Frame_t * pAbc )
Cmd_CommandAdd
(
pAbc
,
"ABC9"
,
"&put"
,
Abc_CommandAbc9Put
,
0
);
Cmd_CommandAdd
(
pAbc
,
"ABC9"
,
"&r"
,
Abc_CommandAbc9Read
,
0
);
Cmd_CommandAdd
(
pAbc
,
"ABC9"
,
"&read_blif"
,
Abc_CommandAbc9ReadBlif
,
0
);
Cmd_CommandAdd
(
pAbc
,
"ABC9"
,
"&read_cblif"
,
Abc_CommandAbc9ReadCBlif
,
0
);
Cmd_CommandAdd
(
pAbc
,
"ABC9"
,
"&w"
,
Abc_CommandAbc9Write
,
0
);
Cmd_CommandAdd
(
pAbc
,
"ABC9"
,
"&ps"
,
Abc_CommandAbc9Ps
,
0
);
Cmd_CommandAdd
(
pAbc
,
"ABC9"
,
"&pfan"
,
Abc_CommandAbc9PFan
,
0
);
...
...
@@ -24506,7 +24508,7 @@ int Abc_CommandAbc9ReadBlif( Abc_Frame_t * pAbc, int argc, char ** argv )
if
(
(
pFile
=
fopen
(
FileName
,
"r"
))
==
NULL
)
{
Abc_Print
(
-
1
,
"Cannot open input file
\"
%s
\"
. "
,
FileName
);
if
(
(
FileName
=
Extra_FileGetSimilarName
(
FileName
,
".
aig"
,
".blif"
,
".pla"
,
".eqn"
,
".bench"
))
)
if
(
(
FileName
=
Extra_FileGetSimilarName
(
FileName
,
".
blif"
,
NULL
,
NULL
,
NULL
,
NULL
))
)
Abc_Print
(
1
,
"Did you mean
\"
%s
\"
?"
,
FileName
);
Abc_Print
(
1
,
"
\n
"
);
return
1
;
...
...
@@ -24537,6 +24539,75 @@ usage:
SeeAlso []
***********************************************************************/
int
Abc_CommandAbc9ReadCBlif
(
Abc_Frame_t
*
pAbc
,
int
argc
,
char
**
argv
)
{
extern
Gia_Man_t
*
Abc_NtkHieCecTest2
(
char
*
pFileName
,
int
fVerbose
);
Gia_Man_t
*
pAig
;
FILE
*
pFile
;
char
**
pArgvNew
;
char
*
FileName
,
*
pTemp
;
int
nArgcNew
;
int
c
,
fVerbose
=
0
;
Extra_UtilGetoptReset
();
while
(
(
c
=
Extra_UtilGetopt
(
argc
,
argv
,
"vh"
)
)
!=
EOF
)
{
switch
(
c
)
{
case
'v'
:
fVerbose
^=
1
;
break
;
default:
goto
usage
;
}
}
pArgvNew
=
argv
+
globalUtilOptind
;
nArgcNew
=
argc
-
globalUtilOptind
;
if
(
nArgcNew
!=
1
)
{
Abc_Print
(
-
1
,
"There is no file name.
\n
"
);
return
1
;
}
// get the input file name
FileName
=
pArgvNew
[
0
];
// fix the wrong symbol
for
(
pTemp
=
FileName
;
*
pTemp
;
pTemp
++
)
if
(
*
pTemp
==
'>'
)
*
pTemp
=
'\\'
;
if
(
(
pFile
=
fopen
(
FileName
,
"r"
))
==
NULL
)
{
Abc_Print
(
-
1
,
"Cannot open input file
\"
%s
\"
. "
,
FileName
);
if
(
(
FileName
=
Extra_FileGetSimilarName
(
FileName
,
".cblif"
,
NULL
,
NULL
,
NULL
,
NULL
))
)
Abc_Print
(
1
,
"Did you mean
\"
%s
\"
?"
,
FileName
);
Abc_Print
(
1
,
"
\n
"
);
return
1
;
}
fclose
(
pFile
);
pAig
=
Abc_NtkHieCecTest2
(
FileName
,
fVerbose
);
Abc_CommandUpdate9
(
pAbc
,
pAig
);
return
0
;
usage:
Abc_Print
(
-
2
,
"usage: &read_cblif [-vh] <file>
\n
"
);
Abc_Print
(
-
2
,
"
\t
reads the current AIG from a hierarchical CBLIF file
\n
"
);
Abc_Print
(
-
2
,
"
\t
-v : toggles additional verbose output [default = %s]
\n
"
,
fVerbose
?
"yes"
:
"no"
);
Abc_Print
(
-
2
,
"
\t
-h : print the command usage
\n
"
);
Abc_Print
(
-
2
,
"
\t
<file> : the file name
\n
"
);
return
1
;
}
/**Function*************************************************************
Synopsis []
Description []
SideEffects []
SeeAlso []
***********************************************************************/
int
Abc_CommandAbc9Get
(
Abc_Frame_t
*
pAbc
,
int
argc
,
char
**
argv
)
{
extern
Aig_Man_t
*
Abc_NtkToDar
(
Abc_Ntk_t
*
pNtk
,
int
fExors
,
int
fRegisters
);
...
...
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