]>
git.ipfire.org Git - people/ms/linux.git/blob - arch/um/kernel/skas/util/mk_ptregs-x86_64.c
2 * Copyright 2003 PathScale, Inc.
4 * Licensed under the GPL
8 #define __FRAME_OFFSETS
9 #include <asm/ptrace.h>
11 #define PRINT_REG(name, val) \
12 printf("#define HOST_%s (%d / sizeof(unsigned long))\n", (name), (val))
14 int main(int argc
, char **argv
)
16 printf("/* Automatically generated by "
17 "arch/um/kernel/skas/util/mk_ptregs */\n");
19 printf("#ifndef __SKAS_PT_REGS_\n");
20 printf("#define __SKAS_PT_REGS_\n");
21 printf("#define HOST_FRAME_SIZE (%d / sizeof(unsigned long))\n",
23 PRINT_REG("RBX", RBX
);
24 PRINT_REG("RCX", RCX
);
25 PRINT_REG("RDI", RDI
);
26 PRINT_REG("RSI", RSI
);
27 PRINT_REG("RDX", RDX
);
28 PRINT_REG("RBP", RBP
);
29 PRINT_REG("RAX", RAX
);
32 PRINT_REG("R10", R10
);
33 PRINT_REG("R11", R11
);
34 PRINT_REG("R12", R12
);
35 PRINT_REG("R13", R13
);
36 PRINT_REG("R14", R14
);
37 PRINT_REG("R15", R15
);
38 PRINT_REG("ORIG_RAX", ORIG_RAX
);
41 PRINT_REG("EFLAGS", EFLAGS
);
51 printf("#define HOST_FP_SIZE 0\n");
52 printf("#define HOST_XFP_SIZE 0\n");
60 * Overrides for Emacs so that we follow Linus's tabbing style.
61 * Emacs will notice this stuff at the end of the file and automatically
62 * adjust the settings for this buffer only. This must remain at the end
64 * ---------------------------------------------------------------------------
66 * c-file-style: "linux"