Hello Thomas, On Mon, 16 Aug 2021 at 23:39, Thorsten Glaser <tg@xxxxxxxxxx> wrote: > > Hi, > > I hope I’m right here, I wasn’t sure whether Bugzilla is also for > feature requests. > > syscall(2) on my Debian systems has these wonderful tables for the > calling conventions on all kinds of CPU architectures. I often have > to debug various things in various libcs on various platforms for > various bugs ☺ and would love it if this information could somehow > be extended by the relevant userspace calling conventions (so I can > read “foreign”, i.e. not i8086/i386 Intel, assembly more easily, > figure out the bugs in their {,sig}{set,long}jmp implementations, > write patches without extra digging, etc. > > I’m aware that linux-man is probably more kernel-oriented and > conventions can differ by libcs (e.g. I’ve seen libcs that use > a regparm convention on i386), but the “standard” case should > be sufficiently on topic (especially as I think the vDSO would > also use these conventions). > > Things like, what arguments go into which registers, which are > saved by who, etc. So, the manual page already has the info below. And from your mail above, it's not immediately clear to me what you would like to see added. Could you provide a concrete example for a specific architecture? Thanks, Michael === Arch/ABI arg1 arg2 arg3 arg4 arg5 arg6 arg7 Notes ────────────────────────────────────────────────────────────── alpha a0 a1 a2 a3 a4 a5 - arc r0 r1 r2 r3 r4 r5 - arm/OABI r0 r1 r2 r3 r4 r5 r6 arm/EABI r0 r1 r2 r3 r4 r5 r6 arm64 x0 x1 x2 x3 x4 x5 - blackfin R0 R1 R2 R3 R4 R5 - i386 ebx ecx edx esi edi ebp - ia64 out0 out1 out2 out3 out4 out5 - m68k d1 d2 d3 d4 d5 a0 - microblaze r5 r6 r7 r8 r9 r10 - mips/o32 a0 a1 a2 a3 - - - 1 mips/n32,64 a0 a1 a2 a3 a4 a5 - nios2 r4 r5 r6 r7 r8 r9 - parisc r26 r25 r24 r23 r22 r21 - powerpc r3 r4 r5 r6 r7 r8 r9 powerpc64 r3 r4 r5 r6 r7 r8 - riscv a0 a1 a2 a3 a4 a5 - s390 r2 r3 r4 r5 r6 r7 - s390x r2 r3 r4 r5 r6 r7 - superh r4 r5 r6 r7 r0 r1 r2 sparc/32 o0 o1 o2 o3 o4 o5 - sparc/64 o0 o1 o2 o3 o4 o5 - tile R00 R01 R02 R03 R04 R05 - x86-64 rdi rsi rdx r10 r8 r9 - x32 rdi rsi rdx r10 r8 r9 - xtensa a6 a3 a4 a5 a8 a9 - -- Michael Kerrisk Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/ Linux/UNIX System Programming Training: http://man7.org/training/