I am using the function attributes to handle interrupt in the Atmega32.
I write this
void __vector_1(void) __attribute__((signal)); void __vector_2(void) __attribute__((signal)); void __vector_3(void) __attribute__((signal));
I know that when external interrupt 0 happens, the function '__vector_1' gets called, when external interrupt 1 happens, the function '__vector_2' gets called, and when external interrupt 2 happens, the function '__vector_3' gets called.
The question is
How does the compiler know that it should call the vector_1 function when the external interrupt 0 occurs, and call the vector_2 function when the external interrupt 1 occurs and so on ?
Thank you.