Merge pull request #462 from YosysHQ/upstreaming

Upstreaming YosysHQ changes
This commit is contained in:
alanminko 2025-12-24 07:24:07 -08:00 committed by GitHub
commit e57bd52127
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 10 additions and 2 deletions

View File

@ -562,7 +562,7 @@ Gia_Man_t * Gia_ManPerformMfs( Gia_Man_t * p, Sfm_Par_t * pPars )
{
Sfm_Ntk_t * pNtk;
Gia_Man_t * pNew;
int nFaninMax, nNodes;
int nFaninMax, nNodes = 0;
assert( Gia_ManRegNum(p) == 0 );
assert( p->vMapping != NULL );
if ( p->pManTime != NULL && p->pAigExtra == NULL )

View File

@ -2844,6 +2844,10 @@ int CmdCommandSolver( Abc_Frame_t * pAbc, int argc, char **argv )
goto usage;
}
#if defined(__wasm)
fprintf( pAbc->Err, "Unsupported command.\n" );
return 1;
#else
// Check if solver binary exists in current directory or PATH
char * pSolverName;
if ( (pFile = fopen( "./solver", "r" )) != NULL )
@ -2913,7 +2917,7 @@ int CmdCommandSolver( Abc_Frame_t * pAbc, int argc, char **argv )
// Clean up the temporary file
unlink( TempFileName );
#endif
return 0;
usage:

View File

@ -1103,7 +1103,11 @@ tn_vi * Tn_SolveSat( const char * pFileNameIn, const char * pFileNameOut, int Se
sprintf( pCommand, "%s --seed=%d %s %s > %s", pKissat, Seed, fVerboseSolver ? "": "-q", pFileNameIn, pFileNameOut );
//if ( fVerbose )
// printf( "Running command line: %s\n", pCommand );
#if defined(__wasm)
if ( 1 )
#else
if ( system( pCommand ) == -1 )
#endif
{
printf( "Command \"%s\" did not succeed.\n", pCommand );
return 0;