Using inline assembler is it possible to write a function to add or subtract 2 quad integers as if they were unsigned?
The function should receive 2 PB quad integer as parameters and return the result as quad integer.
Something like:
Same to subtract 2 numbers.
If simpler, it's ok even to use a sub, pass the first parameter byref and receive the result in it.
Addition and subtraction should be done ignoring that quad in PB are signed, so the bit 63 is used to represents negative numbers.
Thank you!
The function should receive 2 PB quad integer as parameters and return the result as quad integer.
Something like:
Code:
function addquad(byval a as quad, byval b as quad) as quad local result as quad ! some inline assembler to add a + b giving result function=result end function
If simpler, it's ok even to use a sub, pass the first parameter byref and receive the result in it.
Addition and subtraction should be done ignoring that quad in PB are signed, so the bit 63 is used to represents negative numbers.
Thank you!
Comment