Module Name: src Committed By: martin Date: Wed May 31 11:09:22 UTC 2017
Modified Files: src/sys/arch/sparc/include: profile.h Log Message: Fix __PIC__ profiled binaries To generate a diff of this commit: cvs rdiff -u -r1.16 -r1.17 src/sys/arch/sparc/include/profile.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/arch/sparc/include/profile.h diff -u src/sys/arch/sparc/include/profile.h:1.16 src/sys/arch/sparc/include/profile.h:1.17 --- src/sys/arch/sparc/include/profile.h:1.16 Thu Sep 12 15:36:17 2013 +++ src/sys/arch/sparc/include/profile.h Wed May 31 11:09:22 2017 @@ -1,4 +1,4 @@ -/* $NetBSD: profile.h,v 1.16 2013/09/12 15:36:17 joerg Exp $ */ +/* $NetBSD: profile.h,v 1.17 2017/05/31 11:09:22 martin Exp $ */ /* * Copyright (c) 1992, 1993 @@ -57,7 +57,6 @@ __asm("add %o7, 8, %o1");\ __asm("1: rd %pc, %o2");\ __asm("add %o2," _MCOUNT_SYM "-1b, %o2");\ - __asm("ld [%o2], %o2");\ __asm("jmpl %o2, %g0");\ __asm("add %i7, 8, %o0"); #else @@ -65,9 +64,10 @@ __asm(".global " _MCOUNT_ENTRY);\ __asm(_MCOUNT_ENTRY ":");\ __asm("add %o7, 8, %o1");\ + __asm("mov %o7, %o3");\ __asm("1: call 2f; nop; 2:");\ __asm("add %o7," _MCOUNT_SYM "-1b, %o2");\ - __asm("ld [%o2], %o2");\ + __asm("mov %o3, %o7");\ __asm("jmpl %o2, %g0");\ __asm("add %i7, 8, %o0"); #endif