Relaxed assert in Io_WritePla() to avoid failure with too shallow network.

Otherwise the abc will refuse to output trivial functions(constant 1 or 0).

The issue was originally submitted to
<URL: https://bitbucket.org/alanmi/abc/issue/27/assertion-failure-in-write_pla-command >,
now available via
<URL: https://web.archive.org/web/20200621081236/https://bitbucket.org/alanmi/abc/issues/27/assertion-failure-in-write_pla-command >.
Sadly the example demonstrated the problem was not archived.

This issue was also reported as <URL: https://bugs.debian.org/780450 >.
This commit is contained in:
Petter Reinholdtsen 2026-04-23 07:31:33 +02:00
parent 8762d6c667
commit 2b9920e6a5
1 changed files with 1 additions and 1 deletions

View File

@ -174,7 +174,7 @@ int Io_WritePla( Abc_Ntk_t * pNtk, char * pFileName )
FILE * pFile;
assert( Abc_NtkIsSopNetlist(pNtk) );
assert( Abc_NtkLevel(pNtk) == 1 );
assert( Abc_NtkLevel(pNtk) <= 1 );
pFile = fopen( pFileName, "w" );
if ( pFile == NULL )