Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 28 additions & 2 deletions conformance/sv-tests/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -158,8 +158,34 @@ cases in 2state and 526 in 4state. No passing case regresses: classes that are
declared but never constructed, interface classes and pure virtual methods are
not lowered. `8.7--constructor` keeps failing because it initializes an
implicitly static procedural variable without the `static` keyword, which IEEE
1800-2023 6.21 requires. Inheritance with constructors, `super`, static members,
virtual dispatch and parameterized classes stay unsupported.
1800-2023 6.21 requires; `8.7--constructor_param` fails for the same reason.

Base constructors, `super`, static members and `C::` scope resolution update
eighteen more rows: both state modes for `8.7--constructor_super`,
`8.8--typed_constructor`, `8.9--static_properties`, `8.10--static_methods`,
`8.13--inheritance`, `8.14--override_member`, `8.15--super`,
`8.17--constructor_const_arg` and `8.23--scope_resolution` change from fail to
pass. Each was simulated and its displayed values checked, including the base
method that a base-class handle calls in `8.14--override_member`. Full official
runs at the pinned revision report 534 passing cases in 2state and 536 in
4state, with no passing case regressing. Virtual dispatch, abstract and
interface classes, classes in packages, parameterized classes and shallow copies
stay unsupported.

Virtual methods, abstract classes and classes implementing interface classes
update eighteen more rows: both state modes for `8.15--super-default-new`,
`8.20--virtual_method`, `8.21--abstract_class`, `8.22--dynamic_method_lookup`,
`8.26.2--implements`, `8.26.2--implements_extends`,
`8.26.2--implements_multiple`, `8.26.6.1--name_conflict_resolved` and
`8.26.7--partial_implementation` change from fail to pass. Each was simulated
and its displayed values checked: the override of the object's class runs
through base-class handles and an array of them, and the shadowed property of
`8.20--virtual_method` reads the derived class's value. Full official runs at
the pinned revision report 543 passing cases in 2state and 545 in 4state, with
no passing case regressing. `8.26.6.1--name_conflict_unresolved` stays a
passing negative case: its return types conflict, which is rejected. Calls
through interface class handles, `$cast`, parameterized classes and shallow
copies stay unsupported.

