跳到主要内容

PTO-ARCH-SYSTEM-REGISTERS-INTERRUPT

PTO-ARCH-SYSTEM-REGISTERS-INTERRUPT

ASL 伪代码

下面直接显示完整的 ASL 所有者。

// PTO-UNIT: {"id":"PTO-ARCH-SYSTEM-REGISTERS-INTERRUPT","surface":"arch","classification":["system-registers","interrupt"],"depends_on":["PTO-ARCH-SYSTEM-REGISTERS-TIMER"]}func RefreshTopPendingInterrupt(ring: AccessControlRing)begin    let pending = _ExtendedSystemRegisters[[        ContextRegisterIndex(ring, 0x0f08)]];    var found = FALSE;    var top: InterruptID = 0;    for interrupt_id = 0 to 63 do        if !found && pending[interrupt_id] == '1' then            top = interrupt_id as InterruptID;            found = TRUE;        end;    end;    _ExtendedSystemRegisters[[ContextRegisterIndex(ring, 0x0f09)]] =        NaturalToWord(top as integer {0..262144});end;
func SetInterruptPending(ring: AccessControlRing,                         interrupt_id: InterruptID)begin    let index = ContextRegisterIndex(ring, 0x0f08);    _ExtendedSystemRegisters[[index]][interrupt_id] = '1';    RefreshTopPendingInterrupt(ring);end;
func ClearInterruptPending(ring: AccessControlRing,                           interrupt_id: InterruptID)begin    let index = ContextRegisterIndex(ring, 0x0f08);    _ExtendedSystemRegisters[[index]][interrupt_id] = '0';    RefreshTopPendingInterrupt(ring);end;
readonly func InterruptEnabled(ring: AccessControlRing,                               interrupt_id: InterruptID) => booleanbegin    let interrupt_config = _ExtendedSystemRegisters[[        ContextRegisterIndex(ring, 0x0f07)]];    if interrupt_id == TimerInterruptId(ring) then        return interrupt_config[1] == '1';    else return interrupt_config[0] == '1';    end;end;
func ReadInterruptPending(ring: AccessControlRing) => Wordbegin    RefreshTimerPending(ring);    return _ExtendedSystemRegisters[[ContextRegisterIndex(ring, 0x0f08)]];end;
func ReadTopPendingInterrupt(ring: AccessControlRing) => Wordbegin    RefreshTimerPending(ring);    return _ExtendedSystemRegisters[[ContextRegisterIndex(ring, 0x0f09)]];end;
func EndOfInterrupt(ring: AccessControlRing, value: Word)begin    if value[63:6] == Zeros{58} then        ClearInterruptPending(ring, UInt(value[5:0]) as InterruptID);    end;    _ACRTrapAsynchronous[[ring]] = FALSE;    _ACRTrapArgumentValid[[ring]] = FALSE;end;

架构行为

目的与范围

用途与范围

本单元拥有待处理中断更新、最高优先待处理中断选择、使能检查、读取时的定时器刷新以及中断结束状态变化。

概念与架构状态

本页使用的上下文寄存器布局

对每个 ACR,低位索引 0x0f07 保存中断配置,0x0f08 保存待处理中断位图,0x0f09 保存选中的最高优先待处理中断 ID。

RefreshTopPendingInterrupt 从中断 ID 0 扫描到 63,并记录第一个被置位的 ID。如果没有位被置位,保存的最高优先值保持为 0。

规则与交互

待处理、使能与读取行为

SetInterruptPending 设置一个待处理位;ClearInterruptPending 清除一个待处理位。两者都会立即重新计算最高优先待处理中断值。

InterruptEnabled 对该环的定时器中断检查配置位 1,对其他每个中断 ID 检查位 0。

ReadInterruptPending 和 ReadTopPendingInterrupt 在返回各自的上下文寄存器值之前调用 RefreshTimerPending。

边界与未定义范围

中断结束边界

