Open
Description
Added in #38465
This calling convention is used to define interrup handlers on MSP430 microcontrollers. Usage looks like this:
#[no_mangle]
#[link_section = "__interrupt_vector_10"]
pub static TIM0_VECTOR: unsafe extern "msp430-interrupt" fn() = tim0;
unsafe extern "msp430-interrupt" fn tim0() {
P1OUT.write(0x00);
}
which generates the following assembly:
Disassembly of section __interrupt_vector_10:
0000fff2 <TIM0_VECTOR>:
fff2: 10 c0 interrupt service routine at 0xc010
Disassembly of section .text:
0000c010 <_ZN3msp4tim017h3193b957fd6a4fd4E>:
c010: c2 43 21 00 mov.b #0, &0x0021 ;r3 As==00
c014: 00 13 reti
...
Metadata
Metadata
Assignees
Labels
Area: Code for handling the "interrupt ABI" of various processorsBlocker: Implemented in the nightly compiler and unstable.Category: An issue tracking the progress of sth. like the implementation of an RFCStatus: It's hard to tell what's been done and what hasn't! Someone should do some investigation.Relevant to the language team, which will review and decide on the PR/issue.Working group: Embedded systems