Part Number: AM3358
Tool/software: TI C/C++ Compiler
Hi,
We are trying to read value of LR register into a C variable, for which we used below mentioned inline function, but are getting error #18: expected a ")".
__attribute__( ( always_inline ) ) __STATIC_INLINE VCI_UINT32 __get_LR(void)
{
register VCI_UINT32 result;
__ASM volatile ("MOV %0, lr\n\t" : "=r" (result));
return(result);
}
We referred similar query, linked below, but was unable to understand provided solution:
It would be a great help if you could provide us an example code for the same.