Quote:
Originally Posted by nogginthenog
AmigaOS ROM calls work this way via the inlines.
Code:
void MyFunc(register int d0 __asm("d0"));
results in:
Code:
moveq #2,d0
jsr _MyFunc
|
Yes, but in this case they don't:
Code:
C:/Users/Me/Desktop/AmigaDevelopment/test/test.c:57:38: error: expected ';', ',' or ')' before '__asm'
for the code:
Code:
void AquireLock(register BYTE * lock __asm("a0"));
and:
Code:
AquireLock(&tripleBufferedDisplay->displayFlippingLock);
Makes me think there's something missing, either in GCC 8.3 or in my code.
I've worked around this situation by using GCC's extended inline assembly:
Code:
{
register BYTE * lock asm ("a0") = &tripleBufferedDisplay->displayFlippingLock;
asm volatile (
"jsr _ReleaseLock"
:
: "r" (lock)
);
}
but that's not an easily maintainable solution.