blob: a44133e1ca096e61e0bf49d528f47f6e941b3855 [file] [log] [blame]
njn25e49d8e72002-09-23 09:36:25 +00001
2/*--------------------------------------------------------------------*/
nethercote137bc552003-11-14 17:47:54 +00003/*--- Dummy profiling machinery -- overridden by tools when they ---*/
njn25e49d8e72002-09-23 09:36:25 +00004/*--- want profiling. ---*/
5/*--- vg_dummy_profile.c ---*/
6/*--------------------------------------------------------------------*/
7
8/*
njnc9539842002-10-02 13:26:35 +00009 This file is part of Valgrind, an extensible x86 protected-mode
10 emulator for monitoring program execution on x86-Unixes.
njn25e49d8e72002-09-23 09:36:25 +000011
nethercotebb1c9912004-01-04 16:43:23 +000012 Copyright (C) 2000-2004 Julian Seward
njn25e49d8e72002-09-23 09:36:25 +000013 jseward@acm.org
14
15 This program is free software; you can redistribute it and/or
16 modify it under the terms of the GNU General Public License as
17 published by the Free Software Foundation; either version 2 of the
18 License, or (at your option) any later version.
19
20 This program is distributed in the hope that it will be useful, but
21 WITHOUT ANY WARRANTY; without even the implied warranty of
22 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
23 General Public License for more details.
24
25 You should have received a copy of the GNU General Public License
26 along with this program; if not, write to the Free Software
27 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
28 02111-1307, USA.
29
30 The GNU General Public License is contained in the file COPYING.
31*/
32
nethercotef1e5e152004-09-01 23:58:16 +000033#include "core.h"
njn25e49d8e72002-09-23 09:36:25 +000034
njn0c15c332003-03-07 11:13:42 +000035static void vgp_die(void)
njn25e49d8e72002-09-23 09:36:25 +000036{
37 VG_(printf)(
38 "\nProfiling error:\n"
nethercote137bc552003-11-14 17:47:54 +000039 " The --profile=yes option was specified, but the tool\n"
njn25e49d8e72002-09-23 09:36:25 +000040 " wasn't built for profiling. #include \"vg_profile.c\"\n"
nethercote137bc552003-11-14 17:47:54 +000041 " into the tool and rebuild to allow profiling.\n\n");
njn25e49d8e72002-09-23 09:36:25 +000042 VG_(exit)(1);
43}
44
njn0c15c332003-03-07 11:13:42 +000045void VGP_(register_profile_event) ( Int n, Char* name )
46{
47}
48
49void VGP_(init_profiling) ( void )
50{
51 vgp_die();
52}
53
njn25e49d8e72002-09-23 09:36:25 +000054void VGP_(done_profiling) ( void )
55{
njn9d28c952003-03-07 13:54:50 +000056 VG_(core_panic)("done_profiling(), but not compiled for profiling??");
njn25e49d8e72002-09-23 09:36:25 +000057}
58
59void VGP_(pushcc) ( UInt cc )
60{
njn0c15c332003-03-07 11:13:42 +000061 vgp_die();
njn25e49d8e72002-09-23 09:36:25 +000062}
63
64void VGP_(popcc) ( UInt cc )
65{
njn0c15c332003-03-07 11:13:42 +000066 vgp_die();
njn25e49d8e72002-09-23 09:36:25 +000067}
68
69/*--------------------------------------------------------------------*/
70/*--- end vg_dummy_profile.c ---*/
71/*--------------------------------------------------------------------*/