只有输入的位 63:6 都为零时,EndOfInterrupt 才清除一个待处理中断;此时低六位选择 ID。无论编码检查结果如何,它都会清除该环的 _ACRTrapAsynchronous 和 _ACRTrapArgumentValid。

单独的最高优先待处理中断值 0 无法区分“没有待处理中断”和“中断 ID 0 待处理”;待处理中断位图才提供该信息。

使用示例

示例性优先级示例

如果待处理中断 ID 5 和 9 同时被置位,刷新会记录 5,因为扫描在第一个置位处停止。清除 ID 5 后,最高优先值重新计算为 9。

NDF 条款

正文来自 owning ASL。拖拽或按钮只临时改变当前页面显示顺序。

No NDF clause is attached to this unit.

Evidence index

12 matching entries

Executable evidence2
  • PTO-ARCH-SYSTEM-REGISTERS-INTERRUPT compiles as an independent normative unit
    1. surfaceARCH
    2. ownerPTO-ARCH-SYSTEM-REGISTERS-INTERRUPT
    3. categorySTATIC-INVARIANT
    4. case001
    Show exact test source
    Sources and references
    Complete stable ID
    PTO-AVS-ARCH-SYSTEM-REGISTERS-INTERRUPT-STATIC-001
    Path
    tests/asl/arch/system-registers/interrupt/arch-static-interrupt-contract-001.asl
    Kind / role
    static-invariant
    Pass condition
    the complete model and this unit's static invariant compile
    SHA-256
    95732ad1696857b64611f72d130cd82f331b7711b2c68d7b6595a832d9645166
    Open exact source ↗ for PTO-AVS-ARCH-SYSTEM-REGISTERS-INTERRUPT-STATIC-001
  • Covers Interrupt Register State.
    1. surfaceARCH
    2. ownerPTO-ARCH-SYSTEM-REGISTERS-INTERRUPT
    3. categorySTATE-TRANSITION
    4. case001
    Show exact test source
    Sources and references
    Complete stable ID
    PTO-AVS-ARCH-TESTINTERRUPTREGISTERSTATE-STATE-TRANSITION-001
    Path
    tests/asl/arch/system-registers/interrupt/arch-state-register-001.asl
    Kind / role
    state-transition
    Pass condition
    TestInterruptRegisterState completes without assertion failure
    SHA-256
    a64d42334a45d3834287228bb415e2c1d492d7d90323b099bea087aae3f7c78f
    Open exact source ↗ for PTO-AVS-ARCH-TESTINTERRUPTREGISTERSTATE-STATE-TRANSITION-001
Commit-scoped evidence5
  • spec/evidence/release-traceability-readiness.json · closedPTO-EVIDENCE-RELEASE-TRACEABILITY
    Sources and references
    Complete stable ID
    PTO-EVIDENCE-RELEASE-TRACEABILITY
    Path
    spec/evidence/release-traceability-readiness.json
    Kind / role
    ASL/NDF/documentation/AVS traceability
    SHA-256
    c7327021d39dc67ac5564bc55073b3870a397d79ac8d9648284d56e33bc14a3e
    Open exact source ↗ for PTO-EVIDENCE-RELEASE-TRACEABILITY
  • spec/evidence/instruction-contract-closure.json · closedPTO-EVIDENCE-INSTRUCTION-CONTRACT-CLOSURE
    Sources and references
    Complete stable ID
    PTO-EVIDENCE-INSTRUCTION-CONTRACT-CLOSURE
    Path
    spec/evidence/instruction-contract-closure.json
    Kind / role
    mnemonic and encoding contract closure
    SHA-256
    3ef2bb62421c79dff8fa77a1c7983923b523244b8090812883ef81286ca8106a
    Open exact source ↗ for PTO-EVIDENCE-INSTRUCTION-CONTRACT-CLOSURE
  • spec/evidence/architecture-readiness.json · openPTO-EVIDENCE-ARCHITECTURE-READINESS
    Sources and references
    Complete stable ID
    PTO-EVIDENCE-ARCHITECTURE-READINESS
    Path
    spec/evidence/architecture-readiness.json
    Kind / role
    architecture maturity and blockers
    SHA-256
    4b0b85199101251bea744e0f3591cc31906909dc80d5ab651c417a936036a004
    Open exact source ↗ for PTO-EVIDENCE-ARCHITECTURE-READINESS
  • spec/evidence/release-gate-readiness.json · ready-for-exact-head-verificationPTO-EVIDENCE-RELEASE-GATE-READINESS
    Sources and references
    Complete stable ID
    PTO-EVIDENCE-RELEASE-GATE-READINESS
    Path
    spec/evidence/release-gate-readiness.json
    Kind / role
    exact-head gate readiness
    SHA-256
    a0f4d2b6920c08981ea55fd8ef820708a40d4feb5402c5150e8e9ab532d84ce0
    Open exact source ↗ for PTO-EVIDENCE-RELEASE-GATE-READINESS
  • spec/release-manifest.json · draftPTO-EVIDENCE-RELEASE-MANIFEST
    Sources and references
    Complete stable ID
    PTO-EVIDENCE-RELEASE-MANIFEST
    Path
    spec/release-manifest.json
    Kind / role
    release content and encoding fingerprints
    SHA-256
    1a64c109ed7a90351c41e2a418b3c0ebaf8ad975838986d2101385186b85c0d8
    Open exact source ↗ for PTO-EVIDENCE-RELEASE-MANIFEST
