On 18 May 2015 at 13:23, Saidgani wrote: > Hello. I have a question: How does GCC x64 put parametrs of the function on > C language in stack or registers. In x32 architecture it was simple. all > parametrs of function was put in stack . But in x64 gcc puts some parametrs > in %rdi, %rsi, %r8d, %r9d registers, and some parametrs in stack. How does > it work generally? This is defined by the x86_64 psABI: http://refspecs.linuxfoundation.org/elf/x86-64-abi-0.99.pdf