There's no need to hard-code the registers, allow the compiler to choose ones that fit. Signed-off-by: Mathias Krause <minipli@xxxxxxxxxxxxxx> --- x86/emulator64.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x86/emulator64.c b/x86/emulator64.c index c58441ca798c..4138eaae00c9 100644 --- a/x86/emulator64.c +++ b/x86/emulator64.c @@ -421,7 +421,7 @@ static uint64_t usr_gs_mov(void) uint64_t ret; dummy_ptr -= GS_BASE; - asm volatile("mov %%gs:(%%rcx), %%rax" : "=a"(ret): "c"(dummy_ptr) :); + asm volatile("mov %%gs:(%1), %0" : "=r"(ret) : "r"(dummy_ptr)); return ret; } -- 2.39.2