The report contains each case’s state mode, verdict, selected execution mode,
tags, tool return code and path to the official log. The output directory retains
Expand Down
72 changes: 36 additions & 36 deletions conformance/sv-tests/expected.tsv
Original file line number Diff line number Diff line change
Expand Up @@ -1461,26 +1461,26 @@ chapter-7/unions/tagged/packed.sv 2state fail
chapter-7/unions/tagged/packed.sv 4state fail
chapter-7/unions/unpacked/basic.sv 2state fail
chapter-7/unions/unpacked/basic.sv 4state fail
chapter-8/8.10--static_methods.sv 2state fail
chapter-8/8.10--static_methods.sv 4state fail
chapter-8/8.10--static_methods.sv 2state pass
chapter-8/8.10--static_methods.sv 4state pass
chapter-8/8.11--this.sv 2state pass
chapter-8/8.11--this.sv 4state pass
chapter-8/8.12--assignment.sv 2state pass
chapter-8/8.12--assignment.sv 4state pass
chapter-8/8.12--shallow_copy.sv 2state fail
chapter-8/8.12--shallow_copy.sv 4state fail
chapter-8/8.13--inheritance.sv 2state fail
chapter-8/8.13--inheritance.sv 4state fail
chapter-8/8.14--override_member.sv 2state fail
chapter-8/8.14--override_member.sv 4state fail
chapter-8/8.15--super-default-new.sv 2state fail
chapter-8/8.15--super-default-new.sv 4state fail
chapter-8/8.15--super.sv 2state fail
chapter-8/8.15--super.sv 4state fail
chapter-8/8.13--inheritance.sv 2state pass
chapter-8/8.13--inheritance.sv 4state pass
chapter-8/8.14--override_member.sv 2state pass
chapter-8/8.14--override_member.sv 4state pass
chapter-8/8.15--super-default-new.sv 2state pass
chapter-8/8.15--super-default-new.sv 4state pass
chapter-8/8.15--super.sv 2state pass
chapter-8/8.15--super.sv 4state pass
chapter-8/8.16--cast_func.sv 2state fail
chapter-8/8.16--cast_func.sv 4state fail
chapter-8/8.17--constructor_const_arg.sv 2state fail
chapter-8/8.17--constructor_const_arg.sv 4state fail
chapter-8/8.17--constructor_const_arg.sv 2state pass
chapter-8/8.17--constructor_const_arg.sv 4state pass
chapter-8/8.18--var_local.sv 2state pass
chapter-8/8.18--var_local.sv 4state pass
chapter-8/8.18--var_protected.sv 2state pass
Expand All @@ -1489,16 +1489,16 @@ chapter-8/8.19--global_constant.sv 2state pass
chapter-8/8.19--global_constant.sv 4state pass
chapter-8/8.19--instance_constant.sv 2state pass
chapter-8/8.19--instance_constant.sv 4state pass
chapter-8/8.20--virtual_method.sv 2state fail
chapter-8/8.20--virtual_method.sv 4state fail
chapter-8/8.21--abstract_class.sv 2state fail
chapter-8/8.21--abstract_class.sv 4state fail
chapter-8/8.20--virtual_method.sv 2state pass
chapter-8/8.20--virtual_method.sv 4state pass
chapter-8/8.21--abstract_class.sv 2state pass
chapter-8/8.21--abstract_class.sv 4state pass
chapter-8/8.21--abstract_class_inst.sv 2state pass
chapter-8/8.21--abstract_class_inst.sv 4state pass
chapter-8/8.22--dynamic_method_lookup.sv 2state fail
chapter-8/8.22--dynamic_method_lookup.sv 4state fail
chapter-8/8.23--scope_resolution.sv 2state fail
chapter-8/8.23--scope_resolution.sv 4state fail
chapter-8/8.22--dynamic_method_lookup.sv 2state pass
chapter-8/8.22--dynamic_method_lookup.sv 4state pass
chapter-8/8.23--scope_resolution.sv 2state pass
chapter-8/8.23--scope_resolution.sv 4state pass
chapter-8/8.24--out_of_block_methods.sv 2state pass
chapter-8/8.24--out_of_block_methods.sv 4state pass
chapter-8/8.25--parametrized_class_extend.sv 2state fail
Expand All @@ -1507,12 +1507,12 @@ chapter-8/8.25.1--parametrized_class_invalid_scope_resolution.sv 2state pass
chapter-8/8.25.1--parametrized_class_invalid_scope_resolution.sv 4state pass
chapter-8/8.25.1--parametrized_class_scope_resolution.sv 2state fail
chapter-8/8.25.1--parametrized_class_scope_resolution.sv 4state fail
chapter-8/8.26.2--implements.sv 2state fail
chapter-8/8.26.2--implements.sv 4state fail
chapter-8/8.26.2--implements_extends.sv 2state fail
chapter-8/8.26.2--implements_extends.sv 4state fail
chapter-8/8.26.2--implements_multiple.sv 2state fail
chapter-8/8.26.2--implements_multiple.sv 4state fail
chapter-8/8.26.2--implements.sv 2state pass
chapter-8/8.26.2--implements.sv 4state pass
chapter-8/8.26.2--implements_extends.sv 2state pass
chapter-8/8.26.2--implements_extends.sv 4state pass
chapter-8/8.26.2--implements_multiple.sv 2state pass
chapter-8/8.26.2--implements_multiple.sv 4state pass
chapter-8/8.26.3--type_access_extends.sv 2state pass
chapter-8/8.26.3--type_access_extends.sv 4state pass
chapter-8/8.26.3--type_access_implements.sv 2state fail
Expand All @@ -1529,8 +1529,8 @@ chapter-8/8.26.5--implemented_class_handle.sv 2state pass
chapter-8/8.26.5--implemented_class_handle.sv 4state pass
chapter-8/8.26.5--invalid_interface_instantiation.sv 2state pass
chapter-8/8.26.5--invalid_interface_instantiation.sv 4state pass
chapter-8/8.26.6.1--name_conflict_resolved.sv 2state fail
chapter-8/8.26.6.1--name_conflict_resolved.sv 4state fail
chapter-8/8.26.6.1--name_conflict_resolved.sv 2state pass
chapter-8/8.26.6.1--name_conflict_resolved.sv 4state pass
chapter-8/8.26.6.1--name_conflict_unresolved.sv 2state pass
chapter-8/8.26.6.1--name_conflict_unresolved.sv 4state pass
chapter-8/8.26.6.2--parameter_type_conflict.sv 2state pass
Expand All @@ -1541,8 +1541,8 @@ chapter-8/8.26.6.3--diamond_relationship.sv 2state pass
chapter-8/8.26.6.3--diamond_relationship.sv 4state pass
chapter-8/8.26.6.3--diamond_relationship_parametrized.sv 2state fail
chapter-8/8.26.6.3--diamond_relationship_parametrized.sv 4state fail
chapter-8/8.26.7--partial_implementation.sv 2state fail
chapter-8/8.26.7--partial_implementation.sv 4state fail
chapter-8/8.26.7--partial_implementation.sv 2state pass
chapter-8/8.26.7--partial_implementation.sv 4state pass
chapter-8/8.27--forward_declaration.sv 2state pass
chapter-8/8.27--forward_declaration.sv 4state pass
chapter-8/8.4--instantiation.sv 2state pass
Expand All @@ -1559,14 +1559,14 @@ chapter-8/8.7--constructor.sv 2state fail
chapter-8/8.7--constructor.sv 4state fail
chapter-8/8.7--constructor_param.sv 2state fail
chapter-8/8.7--constructor_param.sv 4state fail
chapter-8/8.7--constructor_super.sv 2state fail
chapter-8/8.7--constructor_super.sv 4state fail
chapter-8/8.8--typed_constructor.sv 2state fail
chapter-8/8.8--typed_constructor.sv 4state fail
chapter-8/8.7--constructor_super.sv 2state pass
chapter-8/8.7--constructor_super.sv 4state pass
chapter-8/8.8--typed_constructor.sv 2state pass
chapter-8/8.8--typed_constructor.sv 4state pass
chapter-8/8.8--typed_constructor_param.sv 2state fail
chapter-8/8.8--typed_constructor_param.sv 4state fail
chapter-8/8.9--static_properties.sv 2state fail
chapter-8/8.9--static_properties.sv 4state fail
chapter-8/8.9--static_properties.sv 2state pass
chapter-8/8.9--static_properties.sv 4state pass
chapter-9/9.2.1--initial.sv 2state pass
chapter-9/9.2.1--initial.sv 4state pass
chapter-9/9.2.2.1--always.sv 2state pass
Expand Down
2 changes: 2 additions & 0 deletions crates/celox-frontend-core/src/sdk.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1962,6 +1962,8 @@ pub fn lower_frontend_artifact(
processes,
package_bindings: HashMap::default(),
counter_slots,
pending_slots: Vec::new(),
comb_alternatives: Vec::new(),
wait_sites,
nba_sites,
nba_switches: Vec::new(),
Expand Down
26 changes: 25 additions & 1 deletion crates/celox-frontend-core/src/symbolic/artifact.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ use std::{collections::BTreeSet, fmt};
use celox_design::{
CounterSlots, ExternFunction, InitialStateValue, ModuleId, NbaSite, ProcessSlots,
RegionedAbsoluteAddrBase, RegionedVarAddrBase, RuntimeErrorInfo, RuntimeEventSite, TriggerSet,
VariableMetadata, WaitSite,
VarAtomBase, VariableMetadata, WaitSite,
};
use celox_sir::ExecutionUnit;
use celox_slt::{CombObserver, FfAccessSummary, GlueBlockBase, LogicPath, SLTNodeArena};
Expand Down Expand Up @@ -66,6 +66,24 @@ pub struct SplitCommit<A> {
pub nba: ExecutionUnit<A>,
}

/// A combinational process that `comb_blocks` holds both as symbolic
/// definitions and as an imperative unit. The symbolic form computes only
/// the final value of each written variable; the unit performs every store,
/// so the counters of a watched variable see the intermediate values
/// (IEEE 1800-2023 4.3, 9.4.2). Assembly keeps the unit for an instance in
/// which a variable of `candidates` is counted, and the symbolic
/// definitions otherwise.
#[derive(Clone, Debug)]
pub struct CombAlternative {
/// The `process` of the unit's paths.
pub process: SourceVarId,
/// The ranges the symbolic definitions write; other drivers may write
/// the other bits of the same variables.
pub targets: Vec<VarAtomBase<SourceVarId>>,
/// The variables the unit may store twice in one execution.
pub candidates: Vec<SourceVarId>,
}

#[derive(Clone)]
pub struct SimModule {
/// A frontend's global tick precision; absent for scale-free frontends.
Expand Down Expand Up @@ -117,6 +135,12 @@ pub struct SimModule {
/// `crate::watch::multi_store_candidates`). Assembly counts a signal's
/// occurrences only if a flip-flop domain or a wait watches it.
pub counter_slots: Vec<CounterSlots<SourceVarId>>,
/// Objects that hold the occurrences of a flip-flop's repeated writes
/// to a signal until their commit (see `crate::watch::PendingSlots`).
/// Assembly uses them only for the signals it counts.
pub pending_slots: Vec<crate::watch::PendingSlots<SourceVarId>>,
/// Combinational processes lowered both ways; see [`CombAlternative`].
pub comb_alternatives: Vec<CombAlternative>,
/// Wait sites of the module's processes; `process` indexes
/// [`Self::processes`].
pub wait_sites: Vec<WaitSite<SourceVarId>>,
Expand Down
Loading
Loading