1
/* ---------------------------------------------------------------------
2
* Definition of class Memcheck memcheck_object.h
3
* Memcheck-specific options / flags / fns
4
* ---------------------------------------------------------------------
5
* This file is part of Valkyrie, a front-end for Valgrind
6
* Copyright (C) 2000-2008, OpenWorks LLP <info@open-works.co.uk>
7
* This program is released under the terms of the GNU GPL v.2
8
* See the file COPYING for the full license details.
11
#ifndef __MEMCHECK_OBJECT_H
12
#define __MEMCHECK_OBJECT_H
15
#include "tool_object.h"
16
#include "memcheck_view.h"
17
#include "memcheck_options_page.h"
18
#include "vk_logpoller.h"
20
#include "vglogreader.h"
21
#include "vk_process.h"
24
/* class Memcheck ------------------------------------------------------ */
25
class Memcheck : public ToolObject
30
Memcheck( int objId );
33
/* returns the ToolView window (memcheckView) for this tool */
34
ToolView* createView( QWidget* parent );
35
/* called by MainWin::closeToolView() */
38
bool start( VkRunState::State rm, QStringList vgflags );
41
/* check argval for this option, updating if necessary.
42
called by parseCmdArgs() and gui option pages */
43
int checkOptArg( int optid, QString& argval );
57
unsigned int maxOptId() { return NUM_OPTS; }
59
OptionsPage* createOptionsPage( OptionsWindow* parent ) {
60
return (OptionsPage*)new MemcheckOptionsPage( parent, this );
63
/* returns a list of non-default flags to pass to valgrind */
64
QStringList modifiedVgFlags();
67
bool fileSaveDialog( QString fname=QString() );
70
/* overriding to avoid casting everywhere */
71
MemcheckView* view() { return (MemcheckView*)m_view; }
73
void statusMsg( QString hdr, QString msg );
75
bool saveParsedOutput( QString& fname );
77
bool runValgrind( QStringList vgflags ); // RM_Valgrind
78
bool parseLogFile(); // RM_Tool0
79
bool mergeLogFiles(); // RM_Tool1
80
bool startProcess( QStringList flags );
88
VgLogReader* m_vgreader;
90
VkLogPoller* m_logpoller;