this code compiles and works in 32 bit,
Code: Select all
common shared x as uinteger
function test as long
'***********************************************************************************************
'
'***********************************************************************************************
asm push &H1
asm pop [x]
function = x
end function
test
print str(x)
sleep
but in 64 bit i get this:
D:\Users\Administrator\Desktop\Freebasic\Test.c:26:2: error: 'asm' operand has impossible constraints
__asm__ __volatile__( "POP [%0]" : "+m" (X$) : : "cc", "memory", "rax", "rbx", "rcx", "rdx", "rsp", "rdi", "rsi", "r8", "r9", "r10", "r11", "r12", "r13", "r14",
"r15" );
^
compiling C failed: 'D:\FreeBasic\FB64\bin\win64\gcc.exe' terminated with exit code 1
I want to fill the global variable x (uinteger) with a value (uinteger) currently on the stack, 64 bit allows for 64 bit pushes and pops - so what is wrong?
Thanks,
JK