Decision history5
  • Use PTO-owned system-register names · accepted
    1. decision recordADR
    2. case0003

    Decision record

    Loading ADR-0003…

    Sources and references
    Complete stable ID
    ADR-0003
    Path
    docs/status/decisions/0003-pto-owned-system-register-names.md
    Affected units
    PTO-ARCH-SYSTEM-REGISTERS-ACCESS-CONTROL, PTO-ARCH-SYSTEM-REGISTERS-ADDRESSING, PTO-ARCH-SYSTEM-REGISTERS-CONTEXT, PTO-ARCH-SYSTEM-REGISTERS-INTERRUPT, PTO-ARCH-SYSTEM-REGISTERS-MAINTENANCE, PTO-ARCH-SYSTEM-REGISTERS-TIMER, PTO-SCALAR-C-SSRGET, PTO-SCALAR-HL-SSRGET, PTO-SCALAR-HL-SSRSET, PTO-SCALAR-SSRGET, PTO-SCALAR-SSRSET, PTO-SCALAR-SSRSWAP
    Affected NDF
    PTO-C-SSRGET-DIRECT-IDS-001, PTO-HL-SSRGET-DECISION-BINDING-001, PTO-HL-SSRSET-DECISION-BINDING-001, PTO-SSRGET-ADR-CONTRACT-001, PTO-SSRSET-ADR-CONTRACT-001, PTO-SSRSWAP-ADR-CONTRACT-001
    SHA-256
    c6a5379776c3b29c25f0896bc56f84d8f5c15832bbba0859b822aa99a65e342d
    Open exact decision source ↗ for ADR-0003
  • PTO v0 ACR routing and context reset · accepted
    1. decision recordADR
    2. case0010

    Decision record

    Loading ADR-0010…

    Sources and references
    Complete stable ID
    ADR-0010
    Path
    docs/status/decisions/0010-acr-routing-and-context-reset.md
    Affected units
    PTO-ARCH-PROFILE-RESET, PTO-ARCH-PROGRAMMING-MODEL-EXECUTION-CONTEXT, PTO-ARCH-SYSTEM-REGISTERS-ACCESS-CONTROL, PTO-ARCH-SYSTEM-REGISTERS-ADDRESSING, PTO-ARCH-SYSTEM-REGISTERS-CONTEXT, PTO-ARCH-SYSTEM-REGISTERS-INTERRUPT, PTO-ARCH-SYSTEM-REGISTERS-MAINTENANCE, PTO-ARCH-SYSTEM-REGISTERS-TIMER
    Affected NDF
    PTO-REQ-STATE-001
    SHA-256
    7594432a33c54880227fa3ab495bf5b29d406ac3b4e83634ffefe0a713e85f35
    Open exact decision source ↗ for ADR-0010
  • Define interrupt pending and timer state · accepted
    1. decision recordADR
    2. case0016

    Decision record

    Loading ADR-0016…

    Sources and references
    Complete stable ID
    ADR-0016
    Path
    docs/status/decisions/0016-interrupt-pending-and-timer-state.md
    Affected units
    PTO-ARCH-OVERVIEW-ARCHITECTURE, PTO-ARCH-SYSTEM-REGISTERS-INTERRUPT, PTO-ARCH-SYSTEM-REGISTERS-TIMER
    Affected NDF
    PTO-ARCH-COMMIT-EVENT-CONFORMANCE-001, PTO-ARCH-STATE-CLOSURE-001, PTO-RELEASE-VERIFICATION, PTO-SOURCE-HIERARCHY, PTO-TILE-CAPACITY-PER-PE
    SHA-256
    d864e76e1cd097d55d05e36cc28adc756a2b2cc46df5720a6f6afa5b3f9b9fe0
    Open exact decision source ↗ for ADR-0016
  • Classify every visible system register behavior · accepted
    1. decision recordADR
    2. case0017

    Decision record

    Loading ADR-0017…

    Sources and references
    Complete stable ID
    ADR-0017
    Path
    docs/status/decisions/0017-system-register-behavior-classes.md
    Affected units
    PTO-ARCH-OVERVIEW-ARCHITECTURE, PTO-ARCH-SYSTEM-REGISTERS-ACCESS-CONTROL, PTO-ARCH-SYSTEM-REGISTERS-ADDRESSING, PTO-ARCH-SYSTEM-REGISTERS-CONTEXT, PTO-ARCH-SYSTEM-REGISTERS-INTERRUPT, PTO-ARCH-SYSTEM-REGISTERS-MAINTENANCE, PTO-ARCH-SYSTEM-REGISTERS-TIMER
    Affected NDF
    PTO-ARCH-COMMIT-EVENT-CONFORMANCE-001, PTO-ARCH-STATE-CLOSURE-001, PTO-RELEASE-VERIFICATION, PTO-SOURCE-HIERARCHY, PTO-TILE-CAPACITY-PER-PE
    SHA-256
    6b4f7a29546952e4c5c61b0f4f921b04ecbc8340ba4ad86619277f17da97f95f
    Open exact decision source ↗ for ADR-0017
  • Scalar SYS totality and PTO-v0 profile boundaries · accepted
    1. decision recordADR
    2. case0031

    Decision record

    Loading ADR-0031…

    Sources and references
    Complete stable ID
    ADR-0031
    Path
    docs/status/decisions/0031-scalar-sys-totality-and-profile-boundaries.md
    Affected units
    PTO-ARCH-SYSTEM-REGISTERS-ACCESS-CONTROL, PTO-ARCH-SYSTEM-REGISTERS-ADDRESSING, PTO-ARCH-SYSTEM-REGISTERS-CONTEXT, PTO-ARCH-SYSTEM-REGISTERS-INTERRUPT, PTO-ARCH-SYSTEM-REGISTERS-MAINTENANCE, PTO-ARCH-SYSTEM-REGISTERS-TIMER, PTO-SCALAR-ACRC, PTO-SCALAR-ACRE, PTO-SCALAR-ASSERT, PTO-SCALAR-BC-IALL, PTO-SCALAR-BC-IVA, PTO-SCALAR-BSE, PTO-SCALAR-BWE, PTO-SCALAR-BWI, PTO-SCALAR-BWT, PTO-SCALAR-C-EBREAK, PTO-SCALAR-C-SSRGET, PTO-SCALAR-DC-CISW, PTO-SCALAR-DC-CIVA, PTO-SCALAR-DC-CSW, PTO-SCALAR-DC-CVA, PTO-SCALAR-DC-IALL, PTO-SCALAR-DC-ISW, PTO-SCALAR-DC-IVA, PTO-SCALAR-DC-ZVA, PTO-SCALAR-EBREAK, PTO-SCALAR-FENCE-D, PTO-SCALAR-FENCE-I, PTO-SCALAR-HL-SSRGET, PTO-SCALAR-HL-SSRSET, PTO-SCALAR-IC-IALL, PTO-SCALAR-IC-IVA, PTO-SCALAR-LSRGET, PTO-SCALAR-SETC-TGT, PTO-SCALAR-SSRGET, PTO-SCALAR-SSRSET, PTO-SCALAR-SSRSWAP, PTO-SCALAR-TLB-IA, PTO-SCALAR-TLB-IALL, PTO-SCALAR-TLB-IAV, PTO-SCALAR-TLB-IV
    Affected NDF
    PTO-ACRC-DECISION-BINDING-001, PTO-ACRE-IMPLICIT-STOP-001, PTO-BSE-DECISION-BINDING-001, PTO-BWE-DECISION-BINDING-001, PTO-BWI-DECISION-BINDING-001, PTO-BWT-DECISION-BINDING-001, PTO-C-EBREAK-CAUSE-001, PTO-C-SSRGET-DIRECT-IDS-001, PTO-EBREAK-DECISION-BINDING-001, PTO-FENCE-D-DECISION-BINDING-001, PTO-FENCE-I-DECISION-BINDING-001, PTO-HL-SSRGET-DECISION-BINDING-001, PTO-HL-SSRSET-DECISION-BINDING-001, PTO-LSRGET-BARG-001, PTO-SETC-TGT-ADR-CONTRACT-001, PTO-SSRGET-ADR-CONTRACT-001, PTO-SSRSET-ADR-CONTRACT-001, PTO-SSRSWAP-ADR-CONTRACT-001, PTO-TLB-IA-ADR-CONTRACT-001, PTO-TLB-IALL-ADR-CONTRACT-001, PTO-TLB-IAV-ADR-CONTRACT-001, PTO-TLB-IV-ADR-CONTRACT-001
    SHA-256
    5680b3516be6c28a1ccb198c99f5efb66317c65330f6d87434173024d2795a7d
    Open exact decision source ↗ for ADR-0031

