diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2010-05-09 15:56:09 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2010-05-09 15:56:09 +0000 |
commit | f816020cc2cbc721af48d71cbb4ab033aadd5ded (patch) | |
tree | 42a1916cde5114a5ea6066e35c8a5d04acbb3f70 /lib | |
parent | cb0c98a6aaa8166c26a7714e6ee57f93ef8892fe (diff) |
Mark _MCOUNT_DECL as __used to prevent gcc4 from optimizing it away when it
is only referenced from inline asm.
ok jsg@
Diffstat (limited to 'lib')
-rw-r--r-- | lib/libc/gmon/mcount.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libc/gmon/mcount.c b/lib/libc/gmon/mcount.c index b977759b00e..d5faba86654 100644 --- a/lib/libc/gmon/mcount.c +++ b/lib/libc/gmon/mcount.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mcount.c,v 1.10 2005/08/08 08:05:34 espie Exp $ */ +/* $OpenBSD: mcount.c,v 1.11 2010/05/09 15:56:08 kettenis Exp $ */ /*- * Copyright (c) 1983, 1992, 1993 * The Regents of the University of California. All rights reserved. @@ -46,7 +46,7 @@ * both frompcindex and frompc. Any reasonable, modern compiler will * perform this optimization. */ -_MCOUNT_DECL(u_long frompc, u_long selfpc); +_MCOUNT_DECL(u_long frompc, u_long selfpc) __used; /* _mcount; may be static, inline, etc */ _MCOUNT_DECL(u_long frompc, u_long selfpc) { |