用IAR的Intrinsic 函数 :
void __bic_SR_register(unsigned short);// Clears bits in the SR register
void __bic_SR_register_on_exit(unsigned short);/ Clears bits in the SR register when an interrupt
// or monitor function returns
void __bis_SR_register(unsigned short);// Sets bits in the SR register
void __bis_SR_register_on_exit(unsigned short);// Sets bits in the SR register when an interrupt or
//monitor function returns
unsigned short __get_SR_register();// Returns the value of the SR register
unsigned short __get_SR_register_on_exit();// Returns the value that the processor status
//register will h××e when the current interrupt or
//monitor function returns