@@ -371,7 +371,7 @@ def prove_it(id_and_cfg: Tuple[str, Tuple[KCFG, Path]]) -> bool:
371
371
iterations += 1
372
372
curr_node = cfg .frontier [0 ]
373
373
cfg .add_expanded (curr_node .id )
374
- _LOGGER .info (f'Advancing proof from node: { shorten_hashes (curr_node .id )} ' )
374
+ _LOGGER .info (f'Advancing proof from node { cfgid } : { shorten_hashes (curr_node .id )} ' )
375
375
edge = KCFG .Edge (curr_node , target_node , mlTop (), - 1 )
376
376
claim = edge .to_claim ()
377
377
claim_id = f'gen-{ curr_node .id } -to-{ target_node .id } '
@@ -382,35 +382,35 @@ def prove_it(id_and_cfg: Tuple[str, Tuple[KCFG, Path]]) -> bool:
382
382
if result == mlTop ():
383
383
cfg .create_edge (curr_node .id , target_node .id , mlTop (), depth )
384
384
_LOGGER .info (
385
- f'Target state reached at depth { depth } , inserted edge from { shorten_hashes ((curr_node .id )) } to { shorten_hashes (( target_node .id ))} .'
385
+ f'Target state reached at depth { depth } for { cfgid } : { shorten_hashes ((curr_node .id , target_node .id ))} .'
386
386
)
387
387
388
388
else :
389
389
next_state = CTerm (sanitize_config (foundry .definition , result ))
390
390
next_node = cfg .get_or_create_node (next_state )
391
391
if next_node != curr_node :
392
- _LOGGER .info (f'Found basic block at depth { depth } : { shorten_hashes ((curr_node .id , next_node .id ))} .' )
392
+ _LOGGER .info (f'Found basic block at depth { depth } for { cfgid } : { shorten_hashes ((curr_node .id , next_node .id ))} .' )
393
393
cfg .create_edge (curr_node .id , next_node .id , mlTop (), depth )
394
394
395
395
if KEVM .is_terminal (next_node .cterm ):
396
396
cfg .add_expanded (next_node .id )
397
- _LOGGER .info (f'Terminal node: { shorten_hashes ((curr_node .id ))} .' )
397
+ _LOGGER .info (f'Terminal node { cfgid } : { shorten_hashes ((curr_node .id ))} .' )
398
398
399
399
elif branching :
400
400
branches = KEVM .extract_branches (next_state )
401
401
if not branches :
402
402
raise ValueError (
403
- f'Could not extract branch condition:\n { foundry .pretty_print (minimize_term (result ))} '
403
+ f'Could not extract branch condition { cfgid } :\n { foundry .pretty_print (minimize_term (result ))} '
404
404
)
405
405
cfg .add_expanded (next_node .id )
406
406
_LOGGER .info (
407
- f'Found { len (list (branches ))} branches at depth { depth } : { [foundry .pretty_print (b ) for b in branches ]} '
407
+ f'Found { len (list (branches ))} branches at depth { depth } for { cfgid } : { [foundry .pretty_print (b ) for b in branches ]} '
408
408
)
409
409
for branch in branches :
410
410
branch_cterm = next_state .add_constraint (branch )
411
411
branch_node = cfg .get_or_create_node (branch_cterm )
412
412
cfg .create_edge (next_node .id , branch_node .id , branch , 0 )
413
- _LOGGER .info (f'Made split: { shorten_hashes ((next_node .id , branch_node .id ))} ' )
413
+ _LOGGER .info (f'Made split for { cfgid } : { shorten_hashes ((next_node .id , branch_node .id ))} ' )
414
414
# TODO: have to store case splits as rewrites because of how frontier is handled for covers
415
415
# cfg.create_cover(branch_node.id, next_node.id)
416
416
# _LOGGER.info(f'Made cover: {shorten_hashes((branch_node.id, next_node.id))}')
0 commit comments