This is the mail archive of the
mailing list for the binutils project.
Re: How can I do calling for external address in my "C" programm by inline GAS?
Ian Lance Taylor wrote:
> In this code p_printf is the address of the printf function. You are
> running your asm with the value of p_printf in %1. Rather than putting
> the value into a register, you are putting the address of the value into
> a register. In effect you are putting an address on the stack into the
> register. Then you are calling that address, which implies calling into
> the stack. This fails.
> In order to get this kind of thing working, I recommend learning how to
> use the debugger, with single-stepping and display of assembly
> instructions. That would make it clear that at the point of the call
> %rcx does not hold the address you want to call.
Thank you for you reply on my letters.
Your tips does not helped me.
I have registered this behavirous as bug:
The best Regards.