Skip to content

binding_rules: nested-path Actual_Processor_Binding not recognized (applies to fw.firmware) #128

@avrabe

Description

@avrabe

Summary

spar analyze reports threads as "missing required Actual_Processor_Binding" even when the binding is declared at the enclosing system level with the standard dotted-path form (applies to process_name.thread_name).

Reproducer

Fully reproducible against the wohl repo at /Users/r/git/pulseengine/wohl, which has a system with a process containing threads, with bindings declared per AS5506 idiom.

Minimal shape:

processor NRF52840
end NRF52840;

thread DoorFirmware
end DoorFirmware;

process DoorFirmwareProcess
end DoorFirmwareProcess;

process implementation DoorFirmwareProcess.Impl
  subcomponents
    firmware: thread DoorFirmware;
end DoorFirmwareProcess.Impl;

system DoorNode
end DoorNode;

system implementation DoorNode.Battery
  subcomponents
    mcu: processor NRF52840;
    fw: process DoorFirmwareProcess.Impl;
  properties
    Actual_Processor_Binding => (reference (mcu)) applies to fw.firmware;
end DoorNode.Battery;
$ spar analyze --root ... 
[ERROR] binding_rules: thread 'firmware' is missing required Actual_Processor_Binding
        (AS5506 §10.6: threads must be bound to a processor)
        (at DoorNode.Battery/fw/firmware)

AADL reference

AS5506B §8.3 and §10.6 explicitly allow nested-path applies to expressions. The pattern is canonical — every cFS / FPrime AADL example uses it.

Impact

  • Pre-existing spar/wohl_system.aadl in the wohl repo hits the same error for its threads (hub.scheduler, hub.water_mon, ...) even though those bindings are declared.
  • Cannot run schedulability analysis because bindings appear unresolved.
  • Blocks deployment-validation analyses that depend on Actual_Processor_Binding being surfaced.

Expected

binding_rules walks into nested subcomponents and resolves bindings whose applies to uses a dotted path through subcomponent references, producing no error when the referenced thread has a valid binding via any ancestor's property declaration.

Workaround

None that I found. Putting the binding inside the process implementation doesn't help (the process has no reference to the enclosing system's processor subcomponent).

🤖 Generated with Claude Code

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions