Skip to content

Compute gates with path expressions#30

Merged
Casperento merged 12 commits intomainfrom
path-expressions
Aug 4, 2025
Merged

Compute gates with path expressions#30
Casperento merged 12 commits intomainfrom
path-expressions

Conversation

@Casperento
Copy link
Copy Markdown
Collaborator

This pull request introduces significant enhancements to the Daedalus project, focusing on adding a new PHIGateAnalyzer component for advanced control flow analysis, refining the ProgramSlice class for better slicing functionality. Below is a breakdown of the key changes:

New Feature: PHIGateAnalyzer

  • Introduced a new PHIGateAnalyzer class in include/PHIGateAnalyzer.h to analyze and construct gating functions for PHI nodes. This includes support for various path expression types (e.g., EdgeExpr, UnionExpr, ConcatExpr, and SpecialExpr) and implements algorithms from the Tu and Padua paper.
  • Added PHIGateAnalyzer.cpp to the build system in lib/CMakeLists.txt.
  • Reference: https://dl.acm.org/doi/abs/10.1145/207110.207115

Enhancements to ProgramSlice

  • Refactored the ProgramSlice class in include/ProgramSlice.h:
    • Replaced the attractor-based approach with a new "first dominator" model for managing control flow (_firstDominators map).
    • Added methods like computeFirstDominatorsInSlice and getNewTargetByFirstDominator to improve the handling of control flow and PHI nodes.
    • Removed outdated methods and streamlined branch rerouting logic.

These changes collectively improve the project's ability to analyze and manipulate control flow, particularly when dealing with PHI nodes and complex slicing scenarios.

@Casperento Casperento self-assigned this Aug 4, 2025
@Casperento Casperento merged commit 8ccdb75 into main Aug 4, 2025
1 check passed
@Casperento Casperento deleted the path-expressions branch August 4, 2025 21:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant