diff --git a/rtl/openbsd/x86_64/cprt0.as b/rtl/openbsd/x86_64/cprt0.as index fcc442b3b2..cb6c015495 100644 --- a/rtl/openbsd/x86_64/cprt0.as +++ b/rtl/openbsd/x86_64/cprt0.as @@ -101,12 +101,10 @@ ___start: movq -16(%rbp), %rax movb $0, (%rax) .L2: - movl $_mcleanup, %edi + leaq _mcleanup(%rip), %rdi call atexit - movl $_etext, %eax - movq %rax, %rsi - movl $_eprol, %eax - movq %rax, %rdi + leaq _etext(%rip), %rsi + leaq _eprol(%rip), %rdi call monstartup movl $0, %eax call _init