Unit metadata

Open 4 generated metadata fields
id
PTO-ARCH-SYSTEM-REGISTERS-INTERRUPT
surface
arch
classification
[
  "system-registers",
  "interrupt"
]
depends_on
[
  "PTO-ARCH-SYSTEM-REGISTERS-TIMER"
]
Open generated traceability record
{
  "classification": [
    "system-registers",
    "interrupt"
  ],
  "documentation": "docs/arch/system-registers/interrupt.md",
  "id": "PTO-ARCH-SYSTEM-REGISTERS-INTERRUPT",
  "mnemonic": null,
  "readiness_subjects": [
    "ADR-0003",
    "ADR-0010",
    "ADR-0016",
    "ADR-0017",
    "ADR-0031"
  ],
  "semantic_tests": [
    "PTO-AVS-ARCH-TESTINTERRUPTREGISTERSTATE-STATE-TRANSITION-001"
  ],
  "source": "asl/arch/system-registers/interrupt.asl",
  "surface": "arch",
  "tests": [
    "PTO-AVS-ARCH-SYSTEM-REGISTERS-INTERRUPT-STATIC-001",
    "PTO-AVS-ARCH-TESTINTERRUPTREGISTERSTATE-STATE-TRANSITION-001"
  ]
}

来源与发布信息

展开 commit、路径、hash、版本和规范所有者
发布
0.58.5 · 候选发布
Commit
7dc8b7e5b121d2b2499a2273bebff29e2cd86812
ASL SHA-256
2341ac0204294c8619bbfc70f514e70f535ff7bc1ddb3d799639378d5071af34
文档 SHA-256
d38e6dcd6a6abc8d919fef40ce6dbc868a5e3b5c314533cd065482e65a1d4cff

精确所有者