Skip to content

ABC aborts with an assertion failure in Gia_ManChoiceLevel when running dch #528

Description

@zhihaoxu1325

ABC aborts with an assertion failure in Gia_ManChoiceLevel when running dch followed by &get; &if -K 4 on the attached combinational AIGER testcase.

The crash is reproducible with the current locally built ABC:

UC Berkeley, ABC 1.01 (compiled Jun 25 2026 20:02:32)

Reproducer

Input testcase:

input.po-set-reduced.aag
input.po-set-reduced.aig

The ASCII AIGER header is:

aag 10301 192 0 1 10109

Command:

abc -c "read input.po-set-reduced.aig; strash; dch; &get; &if -K 4"

The same failure also reproduces with dch -f:

abc -c "read input.po-set-reduced.aig; strash; dch -f; &get; &if -K 4"

Actual Behavior

ABC aborts:

abc: src/aig/gia/giaIf.c:836: Gia_ManChoiceLevel: Assertion `Gia_ObjLevel(p, pObj) > 0' failed.
Aborted (core dumped)

In shell, the command exits with status 134. In Python subprocess, this appears as signal return code -6.

Expected Behavior

ABC should not abort on a valid combinational AIGER input. If the command sequence is unsupported for this network, ABC should return a normal error instead of hitting an internal assertion.

Additional Notes

The shortest command sequence I found is:

abc -c "read input.po-set-reduced.aig; strash; dch; &get; &if -K 4"

Without dch, the command does not hit this assertion:

abc -c "read input.po-set-reduced.aig; strash; &get; &if -K 4"

The failure is not specific to K=4; it reproduced for K=2,3,4,5,6,8 on the original testcase.

repro-1.zip

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions