Skip to content

Conversation

@mlaveaux
Copy link
Collaborator

Also started with the signature based strong symbolic bisimulation. This is not yet working correctly, and the quotient is also missing.

  • Moved pest_consume to a fork of the original repository, this adds traceability to where 3rd-party dependencies come from, and removed external code from this repo.
  • Move the 3rd party mCRL2 code to its own mcrl2-sys repository. However, it seems that cargo might not work ideal with submodules inside so perhaps this should not be done. Or we can add mcrl2-sys as a submodule itself.
  • Renamed some features for consistency.

@mlaveaux mlaveaux self-assigned this Jan 20, 2026
@mlaveaux mlaveaux added the enhancement New feature or request label Jan 20, 2026
Copilot AI review requested due to automatic review settings January 20, 2026 13:30
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request converts symbolic LTS representation from LDDs to BDDs and begins implementing signature-based strong symbolic bisimulation. The PR also reorganizes third-party dependencies by moving pest_consume and mcrl2-sys to external GitHub repositories.

Changes:

  • Adds BDD-based symbolic LTS representation and conversion from LDD format
  • Implements initial signature refinement algorithm (incomplete)
  • Moves third-party code (pest_consume, mcrl2-sys) to separate repositories
  • Adds new CLI commands to merc-sym tool for symbolic LTS operations
  • Renames mCRL2 features for consistency

Reviewed changes

Copilot reviewed 58 out of 62 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
tools/sym/src/main.rs Adds new CLI interface with commands for info, explore, reorder, convert, and reduce operations on symbolic LTS
crates/symbolic/src/symbolic_lts_bdd.rs New module implementing BDD-based symbolic LTS representation with conversion from LDD format
crates/symbolic/src/sigref.rs New module for signature refinement algorithm (incomplete implementation)
crates/symbolic/src/ldd_to_bdd.rs Refactors LDD to BDD conversion to use explicit variable mapping instead of auto-generated variables
Cargo.toml Updates dependencies to use external repositories for pest_consume and mcrl2-sys
.gitmodules Removes submodules for mCRL2, boost, and cpptrace (moved to mcrl2-sys repo)
3rd-party/* Removes vendored pest_consume and mCRL2-related code
tools/mcrl2/* Removes mcrl2-sys crate (moved to separate repository)

Comment on lines 131 to 147
/// Sets the input symbolic LTS format.
#[arg(long)]
format: Option<LtsFormat>,
Copy link

Copilot AI Jan 20, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The format argument expects SymFormat but the help text says "Sets the input symbolic LTS format", yet the type should be LtsFormat based on the struct name ReduceArgs and the context. This type mismatch will cause compilation errors or incorrect behavior.

Copilot uses AI. Check for mistakes.
Also take cases where there are fixpoint but it is not the first one, such as "<true> nu X ..."
…different levels of the partition and the signature. This was unclear from the pseudocode.
…wice as slow with linking as thin LTO. This is 5 minutes in total on a full rebuild for the GUI tools, and is now 2,5 minutes.
 * It seems that rusty file dialog has been rewritten to drop about 200 dependencies, so that is nice.
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 77 out of 83 changed files in this pull request and generated 8 comments.

Comment on lines 246 to 250
let resulting_ldd = bdd_to_ldd(&mut storage, &manager_ref, &bdd, &bits_dd, 0, 0).unwrap();

println!("resulting LDD: {}", LddDisplay::new(&storage, &resulting_ldd));
assert_eq!(ldd, resulting_ldd, "Converted LDD does not match original");
// assert_eq!(ldd, resulting_ldd, "Converted LDD does not match original");
});
Copy link

Copilot AI Jan 24, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The core correctness assertion in test_random_ldd_to_bdd is commented out, which means this test no longer verifies the LDD↔BDD roundtrip. This likely hides a real regression in ldd_to_bdd/bdd_to_ldd. Please fix the conversion logic so the roundtrip holds again and re-enable the assertion.

Copilot generated this review using guidance from repository custom instructions.
Comment on lines 18 to 22
/// Converts an LDD representing a set of vectors into a BDD representing the
/// same set by bitblasting the vector elements.
pub fn ldd_to_bdd_simple(
storage: &mut Storage,
manager_ref: &BDDManagerRef,
ldd: &LddRef<'_>,
) -> Result<BDDFunction, MercError> {
let highest = compute_highest(storage, ldd);
let bits = compute_bits(&highest);
let bits_dd = merc_ldd::singleton(storage, &bits);

ldd_to_bdd(storage, manager_ref, ldd, &bits_dd, 0)
}

/// Converts an LDD representing a set of vectors into a BDD representing the
/// same set by bitblasting the vector elements.
/// same set by bitblasting the vector elements using the given variables as bits.
///
/// # Details
///
Copy link

Copilot AI Jan 24, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The ldd_to_bdd doc comment is now out of sync with the function signature: it still describes a first_variable parameter and implies consecutive BDD layers, but the API now takes an explicit vars: &[VarNo] mapping. Please update the comment to match the new contract (and remove first_variable references).

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant