From 48ae5fc270ea3bbb965b4bd07cb1691a5c115642 Mon Sep 17 00:00:00 2001 From: The Android Open Source Project Date: Tue, 21 Oct 2008 07:00:00 -0700 Subject: Initial Contribution --- gui/Makefile.am | 43 -- gui/Makefile.in | 618 ------------------------- gui/oprof_start.cpp | 994 ---------------------------------------- gui/oprof_start.h | 162 ------- gui/oprof_start_config.cpp | 103 ----- gui/oprof_start_config.h | 53 --- gui/oprof_start_main.cpp | 27 -- gui/oprof_start_util.cpp | 341 -------------- gui/oprof_start_util.h | 39 -- gui/ui/Makefile.am | 24 - gui/ui/Makefile.in | 453 ------------------- gui/ui/oprof_start.base.ui | 1078 -------------------------------------------- 12 files changed, 3935 deletions(-) delete mode 100644 gui/Makefile.am delete mode 100644 gui/Makefile.in delete mode 100644 gui/oprof_start.cpp delete mode 100644 gui/oprof_start.h delete mode 100644 gui/oprof_start_config.cpp delete mode 100644 gui/oprof_start_config.h delete mode 100644 gui/oprof_start_main.cpp delete mode 100644 gui/oprof_start_util.cpp delete mode 100644 gui/oprof_start_util.h delete mode 100644 gui/ui/Makefile.am delete mode 100644 gui/ui/Makefile.in delete mode 100644 gui/ui/oprof_start.base.ui (limited to 'gui') diff --git a/gui/Makefile.am b/gui/Makefile.am deleted file mode 100644 index ba5e27c..0000000 --- a/gui/Makefile.am +++ /dev/null @@ -1,43 +0,0 @@ -SUBDIRS = ui - -dist_sources = \ - oprof_start.cpp \ - oprof_start_config.cpp \ - oprof_start_util.cpp \ - oprof_start_main.cpp \ - oprof_start.h \ - oprof_start_config.h \ - oprof_start_util.h - -EXTRA_DIST = $(dist_sources) - -if have_qt - -AM_CPPFLAGS = \ - @QT_INCLUDES@ \ - -I ${top_srcdir}/libop \ - -I ${top_srcdir}/libutil++ \ - -I ${top_srcdir}/libutil - -AM_CXXFLAGS = @OP_CXXFLAGS@ - -bin_PROGRAMS = oprof_start - -oprof_start_SOURCES = $(dist_sources) -nodist_oprof_start_SOURCES = oprof_start.moc.cpp -oprof_start_LDADD = \ - ../libutil++/libutil++.a \ - ../libop/libop.a \ - ../libutil/libutil.a \ - ui/liboprof_start.a \ - @QT_LDFLAGS@ \ - @QT_LIB@ \ - @X_LIBS@ - -oprof_start.moc.cpp: ${top_srcdir}/gui/oprof_start.h - $(MOC) -o $@ ${top_srcdir}/gui/oprof_start.h - -clean-local: - rm -f oprof_start.moc.cpp - -endif diff --git a/gui/Makefile.in b/gui/Makefile.in deleted file mode 100644 index b023d6c..0000000 --- a/gui/Makefile.in +++ /dev/null @@ -1,618 +0,0 @@ -# Makefile.in generated by automake 1.9.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005 Free Software Foundation, Inc. -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -SOURCES = $(oprof_start_SOURCES) $(nodist_oprof_start_SOURCES) - -srcdir = @srcdir@ -top_srcdir = @top_srcdir@ -VPATH = @srcdir@ -pkgdatadir = $(datadir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -top_builddir = .. -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -INSTALL = @INSTALL@ -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -@have_qt_TRUE@bin_PROGRAMS = oprof_start$(EXEEXT) -subdir = gui -DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/binutils.m4 \ - $(top_srcdir)/m4/builtinexpect.m4 \ - $(top_srcdir)/m4/compileroption.m4 \ - $(top_srcdir)/m4/configmodule.m4 \ - $(top_srcdir)/m4/copyifchange.m4 $(top_srcdir)/m4/docbook.m4 \ - $(top_srcdir)/m4/extradirs.m4 $(top_srcdir)/m4/findkernel.m4 \ - $(top_srcdir)/m4/kerneloption.m4 \ - $(top_srcdir)/m4/kernelversion.m4 \ - $(top_srcdir)/m4/mallocattribute.m4 \ - $(top_srcdir)/m4/poptconst.m4 \ - $(top_srcdir)/m4/precompiledheader.m4 $(top_srcdir)/m4/qt.m4 \ - $(top_srcdir)/m4/resultyn.m4 $(top_srcdir)/m4/sstream.m4 \ - $(top_srcdir)/m4/typedef.m4 $(top_srcdir)/configure.in -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -am__installdirs = "$(DESTDIR)$(bindir)" -binPROGRAMS_INSTALL = $(INSTALL_PROGRAM) -PROGRAMS = $(bin_PROGRAMS) -am__oprof_start_SOURCES_DIST = oprof_start.cpp oprof_start_config.cpp \ - oprof_start_util.cpp oprof_start_main.cpp oprof_start.h \ - oprof_start_config.h oprof_start_util.h -am__objects_1 = oprof_start.$(OBJEXT) oprof_start_config.$(OBJEXT) \ - oprof_start_util.$(OBJEXT) oprof_start_main.$(OBJEXT) -@have_qt_TRUE@am_oprof_start_OBJECTS = $(am__objects_1) -@have_qt_TRUE@nodist_oprof_start_OBJECTS = oprof_start.moc.$(OBJEXT) -oprof_start_OBJECTS = $(am_oprof_start_OBJECTS) \ - $(nodist_oprof_start_OBJECTS) -@have_qt_TRUE@oprof_start_DEPENDENCIES = ../libutil++/libutil++.a \ -@have_qt_TRUE@ ../libop/libop.a ../libutil/libutil.a \ -@have_qt_TRUE@ ui/liboprof_start.a -DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp -am__depfiles_maybe = depfiles -CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -CXXLD = $(CXX) -CXXLINK = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) \ - -o $@ -COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ - $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -CCLD = $(CC) -LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ -SOURCES = $(oprof_start_SOURCES) $(nodist_oprof_start_SOURCES) -DIST_SOURCES = $(am__oprof_start_SOURCES_DIST) -RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ - html-recursive info-recursive install-data-recursive \ - install-exec-recursive install-info-recursive \ - install-recursive installcheck-recursive installdirs-recursive \ - pdf-recursive ps-recursive uninstall-info-recursive \ - uninstall-recursive -ETAGS = etags -CTAGS = ctags -DIST_SUBDIRS = $(SUBDIRS) -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMDEP_FALSE = @AMDEP_FALSE@ -AMDEP_TRUE = @AMDEP_TRUE@ -AMTAR = @AMTAR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -BFD_LIBS = @BFD_LIBS@ -CAT_ENTRY_END = @CAT_ENTRY_END@ -CAT_ENTRY_START = @CAT_ENTRY_START@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DATE = @DATE@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DOCBOOK_ROOT = @DOCBOOK_ROOT@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -EXEEXT = @EXEEXT@ -EXTRA_CFLAGS_MODULE = @EXTRA_CFLAGS_MODULE@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -KINC = @KINC@ -KSRC = @KSRC@ -KVERS = @KVERS@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LIBERTY_LIBS = @LIBERTY_LIBS@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LTLIBOBJS = @LTLIBOBJS@ -MAKEINFO = @MAKEINFO@ -MOC = @MOC@ -MODINSTALLDIR = @MODINSTALLDIR@ -OBJEXT = @OBJEXT@ -OPROFILE_DIR = @OPROFILE_DIR@ -OPROFILE_MODULE_ARCH = @OPROFILE_MODULE_ARCH@ -OP_CFLAGS = @OP_CFLAGS@ -OP_CXXFLAGS = @OP_CXXFLAGS@ -OP_DOCDIR = @OP_DOCDIR@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -POPT_LIBS = @POPT_LIBS@ -PTRDIFF_T_TYPE = @PTRDIFF_T_TYPE@ -QT_INCLUDES = @QT_INCLUDES@ -QT_LDFLAGS = @QT_LDFLAGS@ -QT_LIB = @QT_LIB@ -QT_VERSION = @QT_VERSION@ -RANLIB = @RANLIB@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -SIZE_T_TYPE = @SIZE_T_TYPE@ -STRIP = @STRIP@ -UIC = @UIC@ -VERSION = @VERSION@ -XML_CATALOG = @XML_CATALOG@ -XSLTPROC = @XSLTPROC@ -XSLTPROC_FLAGS = @XSLTPROC_FLAGS@ -X_CFLAGS = @X_CFLAGS@ -X_EXTRA_LIBS = @X_EXTRA_LIBS@ -X_LIBS = @X_LIBS@ -X_PRE_LIBS = @X_PRE_LIBS@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_RANLIB = @ac_ct_RANLIB@ -ac_ct_STRIP = @ac_ct_STRIP@ -am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ -am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ -am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@ -am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build_alias = @build_alias@ -datadir = @datadir@ -enable_abi_FALSE = @enable_abi_FALSE@ -enable_abi_TRUE = @enable_abi_TRUE@ -exec_prefix = @exec_prefix@ -have_qt_FALSE = @have_qt_FALSE@ -have_qt_TRUE = @have_qt_TRUE@ -have_xsltproc_FALSE = @have_xsltproc_FALSE@ -have_xsltproc_TRUE = @have_xsltproc_TRUE@ -host_alias = @host_alias@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -kernel_support_FALSE = @kernel_support_FALSE@ -kernel_support_TRUE = @kernel_support_TRUE@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -topdir = @topdir@ -SUBDIRS = ui -dist_sources = \ - oprof_start.cpp \ - oprof_start_config.cpp \ - oprof_start_util.cpp \ - oprof_start_main.cpp \ - oprof_start.h \ - oprof_start_config.h \ - oprof_start_util.h - -EXTRA_DIST = $(dist_sources) -@have_qt_TRUE@AM_CPPFLAGS = \ -@have_qt_TRUE@ @QT_INCLUDES@ \ -@have_qt_TRUE@ -I ${top_srcdir}/libop \ -@have_qt_TRUE@ -I ${top_srcdir}/libutil++ \ -@have_qt_TRUE@ -I ${top_srcdir}/libutil - -@have_qt_TRUE@AM_CXXFLAGS = @OP_CXXFLAGS@ -@have_qt_TRUE@oprof_start_SOURCES = $(dist_sources) -@have_qt_TRUE@nodist_oprof_start_SOURCES = oprof_start.moc.cpp -@have_qt_TRUE@oprof_start_LDADD = \ -@have_qt_TRUE@ ../libutil++/libutil++.a \ -@have_qt_TRUE@ ../libop/libop.a \ -@have_qt_TRUE@ ../libutil/libutil.a \ -@have_qt_TRUE@ ui/liboprof_start.a \ -@have_qt_TRUE@ @QT_LDFLAGS@ \ -@have_qt_TRUE@ @QT_LIB@ \ -@have_qt_TRUE@ @X_LIBS@ - -all: all-recursive - -.SUFFIXES: -.SUFFIXES: .cpp .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \ - && exit 0; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign gui/Makefile'; \ - cd $(top_srcdir) && \ - $(AUTOMAKE) --foreign gui/Makefile -.PRECIOUS: Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -install-binPROGRAMS: $(bin_PROGRAMS) - @$(NORMAL_INSTALL) - test -z "$(bindir)" || $(mkdir_p) "$(DESTDIR)$(bindir)" - @list='$(bin_PROGRAMS)'; for p in $$list; do \ - p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \ - if test -f $$p \ - ; then \ - f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \ - echo " $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \ - $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \ - else :; fi; \ - done - -uninstall-binPROGRAMS: - @$(NORMAL_UNINSTALL) - @list='$(bin_PROGRAMS)'; for p in $$list; do \ - f=`echo "$$p" | sed 's,^.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \ - echo " rm -f '$(DESTDIR)$(bindir)/$$f'"; \ - rm -f "$(DESTDIR)$(bindir)/$$f"; \ - done - -clean-binPROGRAMS: - -test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS) -oprof_start$(EXEEXT): $(oprof_start_OBJECTS) $(oprof_start_DEPENDENCIES) - @rm -f oprof_start$(EXEEXT) - $(CXXLINK) $(oprof_start_LDFLAGS) $(oprof_start_OBJECTS) $(oprof_start_LDADD) $(LIBS) - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/oprof_start.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/oprof_start.moc.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/oprof_start_config.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/oprof_start_main.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/oprof_start_util.Po@am__quote@ - -.cpp.o: -@am__fastdepCXX_TRUE@ if $(CXXCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ $<; \ -@am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCXX_FALSE@ $(CXXCOMPILE) -c -o $@ $< - -.cpp.obj: -@am__fastdepCXX_TRUE@ if $(CXXCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ `$(CYGPATH_W) '$<'`; \ -@am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCXX_FALSE@ $(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` -uninstall-info-am: - -# This directory's subdirectories are mostly independent; you can cd -# into them and run `make' without going through this Makefile. -# To change the values of `make' variables: instead of editing Makefiles, -# (1) if the variable is set in `config.status', edit `config.status' -# (which will cause the Makefiles to be regenerated when you run `make'); -# (2) otherwise, pass the desired values on the `make' command line. -$(RECURSIVE_TARGETS): - @failcom='exit 1'; \ - for f in x $$MAKEFLAGS; do \ - case $$f in \ - *=* | --[!k]*);; \ - *k*) failcom='fail=yes';; \ - esac; \ - done; \ - dot_seen=no; \ - target=`echo $@ | sed s/-recursive//`; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - dot_seen=yes; \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done; \ - if test "$$dot_seen" = "no"; then \ - $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ - fi; test -z "$$fail" - -mostlyclean-recursive clean-recursive distclean-recursive \ -maintainer-clean-recursive: - @failcom='exit 1'; \ - for f in x $$MAKEFLAGS; do \ - case $$f in \ - *=* | --[!k]*);; \ - *k*) failcom='fail=yes';; \ - esac; \ - done; \ - dot_seen=no; \ - case "$@" in \ - distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ - *) list='$(SUBDIRS)' ;; \ - esac; \ - rev=''; for subdir in $$list; do \ - if test "$$subdir" = "."; then :; else \ - rev="$$subdir $$rev"; \ - fi; \ - done; \ - rev="$$rev ."; \ - target=`echo $@ | sed s/-recursive//`; \ - for subdir in $$rev; do \ - echo "Making $$target in $$subdir"; \ - if test "$$subdir" = "."; then \ - local_target="$$target-am"; \ - else \ - local_target="$$target"; \ - fi; \ - (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ - || eval $$failcom; \ - done && test -z "$$fail" -tags-recursive: - list='$(SUBDIRS)'; for subdir in $$list; do \ - test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \ - done -ctags-recursive: - list='$(SUBDIRS)'; for subdir in $$list; do \ - test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \ - done - -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - tags=; \ - here=`pwd`; \ - if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ - include_option=--etags-include; \ - empty_fix=.; \ - else \ - include_option=--include; \ - empty_fix=; \ - fi; \ - list='$(SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - test ! -f $$subdir/TAGS || \ - tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \ - fi; \ - done; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ - if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$tags $$unique; \ - fi -ctags: CTAGS -CTAGS: ctags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - tags=; \ - here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ - test -z "$(CTAGS_ARGS)$$tags$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$tags $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && cd $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) $$here - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -distdir: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ - list='$(DISTFILES)'; for file in $$list; do \ - case $$file in \ - $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ - $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ - esac; \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test "$$dir" != "$$file" && test "$$dir" != "."; then \ - dir="/$$dir"; \ - $(mkdir_p) "$(distdir)$$dir"; \ - else \ - dir=''; \ - fi; \ - if test -d $$d/$$file; then \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ - fi; \ - cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ - else \ - test -f $(distdir)/$$file \ - || cp -p $$d/$$file $(distdir)/$$file \ - || exit 1; \ - fi; \ - done - list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ - if test "$$subdir" = .; then :; else \ - test -d "$(distdir)/$$subdir" \ - || $(mkdir_p) "$(distdir)/$$subdir" \ - || exit 1; \ - distdir=`$(am__cd) $(distdir) && pwd`; \ - top_distdir=`$(am__cd) $(top_distdir) && pwd`; \ - (cd $$subdir && \ - $(MAKE) $(AM_MAKEFLAGS) \ - top_distdir="$$top_distdir" \ - distdir="$$distdir/$$subdir" \ - distdir) \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-recursive -all-am: Makefile $(PROGRAMS) -installdirs: installdirs-recursive -installdirs-am: - for dir in "$(DESTDIR)$(bindir)"; do \ - test -z "$$dir" || $(mkdir_p) "$$dir"; \ - done -install: install-recursive -install-exec: install-exec-recursive -install-data: install-data-recursive -uninstall: uninstall-recursive - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-recursive -install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -@have_qt_FALSE@clean-local: -clean: clean-recursive - -clean-am: clean-binPROGRAMS clean-generic clean-local mostlyclean-am - -distclean: distclean-recursive - -rm -rf ./$(DEPDIR) - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-recursive - -dvi-am: - -html: html-recursive - -info: info-recursive - -info-am: - -install-data-am: - -install-exec-am: install-binPROGRAMS - -install-info: install-info-recursive - -install-man: - -installcheck-am: - -maintainer-clean: maintainer-clean-recursive - -rm -rf ./$(DEPDIR) - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-recursive - -mostlyclean-am: mostlyclean-compile mostlyclean-generic - -pdf: pdf-recursive - -pdf-am: - -ps: ps-recursive - -ps-am: - -uninstall-am: uninstall-binPROGRAMS uninstall-info-am - -uninstall-info: uninstall-info-recursive - -.PHONY: $(RECURSIVE_TARGETS) CTAGS GTAGS all all-am check check-am \ - clean clean-binPROGRAMS clean-generic clean-local \ - clean-recursive ctags ctags-recursive distclean \ - distclean-compile distclean-generic distclean-recursive \ - distclean-tags distdir dvi dvi-am html html-am info info-am \ - install install-am install-binPROGRAMS install-data \ - install-data-am install-exec install-exec-am install-info \ - install-info-am install-man install-strip installcheck \ - installcheck-am installdirs installdirs-am maintainer-clean \ - maintainer-clean-generic maintainer-clean-recursive \ - mostlyclean mostlyclean-compile mostlyclean-generic \ - mostlyclean-recursive pdf pdf-am ps ps-am tags tags-recursive \ - uninstall uninstall-am uninstall-binPROGRAMS uninstall-info-am - - -@have_qt_TRUE@oprof_start.moc.cpp: ${top_srcdir}/gui/oprof_start.h -@have_qt_TRUE@ $(MOC) -o $@ ${top_srcdir}/gui/oprof_start.h - -@have_qt_TRUE@clean-local: -@have_qt_TRUE@ rm -f oprof_start.moc.cpp -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/gui/oprof_start.cpp b/gui/oprof_start.cpp deleted file mode 100644 index 7126314..0000000 --- a/gui/oprof_start.cpp +++ /dev/null @@ -1,994 +0,0 @@ -/** - * @file oprof_start.cpp - * The GUI start main class - * - * @remark Copyright 2002 OProfile authors - * @remark Read the file COPYING - * - * @author Philippe Elie - * @author John Levon - */ - -#include -#include - -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include "config.h" -#include "oprof_start.h" -#include "op_config.h" -#include "op_config_24.h" -#include "string_manip.h" -#include "op_cpufreq.h" -#include "op_alloc_counter.h" -#include "oprof_start_util.h" - -#include "op_hw_config.h" - -using namespace std; - -static char const * green_xpm[] = { -"16 16 2 1", -" c None", -". c #00FF00", -" ....... ", -" ........... ", -" ............. ", -" ............. ", -"............... ", -"............... ", -"............... ", -"............... ", -"............... ", -"............... ", -"............... ", -" ............. ", -" ............. ", -" ........... ", -" ....... ", -" " }; - -static char const * red_xpm[] = { -"16 16 2 1", -" c None", -". c #FF0000", -" ....... ", -" ........... ", -" ............. ", -" ............. ", -"............... ", -"............... ", -"............... ", -"............... ", -"............... ", -"............... ", -"............... ", -" ............. ", -" ............. ", -" ........... ", -" ....... ", -" " }; - -static QPixmap * green_pixmap; -static QPixmap * red_pixmap; - - -op_event_descr::op_event_descr() - : - counter_mask(0), - val(0), - unit(0), - min_count(0) -{ -} - - -oprof_start::oprof_start() - : - oprof_start_base(0, 0, false, 0), - event_count_validator(new QIntValidator(event_count_edit)), - current_event(0), - cpu_speed(op_cpu_frequency()), - total_nr_interrupts(0) -{ - green_pixmap = new QPixmap(green_xpm); - red_pixmap = new QPixmap(red_xpm); - vector args; - args.push_back("--init"); - - if (do_exec_command(OP_BINDIR "/opcontrol", args)) - exit(EXIT_FAILURE); - - cpu_type = op_get_cpu_type(); - op_nr_counters = op_get_nr_counters(cpu_type); - - if (cpu_type == CPU_TIMER_INT) { - setup_config_tab->removePage(counter_setup_page); - } else { - fill_events(); - } - - op_interface interface = op_get_interface(); - if (interface == OP_INTERFACE_NO_GOOD) { - QMessageBox::warning(this, 0, "Couldn't determine kernel" - " interface version"); - exit(EXIT_FAILURE); - } - bool is_26 = interface == OP_INTERFACE_26; - - if (is_26) { - note_table_size_edit->hide(); - note_table_size_label->hide(); - // FIXME: can adapt to 2.6 ... - buffer_size_edit->hide(); - buffer_size_label->hide(); - } - - // setup the configuration page. - kernel_filename_edit->setText(config.kernel_filename.c_str()); - - no_vmlinux->setChecked(config.no_kernel); - - buffer_size_edit->setText(QString().setNum(config.buffer_size)); - note_table_size_edit->setText(QString().setNum(config.note_table_size)); - verbose->setChecked(config.verbose); - separate_lib_cb->setChecked(config.separate_lib); - separate_kernel_cb->setChecked(config.separate_kernel); - separate_cpu_cb->setChecked(config.separate_cpu); - separate_thread_cb->setChecked(config.separate_thread); - - // the unit mask check boxes - hide_masks(); - - event_count_edit->setValidator(event_count_validator); - QIntValidator * iv; - iv = new QIntValidator(OP_MIN_BUF_SIZE, OP_MAX_BUF_SIZE, buffer_size_edit); - buffer_size_edit->setValidator(iv); - iv = new QIntValidator(OP_MIN_NOTE_TABLE_SIZE, OP_MAX_NOTE_TABLE_SIZE, note_table_size_edit); - note_table_size_edit->setValidator(iv); - - // daemon status timer - startTimer(5000); - timerEvent(0); - - resize(minimumSizeHint()); - - // force the pixmap re-draw - event_selected(); -} - - -void oprof_start::fill_events() -{ - // we need to build the event descr stuff before loading the - // configuration because we use locate_event to get an event descr - // from its name. - struct list_head * pos; - struct list_head * events = op_events(cpu_type); - - list_for_each(pos, events) { - struct op_event * event = list_entry(pos, struct op_event, event_next); - - op_event_descr descr; - - descr.counter_mask = event->counter_mask; - descr.val = event->val; - if (event->unit->num) { - descr.unit = event->unit; - } else { - descr.unit = 0; - } - - descr.name = event->name; - descr.help_str = event->desc; - descr.min_count = event->min_count; - - for (uint ctr = 0; ctr < op_nr_counters; ++ctr) { - uint count; - - if (!(descr.counter_mask & (1 << ctr))) - continue; - - if (cpu_type == CPU_RTC) { - count = 1024; - } else { - /* setting to cpu Hz / 2000 gives a safe value for - * all events, and a good one for most. - */ - if (cpu_speed) - count = int(cpu_speed * 500); - else - count = descr.min_count * 100; - } - - event_cfgs[descr.name].count = count; - event_cfgs[descr.name].umask = 0; - if (descr.unit) - event_cfgs[descr.name].umask = descr.unit->default_mask; - event_cfgs[descr.name].os_ring_count = 1; - event_cfgs[descr.name].user_ring_count = 1; - } - - v_events.push_back(descr); - } - - events_list->header()->hide(); - events_list->setSorting(-1); - - fill_events_listbox(); - - read_set_events(); - - // FIXME: why this ? - if (cpu_type == CPU_RTC) - events_list->setCurrentItem(events_list->firstChild()); - - load_config_file(); -} - - -namespace { - -/// find the first item with the given text in column 0 or return NULL -QListViewItem * findItem(QListView * view, char const * name) -{ - // Qt 2.3.1 does not have QListView::findItem() - QListViewItem * item = view->firstChild(); - - while (item && strcmp(item->text(0).latin1(), name)) { - item = item->nextSibling(); - } - - return item; -} - -}; - - -void oprof_start::setup_default_event() -{ - struct op_default_event_descr descr; - op_default_event(cpu_type, &descr); - - event_cfgs[descr.name].umask = descr.um; - event_cfgs[descr.name].count = descr.count; - event_cfgs[descr.name].user_ring_count = 1; - event_cfgs[descr.name].os_ring_count = 1; - - QListViewItem * item = findItem(events_list, descr.name); - if (item) - item->setSelected(true); -} - - -void oprof_start::read_set_events() -{ - string name = get_user_filename(".oprofile/daemonrc"); - - ifstream in(name.c_str()); - - if (!in) { - setup_default_event(); - return; - } - - string str; - - bool one_enabled = false; - - while (getline(in, str)) { - string const val = split(str, '='); - string const name = str; - - if (!is_prefix(name, "CHOSEN_EVENTS[")) - continue; - - one_enabled = true; - - // CHOSEN_EVENTS[0]=CPU_CLK_UNHALTED:10000:0:1:1 - vector parts = separate_token(val, ':'); - - if (parts.size() != 5 && parts.size() != 2) { - cerr << "invalid configuration file\n"; - // FIXME - exit(EXIT_FAILURE); - } - - string ev_name = parts[0]; - event_cfgs[ev_name].count = - op_lexical_cast(parts[1]); - - // CPU_CLK_UNHALTED:10000 is also valid - if (parts.size() == 5) { - event_cfgs[ev_name].umask = - op_lexical_cast(parts[2]); - event_cfgs[ev_name].user_ring_count = - op_lexical_cast(parts[3]); - event_cfgs[ev_name].os_ring_count = - op_lexical_cast(parts[4]); - } else { - event_cfgs[ev_name].umask = 0; - event_cfgs[ev_name].user_ring_count = 1; - event_cfgs[ev_name].os_ring_count = 1; - } - - QListViewItem * item = findItem(events_list, ev_name.c_str()); - if (item) - item->setSelected(true); - } - - // use default event if none set - if (!one_enabled) - setup_default_event(); -} - - -void oprof_start::load_config_file() -{ - string name = get_user_filename(".oprofile/daemonrc"); - - ifstream in(name.c_str()); - if (!in) { - if (!check_and_create_config_dir()) - return; - - ofstream out(name.c_str()); - if (!out) { - QMessageBox::warning(this, 0, "Unable to open configuration " - "file ~/.oprofile/daemonrc"); - } - return; - } - - in >> config; -} - - -// user request a "normal" exit so save the config file. -void oprof_start::accept() -{ - // record the previous settings - record_selected_event_config(); - - save_config(); - - QDialog::accept(); -} - - -void oprof_start::closeEvent(QCloseEvent *) -{ - accept(); -} - - -void oprof_start::timerEvent(QTimerEvent *) -{ - static time_t last = time(0); - - daemon_status dstat; - - flush_profiler_data_btn->setEnabled(dstat.running); - stop_profiler_btn->setEnabled(dstat.running); - start_profiler_btn->setEnabled(!dstat.running); - - if (!dstat.running) { - daemon_label->setText("Profiler is not running."); - return; - } - - ostringstream ss; - ss << "Profiler running:"; - - time_t curr = time(0); - total_nr_interrupts += dstat.nr_interrupts; - - if (curr - last) - ss << " (" << dstat.nr_interrupts / (curr - last) << " interrupts / second, total " << total_nr_interrupts << ")"; - - daemon_label->setText(ss.str().c_str()); - - last = curr; -} - - -void oprof_start::fill_events_listbox() -{ - setUpdatesEnabled(false); - - for (vector::reverse_iterator cit = v_events.rbegin(); - cit != v_events.rend(); ++cit) { - new QListViewItem(events_list, cit->name.c_str()); - } - - setUpdatesEnabled(true); - update(); -} - - -void oprof_start::display_event(op_event_descr const & descr) -{ - setUpdatesEnabled(false); - - setup_unit_masks(descr); - os_ring_count_cb->setEnabled(true); - user_ring_count_cb->setEnabled(true); - event_count_edit->setEnabled(true); - - event_setting & cfg = event_cfgs[descr.name]; - - os_ring_count_cb->setChecked(cfg.os_ring_count); - user_ring_count_cb->setChecked(cfg.user_ring_count); - QString count_text; - count_text.setNum(cfg.count); - event_count_edit->setText(count_text); - event_count_validator->setRange(descr.min_count, max_perf_count()); - - setUpdatesEnabled(true); - update(); -} - - -bool oprof_start::is_selectable_event(QListViewItem * item) -{ - if (item->isSelected()) - return true; - - selected_events.insert(item); - - bool ret = false; - if (alloc_selected_events()) - ret = true; - - selected_events.erase(item); - - return ret; -} - - -void oprof_start::draw_event_list() -{ - QListViewItem * cur; - for (cur = events_list->firstChild(); cur; cur = cur->nextSibling()) { - if (is_selectable_event(cur)) - cur->setPixmap(0, *green_pixmap); - else - cur->setPixmap(0, *red_pixmap); - } -} - - -bool oprof_start::alloc_selected_events() const -{ - vector events; - - set::const_iterator it; - for (it = selected_events.begin(); it != selected_events.end(); ++it) { - events.push_back(find_event_by_name((*it)->text(0).latin1())); - } - - size_t * map = - map_event_to_counter(&events[0], events.size(), cpu_type); - - if (!map) - return false; - - free(map); - return true; -} - -void oprof_start::event_selected() -{ - // The deal is simple: QT lack of a way to know what item was the last - // (de)selected item so we record a set of selected items and diff - // it in the appropriate way with the previous list of selected items. - - set current_selection; - QListViewItem * cur; - for (cur = events_list->firstChild(); cur; cur = cur->nextSibling()) { - if (cur->isSelected()) { - current_selection.insert(cur); - } - } - - // First remove the deselected item. - vector new_deselected; - set_difference(selected_events.begin(), selected_events.end(), - current_selection.begin(), current_selection.end(), - back_inserter(new_deselected)); - vector::const_iterator it; - for (it = new_deselected.begin(); it != new_deselected.end(); ++it) { - selected_events.erase(*it); - } - - // Now try to add the newly selected item if enough HW resource exists - vector new_selected; - set_difference(current_selection.begin(), current_selection.end(), - selected_events.begin(), selected_events.end(), - back_inserter(new_selected)); - for (it = new_selected.begin(); it != new_selected.end(); ++it) { - selected_events.insert(*it); - if (!alloc_selected_events()) { - (*it)->setSelected(false); - selected_events.erase(*it); - } else { - current_event = *it; - } - } - - draw_event_list(); - - if (current_event) - display_event(locate_event(current_event->text(0).latin1())); -} - - -void oprof_start::event_over(QListViewItem * item) -{ - op_event_descr const & descr = locate_event(item->text(0).latin1()); - - string help_str = descr.help_str.c_str(); - if (!is_selectable_event(item)) { - help_str += " conflicts with:"; - - set::const_iterator it; - for (it = selected_events.begin(); - it != selected_events.end(); ) { - QListViewItem * temp = *it; - selected_events.erase(it++); - if (is_selectable_event(item)) { - help_str += " "; - help_str += temp->text(0).latin1(); - } - selected_events.insert(temp); - } - } - - event_help_label->setText(help_str.c_str()); -} - - -/// select the kernel image filename -void oprof_start::choose_kernel_filename() -{ - string name = kernel_filename_edit->text().latin1(); - string result = do_open_file_or_dir(name, false); - - if (!result.empty()) - kernel_filename_edit->setText(result.c_str()); -} - - -// this record the current selected event setting in the event_cfg[] stuff. -// FIXME: need validation? -void oprof_start::record_selected_event_config() -{ - if (!current_event) - return; - - string name(current_event->text(0).latin1()); - - event_setting & cfg = event_cfgs[name]; - op_event_descr const & curr = locate_event(name); - - cfg.count = event_count_edit->text().toUInt(); - cfg.os_ring_count = os_ring_count_cb->isChecked(); - cfg.user_ring_count = user_ring_count_cb->isChecked(); - cfg.umask = get_unit_mask(curr); -} - - -// validate and save the configuration (The qt validator installed -// are not sufficient to do the validation) -bool oprof_start::record_config() -{ - config.kernel_filename = kernel_filename_edit->text().latin1(); - config.no_kernel = no_vmlinux->isChecked(); - - QString const t = buffer_size_edit->text(); - uint temp = t.toUInt(); - if (temp < OP_MIN_BUF_SIZE || temp > OP_MAX_BUF_SIZE) { - ostringstream error; - - error << "buffer size out of range: " << temp - << " valid range is [" << OP_MIN_BUF_SIZE << ", " - << OP_MAX_BUF_SIZE << "]"; - - QMessageBox::warning(this, 0, error.str().c_str()); - - return false; - } - config.buffer_size = temp; - - temp = note_table_size_edit->text().toUInt(); - if (temp < OP_MIN_NOTE_TABLE_SIZE || temp > OP_MAX_NOTE_TABLE_SIZE) { - ostringstream error; - - error << "note table size out of range: " << temp - << " valid range is [" << OP_MIN_NOTE_TABLE_SIZE << ", " - << OP_MAX_NOTE_TABLE_SIZE << "]"; - - QMessageBox::warning(this, 0, error.str().c_str()); - - return false; - } - config.note_table_size = temp; - - config.verbose = verbose->isChecked(); - config.separate_lib = separate_lib_cb->isChecked(); - config.separate_kernel = separate_kernel_cb->isChecked(); - config.separate_cpu = separate_cpu_cb->isChecked(); - config.separate_thread = separate_thread_cb->isChecked(); - - return true; -} - - -void oprof_start::get_unit_mask_part(op_event_descr const & descr, uint num, - bool selected, uint & mask) -{ - if (!selected) - return; - if (num >= descr.unit->num) - return; - - if (descr.unit->unit_type_mask == utm_bitmask) - mask |= descr.unit->um[num].value; - else - mask = descr.unit->um[num].value; -} - - -// return the unit mask selected through the unit mask check box -uint oprof_start::get_unit_mask(op_event_descr const & descr) -{ - uint mask = 0; - - if (!descr.unit) - return 0; - - // mandatory mask is transparent for user. - if (descr.unit->unit_type_mask == utm_mandatory) { - mask = descr.unit->default_mask; - return mask; - } - - get_unit_mask_part(descr, 0, check0->isChecked(), mask); - get_unit_mask_part(descr, 1, check1->isChecked(), mask); - get_unit_mask_part(descr, 2, check2->isChecked(), mask); - get_unit_mask_part(descr, 3, check3->isChecked(), mask); - get_unit_mask_part(descr, 4, check4->isChecked(), mask); - get_unit_mask_part(descr, 5, check5->isChecked(), mask); - get_unit_mask_part(descr, 6, check6->isChecked(), mask); - get_unit_mask_part(descr, 7, check7->isChecked(), mask); - get_unit_mask_part(descr, 8, check8->isChecked(), mask); - get_unit_mask_part(descr, 9, check9->isChecked(), mask); - get_unit_mask_part(descr, 10, check10->isChecked(), mask); - get_unit_mask_part(descr, 11, check11->isChecked(), mask); - get_unit_mask_part(descr, 12, check12->isChecked(), mask); - get_unit_mask_part(descr, 13, check13->isChecked(), mask); - get_unit_mask_part(descr, 14, check14->isChecked(), mask); - get_unit_mask_part(descr, 15, check15->isChecked(), mask); - return mask; -} - - -void oprof_start::hide_masks() -{ - check0->hide(); - check1->hide(); - check2->hide(); - check3->hide(); - check4->hide(); - check5->hide(); - check6->hide(); - check7->hide(); - check8->hide(); - check9->hide(); - check10->hide(); - check11->hide(); - check12->hide(); - check13->hide(); - check14->hide(); - check15->hide(); -} - - -void oprof_start::setup_unit_masks(op_event_descr const & descr) -{ - op_unit_mask const * um = descr.unit; - - hide_masks(); - - if (!um || um->unit_type_mask == utm_mandatory) - return; - - event_setting & cfg = event_cfgs[descr.name]; - - unit_mask_group->setExclusive(um->unit_type_mask == utm_exclusive); - - for (size_t i = 0; i < um->num ; ++i) { - QCheckBox * check = 0; - switch (i) { - case 0: check = check0; break; - case 1: check = check1; break; - case 2: check = check2; break; - case 3: check = check3; break; - case 4: check = check4; break; - case 5: check = check5; break; - case 6: check = check6; break; - case 7: check = check7; break; - case 8: check = check8; break; - case 9: check = check9; break; - case 10: check = check10; break; - case 11: check = check11; break; - case 12: check = check12; break; - case 13: check = check13; break; - case 14: check = check14; break; - case 15: check = check15; break; - } - check->setText(um->um[i].desc); - if (um->unit_type_mask == utm_exclusive) { - check->setChecked(cfg.umask == um->um[i].value); - } else { - // The last descriptor contains a mask that enable all - // value so we must enable the last check box only if - // all bits are on. - if (i == um->num - 1) { - check->setChecked(cfg.umask == um->um[i].value); - } else { - check->setChecked(cfg.umask & um->um[i].value); - } - } - check->show(); - } - unit_mask_group->setMinimumSize(unit_mask_group->sizeHint()); - setup_config_tab->setMinimumSize(setup_config_tab->sizeHint()); -} - - -uint oprof_start::max_perf_count() const -{ - return cpu_type == CPU_RTC ? OP_MAX_RTC_COUNT : OP_MAX_PERF_COUNT; -} - - -void oprof_start::on_flush_profiler_data() -{ - vector args; - args.push_back("--dump"); - - if (daemon_status().running) - do_exec_command(OP_BINDIR "/opcontrol", args); - else - QMessageBox::warning(this, 0, "The profiler is not started."); -} - - -// user is happy of its setting. -void oprof_start::on_start_profiler() -{ - // save the current settings - record_selected_event_config(); - - bool one_enable = false; - - QListViewItem * cur; - for (cur = events_list->firstChild(); cur; cur = cur->nextSibling()) { - if (!cur->isSelected()) - continue; - - // the missing reference is intended: gcc 2.91.66 can compile - // "op_event_descr const & descr = ..." w/o a warning - op_event_descr const descr = - locate_event(cur->text(0).latin1()); - - event_setting & cfg = event_cfgs[cur->text(0).latin1()]; - - one_enable = true; - - if (!cfg.os_ring_count && !cfg.user_ring_count) { - QMessageBox::warning(this, 0, "You must select to " - "profile at least one of user binaries/kernel"); - return; - } - - if (cfg.count < descr.min_count || - cfg.count > max_perf_count()) { - ostringstream out; - - out << "event " << descr.name << " count of range: " - << cfg.count << " must be in [ " - << descr.min_count << ", " - << max_perf_count() - << "]"; - - QMessageBox::warning(this, 0, out.str().c_str()); - return; - } - - if (descr.unit && - descr.unit->unit_type_mask == utm_bitmask && - cfg.umask == 0) { - ostringstream out; - - out << "event " << descr.name << " invalid unit mask: " - << cfg.umask << endl; - - QMessageBox::warning(this, 0, out.str().c_str()); - return; - } - } - - if (one_enable == false && cpu_type != CPU_TIMER_INT) { - QMessageBox::warning(this, 0, "No counters enabled.\n"); - return; - } - - if (daemon_status().running) { - // gcc 2.91 work around - int user_choice = 0; - user_choice = - QMessageBox::warning(this, 0, - "Profiler already started:\n\n" - "stop and restart it?", - "&Restart", "&Cancel", 0, 0, 1); - - if (user_choice == 1) - return; - - // this flush profiler data also. - on_stop_profiler(); - } - - vector args; - - // save_config validate and setup the config - if (save_config()) { - // now actually start - args.push_back("--start"); - if (config.verbose) - args.push_back("--verbose"); - do_exec_command(OP_BINDIR "/opcontrol", args); - } - - total_nr_interrupts = 0; - timerEvent(0); -} - - -bool oprof_start::save_config() -{ - if (!record_config()) - return false; - - vector args; - - // saving config is done by running opcontrol --setup with appropriate - // setted parameters so we use the same config file as command line - // tools - - args.push_back("--setup"); - - bool one_enabled = false; - - vector tmpargs; - tmpargs.push_back("--setup"); - - QListViewItem * cur; - for (cur = events_list->firstChild(); cur; cur = cur->nextSibling()) { - if (!cur->isSelected()) - continue; - - event_setting & cfg = event_cfgs[cur->text(0).latin1()]; - - op_event_descr const & descr = - locate_event(cur->text(0).latin1()); - - one_enabled = true; - - string arg = "--event=" + descr.name; - arg += ":" + op_lexical_cast(cfg.count); - arg += ":" + op_lexical_cast(cfg.umask); - arg += ":" + op_lexical_cast(cfg.os_ring_count); - arg += ":" + op_lexical_cast(cfg.user_ring_count); - - tmpargs.push_back(arg); - } - - // only set counters if at least one is enabled - if (one_enabled) - args = tmpargs; - - if (config.no_kernel) { - args.push_back("--no-vmlinux"); - } else { - args.push_back("--vmlinux=" + config.kernel_filename); - } - - if (op_get_interface() == OP_INTERFACE_24) { - args.push_back("--buffer-size=" + - op_lexical_cast(config.buffer_size)); - args.push_back("--note-table-size=" + - op_lexical_cast(config.note_table_size)); - } - - string sep = "--separate="; - - if (config.separate_lib) - sep += "library,"; - if (config.separate_kernel) - sep += "kernel,"; - if (config.separate_cpu) - sep += "cpu,"; - if (config.separate_thread) - sep += "thread,"; - - if (sep == "--separate=") - sep += "none"; - args.push_back(sep); - - // 2.95 work-around, it didn't like return !do_exec_command() - bool ret = !do_exec_command(OP_BINDIR "/opcontrol", args); - return ret; -} - - -// flush and stop the profiler if it was started. -void oprof_start::on_stop_profiler() -{ - vector args; - args.push_back("--shutdown"); - - if (daemon_status().running) - do_exec_command(OP_BINDIR "/opcontrol", args); - else - QMessageBox::warning(this, 0, "The profiler is already stopped."); - - timerEvent(0); -} - - -void oprof_start::on_separate_kernel_cb_changed(int state) -{ - if (state == 2) - separate_lib_cb->setChecked(true); -} - - -/// function object for matching against name -class event_name_eq { - string name_; -public: - explicit event_name_eq(string const & s) : name_(s) {} - bool operator()(op_event_descr const & d) const { - return d.name == name_; - } -}; - - -// helper to retrieve an event descr through its name. -op_event_descr const & oprof_start::locate_event(string const & name) const -{ - return *(find_if(v_events.begin(), v_events.end(), event_name_eq(name))); -} diff --git a/gui/oprof_start.h b/gui/oprof_start.h deleted file mode 100644 index 7f6212b..0000000 --- a/gui/oprof_start.h +++ /dev/null @@ -1,162 +0,0 @@ -/** - * @file oprof_start.h - * The GUI start main class - * - * @remark Copyright 2002 OProfile authors - * @remark Read the file COPYING - * - * @author Philippe Elie - * @author John Levon - */ - -#ifndef OPROF_START_H -#define OPROF_START_H - -#include -#include -#include - -#include "ui/oprof_start.base.h" -#include "oprof_start_config.h" - -#include "op_events.h" - -class QIntValidator; -class QListViewItem; -class QTimerEvent; - -/// a struct describing a particular event type -struct op_event_descr { - op_event_descr(); - - /// bit mask of allowed counters - uint counter_mask; - /// hardware event number - u8 val; - /// unit mask values if applicable - op_unit_mask const * unit; - /// name of event - std::string name; - /// description of event - std::string help_str; - /// minimum counter value - uint min_count; -}; - -class oprof_start : public oprof_start_base -{ - Q_OBJECT - -public: - oprof_start(); - -protected slots: - /// select the kernel image filename - void choose_kernel_filename(); - /// flush profiler - void on_flush_profiler_data(); - /// start profiler - void on_start_profiler(); - /// stop profiler - void on_stop_profiler(); - /// events selection change - void event_selected(); - /// the mouse is over an event - void event_over(QListViewItem *); - /// state of separate_kernel_cb changed - void on_separate_kernel_cb_changed(int); - - /// close the dialog - void accept(); - - /// WM hide event - void closeEvent(QCloseEvent * e); - - /// timer event - void timerEvent(QTimerEvent * e); - -private: - /// the counter combo has been activated - void fill_events_listbox(); - - /// fill the event details and gui setup - void fill_events(); - - /// find an event description by name - op_event_descr const & locate_event(std::string const & name) const; - - /// update config on user change - void record_selected_event_config(); - /// update config and validate - bool record_config(); - - /// calculate unit mask for given event and unit mask part - void get_unit_mask_part(op_event_descr const & descr, uint num, bool selected, uint & mask); - /// calculate unit mask for given event - uint get_unit_mask(op_event_descr const & descr); - /// set the unit mask widgets for given event - void setup_unit_masks(op_event_descr const & descr); - - /// return the maximum perf counter value for the current cpu type - uint max_perf_count() const; - - /// show an event's settings - void display_event(op_event_descr const & descrp); - - /// hide unit mask widgets - void hide_masks(void); - - /// read the events set in daemonrc - void read_set_events(); - /// use the default event - void setup_default_event(); - /// load the extra config file - void load_config_file(); - /// save the config - bool save_config(); - - /// redraw the event list by changing icon status - void draw_event_list(); - - /// return true if item is selectable or already selected - bool is_selectable_event(QListViewItem * item); - - /// try to alloc counters for the selected_events - bool alloc_selected_events() const; - - /// validator for event count - QIntValidator* event_count_validator; - - /// all available events for this hardware - std::vector v_events; - - /// current event configs for each counter - typedef std::map event_setting_map; - event_setting_map event_cfgs; - - /// The currently selected events. We must track this because - /// with multiple selection listbox QT doesn't allow to know - /// what is the last selected item. events_selected() update it - std::set selected_events; - QListViewItem * current_event; - - /// current config - config_setting config; - - /// the expansion of "~" directory - std::string user_dir; - - /// CPU type - op_cpu cpu_type; - - /// CPU speed in MHz - double cpu_speed; - - /// total number of available HW counters - uint op_nr_counters; - - /// Total number of samples for this run - unsigned long total_nr_interrupts; -}; - -#endif // OPROF_START_H diff --git a/gui/oprof_start_config.cpp b/gui/oprof_start_config.cpp deleted file mode 100644 index 162b130..0000000 --- a/gui/oprof_start_config.cpp +++ /dev/null @@ -1,103 +0,0 @@ -/** - * @file oprof_start_config.cpp - * GUI startup config management - * - * @remark Copyright 2002 OProfile authors - * @remark Read the file COPYING - * - * @author John Levon - * @author Philippe Elie - */ - -#include - -#include -#include -#include -#include - -#include "string_manip.h" -#include "oprof_start_config.h" -#include "op_config.h" -#include "op_config_24.h" - -using namespace std; - -event_setting::event_setting() - : - count(0), - umask(0), - os_ring_count(0), - user_ring_count(0) -{ -} - - -config_setting::config_setting() - : - buffer_size(OP_DEFAULT_BUF_SIZE), - note_table_size(OP_DEFAULT_NOTE_SIZE), - no_kernel(false), - verbose(false), - separate_lib(false), - separate_kernel(false), - separate_cpu(false), - separate_thread(false) -{ - struct utsname info; - - /* Guess path to vmlinux based on kernel currently running. */ - if (uname(&info)) { - perror("oprof_start: Unable to determine OS release."); - } else { - string const version(info.release); - string const vmlinux_path("/lib/modules/" + version - + "/build/vmlinux"); - kernel_filename = vmlinux_path; - } -} - - -void config_setting::load(istream & in) -{ - buffer_size = OP_DEFAULT_BUF_SIZE; - note_table_size = OP_DEFAULT_NOTE_SIZE; - - string str; - - while (getline(in, str)) { - string val = split(str, '='); - if (str == "BUF_SIZE") { - buffer_size = op_lexical_cast(val); - if (buffer_size < OP_DEFAULT_BUF_SIZE) - buffer_size = OP_DEFAULT_BUF_SIZE; - } else if (str == "NOTE_SIZE") { - note_table_size = op_lexical_cast(val); - if (note_table_size < OP_DEFAULT_NOTE_SIZE) - note_table_size = OP_DEFAULT_NOTE_SIZE; - } else if (str == "VMLINUX") { - if (val == "none") { - kernel_filename = ""; - no_kernel = true; - } else if (!val.empty()) { - no_kernel = false; - kernel_filename = val; - } - } else if (str == "SEPARATE_LIB") { - separate_lib = op_lexical_cast(val); - } else if (str == "SEPARATE_KERNEL") { - separate_kernel = op_lexical_cast(val); - } else if (str == "SEPARATE_CPU") { - separate_cpu = op_lexical_cast(val); - } else if (str == "SEPARATE_THREAD") { - separate_thread = op_lexical_cast(val); - } - } -} - - -istream & operator>>(istream & in, config_setting & object) -{ - object.load(in); - return in; -} diff --git a/gui/oprof_start_config.h b/gui/oprof_start_config.h deleted file mode 100644 index 3e82875..0000000 --- a/gui/oprof_start_config.h +++ /dev/null @@ -1,53 +0,0 @@ -/** - * @file oprof_start_config.h - * GUI startup config management - * - * @remark Copyright 2002 OProfile authors - * @remark Read the file COPYING - * - * @author John Levon - * @author Philippe Elie - */ - -#ifndef OPROF_START_CONFIG_H -#define OPROF_START_CONFIG_H - -#include -#include -#include - -/// Store the setup of one event -struct event_setting { - - event_setting(); - - uint count; - uint umask; - bool os_ring_count; - bool user_ring_count; -}; - -/** - * Store the general configuration of the profiler. - * There is no save(), instead opcontrol --setup must be - * called. This uses opcontrol's daemonrc file. - */ -struct config_setting { - config_setting(); - - void load(std::istream & in); - - uint buffer_size; - uint note_table_size; - std::string kernel_filename; - bool no_kernel; - bool verbose; - bool separate_lib; - bool separate_kernel; - bool separate_cpu; - bool separate_thread; -}; - -std::istream & operator>>(std::istream & in, config_setting & object); - -#endif // ! OPROF_START_CONFIG_H diff --git a/gui/oprof_start_main.cpp b/gui/oprof_start_main.cpp deleted file mode 100644 index 44da5de..0000000 --- a/gui/oprof_start_main.cpp +++ /dev/null @@ -1,27 +0,0 @@ -/** - * @file oprof_start_main.cpp - * main routine for GUI start - * - * @remark Copyright 2002 OProfile authors - * @remark Read the file COPYING - * - * @author Philippe Elie - * @author John Levon - */ - -#include - -#include "oprof_start.h" - -int main(int argc, char* argv[]) -{ - QApplication a(argc, argv); - - oprof_start* dlg = new oprof_start(); - - a.setMainWidget(dlg); - - dlg->show(); - - return a.exec(); -} diff --git a/gui/oprof_start_util.cpp b/gui/oprof_start_util.cpp deleted file mode 100644 index ded9cae..0000000 --- a/gui/oprof_start_util.cpp +++ /dev/null @@ -1,341 +0,0 @@ -/** - * @file oprof_start_util.cpp - * Miscellaneous helpers for the GUI start - * - * @remark Copyright 2002 OProfile authors - * @remark Read the file COPYING - * - * @author Philippe Elie - * @author John Levon - */ - -#include -#include -#include - -#include -#include -#include -#include -#include -#include - -#include -#include - -#include "op_file.h" -#include "file_manip.h" -#include "child_reader.h" -#include "op_libiberty.h" - -#include "oprof_start.h" -#include "oprof_start_util.h" - -using namespace std; - -namespace { - -// return the ~ expansion suffixed with a '/' -string const get_user_dir() -{ - static string user_dir; - - if (user_dir.empty()) { - char * dir = getenv("HOME"); - if (!dir) { - cerr << "Can't determine home directory !\n" << endl; - exit(EXIT_FAILURE); - } - - user_dir = dir; - - if (user_dir.length() && user_dir[user_dir.length() -1] != '/') - user_dir += '/'; - } - - return user_dir; -} - -string daemon_pid; - -} // namespace anon - -daemon_status::daemon_status() - : running(false) -{ - int HZ; - if (!daemon_pid.empty()) { - string const exec = - op_realpath(string("/proc/") + daemon_pid + "/exe"); - if (exec.empty()) - daemon_pid.erase(); - else - running = true; - } - - if (daemon_pid.empty()) { - DIR * dir; - struct dirent * dirent; - - if (!(dir = opendir("/proc"))) { - perror("oprofiled: /proc directory could not be opened. "); - exit(EXIT_FAILURE); - } - - while ((dirent = readdir(dir))) { - string const exec = - op_realpath(string("/proc/") - + dirent->d_name + "/exe"); - string const name = op_basename(exec); - if (name != "oprofiled") - continue; - - daemon_pid = dirent->d_name; - running = true; - } - - closedir(dir); - } - - HZ = sysconf(_SC_CLK_TCK); - if (HZ == -1) { - perror("oprofiled: Unable to determine clock ticks per second. "); - exit(EXIT_FAILURE); - } - - if (daemon_pid.empty()) - return; - - nr_interrupts = 0; - - switch (op_get_interface()) { - case OP_INTERFACE_24: - { - ifstream ifs3("/proc/sys/dev/oprofile/nr_interrupts"); - if (ifs3) - ifs3 >> nr_interrupts; - } - break; - case OP_INTERFACE_26: - { - static unsigned int old_sum_interrupts; - unsigned int sum_interrupts = 0; - glob_t file_names; - - file_names.gl_offs = 0; - glob("/dev/oprofile/stats/cpu*/sample_received", - GLOB_DOOFFS, NULL, &file_names); - - for (size_t i = 0; i < file_names.gl_pathc; ++i) { - ifstream ifs3(file_names.gl_pathv[i]); - if (ifs3) { - unsigned int file_interrupts; - ifs3 >> file_interrupts; - sum_interrupts += file_interrupts; - } - } - nr_interrupts = sum_interrupts - old_sum_interrupts; - old_sum_interrupts = sum_interrupts; - globfree(&file_names); - } - break; - default: - break; - } -} - - -/** - * get_user_filename - get absolute filename of file in user $HOME - * @param filename the relative filename - * - * Get the absolute path of a file in a user's home directory. - */ -string const get_user_filename(string const & filename) -{ - return get_user_dir() + "/" + filename; -} - - -/** - * check_and_create_config_dir - make sure config dir is accessible - * - * Returns %true if the dir is accessible. - */ -bool check_and_create_config_dir() -{ - string dir = get_user_filename(".oprofile"); - - char * name = xstrdup(dir.c_str()); - - if (create_dir(name)) { - ostringstream out; - out << "unable to create " << dir << " directory "; - out << "cause: " << strerror(errno); - QMessageBox::warning(0, 0, out.str().c_str()); - - free(name); - - return false; - } - - free(name); - return true; -} - - -/** - * format - re-format a string - * @param orig string to format - * @param maxlen width of line - * - * Re-formats a string to fit into a certain width, - * breaking lines at spaces between words. - * - * Returns the formatted string - */ -string const format(string const & orig, uint const maxlen) -{ - string text(orig); - - istringstream ss(text); - vector lines; - - string oline; - string line; - - while (getline(ss, oline)) { - if (line.size() + oline.size() < maxlen) { - lines.push_back(line + oline); - line.erase(); - } else { - lines.push_back(line); - line.erase(); - string s; - string word; - istringstream oss(oline); - while (oss >> word) { - if (line.size() + word.size() > maxlen) { - lines.push_back(line); - line.erase(); - } - line += word + " "; - } - } - } - - if (line.size()) - lines.push_back(line); - - string ret; - - for(vector::const_iterator it = lines.begin(); it != lines.end(); ++it) - ret += *it + "\n"; - - return ret; -} - - -/** - * do_exec_command - execute a command - * @param cmd command name - * @param args arguments to command - * - * Execute a command synchronously. An error message is shown - * if the command returns a non-zero status, which is also returned. - * - * The arguments are verified and will refuse to execute if they contain - * shell metacharacters. - */ -int do_exec_command(string const & cmd, vector const & args) -{ - ostringstream err; - bool ok = true; - - // verify arguments - for (vector::const_iterator cit = args.begin(); - cit != args.end(); ++cit) { - if (verify_argument(*cit)) - continue; - - QMessageBox::warning(0, 0, - string( - "Could not execute: Argument \"" + *cit + - "\" contains shell metacharacters.\n").c_str()); - return EINVAL; - } - - child_reader reader(cmd, args); - if (reader.error()) - ok = false; - - if (ok) - reader.get_data(cout, err); - - int ret = reader.terminate_process(); - if (ret) { - string error = reader.error_str() + "\n"; - error += "Failed: \n" + err.str() + "\n"; - string cmdline = cmd; - for (vector::const_iterator cit = args.begin(); - cit != args.end(); ++cit) { - cmdline += " " + *cit + " "; - } - error += "\n\nCommand was :\n\n" + cmdline + "\n"; - - QMessageBox::warning(0, 0, format(error, 50).c_str()); - } - - return ret; -} - - -/** - * do_open_file_or_dir - open file/directory - * @param base_dir directory to start at - * @param dir_only directory or filename to select - * - * Select a file or directory. The selection is returned; - * an empty string if the selection was cancelled. - */ -string const do_open_file_or_dir(string const & base_dir, bool dir_only) -{ - QString result; - - if (dir_only) { - result = QFileDialog::getExistingDirectory(base_dir.c_str(), 0, - "open_file_or_dir", "Get directory name", true); - } else { - result = QFileDialog::getOpenFileName(base_dir.c_str(), 0, 0, - "open_file_or_dir", "Get filename"); - } - - if (result.isNull()) - return string(); - else - return result.latin1(); -} - -/** - * verify_argument - check string for potentially dangerous characters - * - * This function returns false if the string contains dangerous shell - * metacharacters. - * - * WWW Security FAQ dangerous chars: - * - * & ; ` ' \ " | * ? ~ < > ^ ( ) [ ] { } $ \n \r - * - * David Wheeler: ! # - * - * We allow '-' because we disallow whitespace. We allow ':' and '=' - */ -bool verify_argument(string const & str) -{ - if (str.find_first_not_of( - "ABCDEFGHIJKLMNOPQRSTUVWXYZ" - "abcdefghijklmnopqrstuvwxyz0123456789_:=-+%,./") - != string::npos) - return false; - return true; -} diff --git a/gui/oprof_start_util.h b/gui/oprof_start_util.h deleted file mode 100644 index 52fafad..0000000 --- a/gui/oprof_start_util.h +++ /dev/null @@ -1,39 +0,0 @@ -/** - * @file oprof_start_util.h - * Miscellaneous helpers for the GUI start - * - * @remark Copyright 2002 OProfile authors - * @remark Read the file COPYING - * - * @author Philippe Elie - * @author John Levon - */ - -#ifndef OPROF_START_UTIL_H -#define OPROF_START_UTIL_H - -#include -#include -#include - -/// Store various daemon status data -struct daemon_status { - /// fill various data member according to the current daemon status - daemon_status(); - bool running; ///< true if daemon is running - unsigned int nr_interrupts; ///< nr_interrupts from profiling start -}; - -inline double ratio(double x1, double x2) -{ - return fabs(((x1 - x2) / x2)) * 100; -} - -std::string const get_user_filename(std::string const & filename); -bool check_and_create_config_dir(); -std::string const format(std::string const & orig, uint const maxlen); -int do_exec_command(std::string const & cmd, std::vector const & args = std::vector()); -std::string const do_open_file_or_dir(std::string const & base_dir, bool dir_only); -bool verify_argument(std::string const & str); - -#endif // OPROF_START_UTIL_H diff --git a/gui/ui/Makefile.am b/gui/ui/Makefile.am deleted file mode 100644 index 387ef4e..0000000 --- a/gui/ui/Makefile.am +++ /dev/null @@ -1,24 +0,0 @@ -EXTRA_DIST = oprof_start.base.ui - -if have_qt - -AM_CPPFLAGS = @QT_INCLUDES@ - -AM_CXXFLAGS = @OP_CXXFLAGS@ - -noinst_LIBRARIES = liboprof_start.a -nodist_liboprof_start_a_SOURCES = oprof_start.base.cpp oprof_start.base.moc.cpp - -oprof_start.base.h: oprof_start.base.ui - $(UIC) -o $@ $< - -oprof_start.base.cpp: oprof_start.base.h oprof_start.base.ui - $(UIC) -o $@ -impl $^ - -oprof_start.base.moc.cpp: oprof_start.base.h - $(MOC) -o $@ $< - -clean-local: - rm -f oprof_start.base.h oprof_start.base.cpp oprof_start.base.moc.cpp - -endif diff --git a/gui/ui/Makefile.in b/gui/ui/Makefile.in deleted file mode 100644 index a1587a4..0000000 --- a/gui/ui/Makefile.in +++ /dev/null @@ -1,453 +0,0 @@ -# Makefile.in generated by automake 1.9.5 from Makefile.am. -# @configure_input@ - -# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -# 2003, 2004, 2005 Free Software Foundation, Inc. -# This Makefile.in is free software; the Free Software Foundation -# gives unlimited permission to copy and/or distribute it, -# with or without modifications, as long as this notice is preserved. - -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY, to the extent permitted by law; without -# even the implied warranty of MERCHANTABILITY or FITNESS FOR A -# PARTICULAR PURPOSE. - -@SET_MAKE@ - -SOURCES = $(nodist_liboprof_start_a_SOURCES) - -srcdir = @srcdir@ -top_srcdir = @top_srcdir@ -VPATH = @srcdir@ -pkgdatadir = $(datadir)/@PACKAGE@ -pkglibdir = $(libdir)/@PACKAGE@ -pkgincludedir = $(includedir)/@PACKAGE@ -top_builddir = ../.. -am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd -INSTALL = @INSTALL@ -install_sh_DATA = $(install_sh) -c -m 644 -install_sh_PROGRAM = $(install_sh) -c -install_sh_SCRIPT = $(install_sh) -c -INSTALL_HEADER = $(INSTALL_DATA) -transform = $(program_transform_name) -NORMAL_INSTALL = : -PRE_INSTALL = : -POST_INSTALL = : -NORMAL_UNINSTALL = : -PRE_UNINSTALL = : -POST_UNINSTALL = : -subdir = gui/ui -DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in -ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 -am__aclocal_m4_deps = $(top_srcdir)/m4/binutils.m4 \ - $(top_srcdir)/m4/builtinexpect.m4 \ - $(top_srcdir)/m4/compileroption.m4 \ - $(top_srcdir)/m4/configmodule.m4 \ - $(top_srcdir)/m4/copyifchange.m4 $(top_srcdir)/m4/docbook.m4 \ - $(top_srcdir)/m4/extradirs.m4 $(top_srcdir)/m4/findkernel.m4 \ - $(top_srcdir)/m4/kerneloption.m4 \ - $(top_srcdir)/m4/kernelversion.m4 \ - $(top_srcdir)/m4/mallocattribute.m4 \ - $(top_srcdir)/m4/poptconst.m4 \ - $(top_srcdir)/m4/precompiledheader.m4 $(top_srcdir)/m4/qt.m4 \ - $(top_srcdir)/m4/resultyn.m4 $(top_srcdir)/m4/sstream.m4 \ - $(top_srcdir)/m4/typedef.m4 $(top_srcdir)/configure.in -am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ - $(ACLOCAL_M4) -mkinstalldirs = $(install_sh) -d -CONFIG_HEADER = $(top_builddir)/config.h -CONFIG_CLEAN_FILES = -LIBRARIES = $(noinst_LIBRARIES) -AR = ar -ARFLAGS = cru -liboprof_start_a_AR = $(AR) $(ARFLAGS) -liboprof_start_a_LIBADD = -@have_qt_TRUE@nodist_liboprof_start_a_OBJECTS = \ -@have_qt_TRUE@ oprof_start.base.$(OBJEXT) \ -@have_qt_TRUE@ oprof_start.base.moc.$(OBJEXT) -liboprof_start_a_OBJECTS = $(nodist_liboprof_start_a_OBJECTS) -DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir) -depcomp = $(SHELL) $(top_srcdir)/depcomp -am__depfiles_maybe = depfiles -CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ - $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -CXXLD = $(CXX) -CXXLINK = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) \ - -o $@ -SOURCES = $(nodist_liboprof_start_a_SOURCES) -DIST_SOURCES = -ETAGS = etags -CTAGS = ctags -DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) -ACLOCAL = @ACLOCAL@ -AMDEP_FALSE = @AMDEP_FALSE@ -AMDEP_TRUE = @AMDEP_TRUE@ -AMTAR = @AMTAR@ -AUTOCONF = @AUTOCONF@ -AUTOHEADER = @AUTOHEADER@ -AUTOMAKE = @AUTOMAKE@ -AWK = @AWK@ -BFD_LIBS = @BFD_LIBS@ -CAT_ENTRY_END = @CAT_ENTRY_END@ -CAT_ENTRY_START = @CAT_ENTRY_START@ -CC = @CC@ -CCDEPMODE = @CCDEPMODE@ -CFLAGS = @CFLAGS@ -CPP = @CPP@ -CPPFLAGS = @CPPFLAGS@ -CXX = @CXX@ -CXXCPP = @CXXCPP@ -CXXDEPMODE = @CXXDEPMODE@ -CXXFLAGS = @CXXFLAGS@ -CYGPATH_W = @CYGPATH_W@ -DATE = @DATE@ -DEFS = @DEFS@ -DEPDIR = @DEPDIR@ -DOCBOOK_ROOT = @DOCBOOK_ROOT@ -ECHO_C = @ECHO_C@ -ECHO_N = @ECHO_N@ -ECHO_T = @ECHO_T@ -EGREP = @EGREP@ -EXEEXT = @EXEEXT@ -EXTRA_CFLAGS_MODULE = @EXTRA_CFLAGS_MODULE@ -INSTALL_DATA = @INSTALL_DATA@ -INSTALL_PROGRAM = @INSTALL_PROGRAM@ -INSTALL_SCRIPT = @INSTALL_SCRIPT@ -INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ -KINC = @KINC@ -KSRC = @KSRC@ -KVERS = @KVERS@ -LD = @LD@ -LDFLAGS = @LDFLAGS@ -LIBERTY_LIBS = @LIBERTY_LIBS@ -LIBOBJS = @LIBOBJS@ -LIBS = @LIBS@ -LTLIBOBJS = @LTLIBOBJS@ -MAKEINFO = @MAKEINFO@ -MOC = @MOC@ -MODINSTALLDIR = @MODINSTALLDIR@ -OBJEXT = @OBJEXT@ -OPROFILE_DIR = @OPROFILE_DIR@ -OPROFILE_MODULE_ARCH = @OPROFILE_MODULE_ARCH@ -OP_CFLAGS = @OP_CFLAGS@ -OP_CXXFLAGS = @OP_CXXFLAGS@ -OP_DOCDIR = @OP_DOCDIR@ -PACKAGE = @PACKAGE@ -PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ -PACKAGE_NAME = @PACKAGE_NAME@ -PACKAGE_STRING = @PACKAGE_STRING@ -PACKAGE_TARNAME = @PACKAGE_TARNAME@ -PACKAGE_VERSION = @PACKAGE_VERSION@ -PATH_SEPARATOR = @PATH_SEPARATOR@ -POPT_LIBS = @POPT_LIBS@ -PTRDIFF_T_TYPE = @PTRDIFF_T_TYPE@ -QT_INCLUDES = @QT_INCLUDES@ -QT_LDFLAGS = @QT_LDFLAGS@ -QT_LIB = @QT_LIB@ -QT_VERSION = @QT_VERSION@ -RANLIB = @RANLIB@ -SET_MAKE = @SET_MAKE@ -SHELL = @SHELL@ -SIZE_T_TYPE = @SIZE_T_TYPE@ -STRIP = @STRIP@ -UIC = @UIC@ -VERSION = @VERSION@ -XML_CATALOG = @XML_CATALOG@ -XSLTPROC = @XSLTPROC@ -XSLTPROC_FLAGS = @XSLTPROC_FLAGS@ -X_CFLAGS = @X_CFLAGS@ -X_EXTRA_LIBS = @X_EXTRA_LIBS@ -X_LIBS = @X_LIBS@ -X_PRE_LIBS = @X_PRE_LIBS@ -ac_ct_CC = @ac_ct_CC@ -ac_ct_CXX = @ac_ct_CXX@ -ac_ct_RANLIB = @ac_ct_RANLIB@ -ac_ct_STRIP = @ac_ct_STRIP@ -am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ -am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ -am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@ -am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@ -am__include = @am__include@ -am__leading_dot = @am__leading_dot@ -am__quote = @am__quote@ -am__tar = @am__tar@ -am__untar = @am__untar@ -bindir = @bindir@ -build_alias = @build_alias@ -datadir = @datadir@ -enable_abi_FALSE = @enable_abi_FALSE@ -enable_abi_TRUE = @enable_abi_TRUE@ -exec_prefix = @exec_prefix@ -have_qt_FALSE = @have_qt_FALSE@ -have_qt_TRUE = @have_qt_TRUE@ -have_xsltproc_FALSE = @have_xsltproc_FALSE@ -have_xsltproc_TRUE = @have_xsltproc_TRUE@ -host_alias = @host_alias@ -includedir = @includedir@ -infodir = @infodir@ -install_sh = @install_sh@ -kernel_support_FALSE = @kernel_support_FALSE@ -kernel_support_TRUE = @kernel_support_TRUE@ -libdir = @libdir@ -libexecdir = @libexecdir@ -localstatedir = @localstatedir@ -mandir = @mandir@ -mkdir_p = @mkdir_p@ -oldincludedir = @oldincludedir@ -prefix = @prefix@ -program_transform_name = @program_transform_name@ -sbindir = @sbindir@ -sharedstatedir = @sharedstatedir@ -sysconfdir = @sysconfdir@ -target_alias = @target_alias@ -topdir = @topdir@ -EXTRA_DIST = oprof_start.base.ui -@have_qt_TRUE@AM_CPPFLAGS = @QT_INCLUDES@ -@have_qt_TRUE@AM_CXXFLAGS = @OP_CXXFLAGS@ -@have_qt_TRUE@noinst_LIBRARIES = liboprof_start.a -@have_qt_TRUE@nodist_liboprof_start_a_SOURCES = oprof_start.base.cpp oprof_start.base.moc.cpp -all: all-am - -.SUFFIXES: -.SUFFIXES: .cpp .o .obj -$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) - @for dep in $?; do \ - case '$(am__configure_deps)' in \ - *$$dep*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \ - && exit 0; \ - exit 1;; \ - esac; \ - done; \ - echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign gui/ui/Makefile'; \ - cd $(top_srcdir) && \ - $(AUTOMAKE) --foreign gui/ui/Makefile -.PRECIOUS: Makefile -Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status - @case '$?' in \ - *config.status*) \ - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ - *) \ - echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ - cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ - esac; - -$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -$(top_srcdir)/configure: $(am__configure_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh -$(ACLOCAL_M4): $(am__aclocal_m4_deps) - cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh - -clean-noinstLIBRARIES: - -test -z "$(noinst_LIBRARIES)" || rm -f $(noinst_LIBRARIES) -liboprof_start.a: $(liboprof_start_a_OBJECTS) $(liboprof_start_a_DEPENDENCIES) - -rm -f liboprof_start.a - $(liboprof_start_a_AR) liboprof_start.a $(liboprof_start_a_OBJECTS) $(liboprof_start_a_LIBADD) - $(RANLIB) liboprof_start.a - -mostlyclean-compile: - -rm -f *.$(OBJEXT) - -distclean-compile: - -rm -f *.tab.c - -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/oprof_start.base.Po@am__quote@ -@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/oprof_start.base.moc.Po@am__quote@ - -.cpp.o: -@am__fastdepCXX_TRUE@ if $(CXXCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ $<; \ -@am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCXX_FALSE@ $(CXXCOMPILE) -c -o $@ $< - -.cpp.obj: -@am__fastdepCXX_TRUE@ if $(CXXCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ `$(CYGPATH_W) '$<'`; \ -@am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ -@AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ -@am__fastdepCXX_FALSE@ $(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` -uninstall-info-am: - -ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ - mkid -fID $$unique -tags: TAGS - -TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - tags=; \ - here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ - if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ - test -n "$$unique" || unique=$$empty_fix; \ - $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ - $$tags $$unique; \ - fi -ctags: CTAGS -CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ - $(TAGS_FILES) $(LISP) - tags=; \ - here=`pwd`; \ - list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ - unique=`for i in $$list; do \ - if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ - done | \ - $(AWK) ' { files[$$0] = 1; } \ - END { for (i in files) print i; }'`; \ - test -z "$(CTAGS_ARGS)$$tags$$unique" \ - || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ - $$tags $$unique - -GTAGS: - here=`$(am__cd) $(top_builddir) && pwd` \ - && cd $(top_srcdir) \ - && gtags -i $(GTAGS_ARGS) $$here - -distclean-tags: - -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags - -distdir: $(DISTFILES) - @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ - topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ - list='$(DISTFILES)'; for file in $$list; do \ - case $$file in \ - $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ - $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ - esac; \ - if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ - dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ - if test "$$dir" != "$$file" && test "$$dir" != "."; then \ - dir="/$$dir"; \ - $(mkdir_p) "$(distdir)$$dir"; \ - else \ - dir=''; \ - fi; \ - if test -d $$d/$$file; then \ - if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ - cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ - fi; \ - cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ - else \ - test -f $(distdir)/$$file \ - || cp -p $$d/$$file $(distdir)/$$file \ - || exit 1; \ - fi; \ - done -check-am: all-am -check: check-am -all-am: Makefile $(LIBRARIES) -installdirs: -install: install-am -install-exec: install-exec-am -install-data: install-data-am -uninstall: uninstall-am - -install-am: all-am - @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am - -installcheck: installcheck-am -install-strip: - $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ - install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ - `test -z '$(STRIP)' || \ - echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install -mostlyclean-generic: - -clean-generic: - -distclean-generic: - -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) - -maintainer-clean-generic: - @echo "This command is intended for maintainers to use" - @echo "it deletes files that may require special tools to rebuild." -@have_qt_FALSE@clean-local: -clean: clean-am - -clean-am: clean-generic clean-local clean-noinstLIBRARIES \ - mostlyclean-am - -distclean: distclean-am - -rm -rf ./$(DEPDIR) - -rm -f Makefile -distclean-am: clean-am distclean-compile distclean-generic \ - distclean-tags - -dvi: dvi-am - -dvi-am: - -html: html-am - -info: info-am - -info-am: - -install-data-am: - -install-exec-am: - -install-info: install-info-am - -install-man: - -installcheck-am: - -maintainer-clean: maintainer-clean-am - -rm -rf ./$(DEPDIR) - -rm -f Makefile -maintainer-clean-am: distclean-am maintainer-clean-generic - -mostlyclean: mostlyclean-am - -mostlyclean-am: mostlyclean-compile mostlyclean-generic - -pdf: pdf-am - -pdf-am: - -ps: ps-am - -ps-am: - -uninstall-am: uninstall-info-am - -.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \ - clean-local clean-noinstLIBRARIES ctags distclean \ - distclean-compile distclean-generic distclean-tags distdir dvi \ - dvi-am html html-am info info-am install install-am \ - install-data install-data-am install-exec install-exec-am \ - install-info install-info-am install-man install-strip \ - installcheck installcheck-am installdirs maintainer-clean \ - maintainer-clean-generic mostlyclean mostlyclean-compile \ - mostlyclean-generic pdf pdf-am ps ps-am tags uninstall \ - uninstall-am uninstall-info-am - - -@have_qt_TRUE@oprof_start.base.h: oprof_start.base.ui -@have_qt_TRUE@ $(UIC) -o $@ $< - -@have_qt_TRUE@oprof_start.base.cpp: oprof_start.base.h oprof_start.base.ui -@have_qt_TRUE@ $(UIC) -o $@ -impl $^ - -@have_qt_TRUE@oprof_start.base.moc.cpp: oprof_start.base.h -@have_qt_TRUE@ $(MOC) -o $@ $< - -@have_qt_TRUE@clean-local: -@have_qt_TRUE@ rm -f oprof_start.base.h oprof_start.base.cpp oprof_start.base.moc.cpp -# Tell versions [3.59,3.63) of GNU make to not export all variables. -# Otherwise a system limit (for SysV at least) may be exceeded. -.NOEXPORT: diff --git a/gui/ui/oprof_start.base.ui b/gui/ui/oprof_start.base.ui deleted file mode 100644 index c54c215..0000000 --- a/gui/ui/oprof_start.base.ui +++ /dev/null @@ -1,1078 +0,0 @@ - -oprof_start_base - - QDialog - - name - oprof_start_base - - - geometry - - 0 - 0 - 569 - 735 - - - - caption - Start profiler - - - sizeGripEnabled - true - - - - margin - 11 - - - spacing - 6 - - - QTabWidget - - name - setup_config_tab - - - QWidget - - name - counter_setup_page - - - title - &Setup - - - - margin - 11 - - - spacing - 6 - - - QGroupBox - - name - counter_group - - - title - Events - - - - margin - 11 - - - spacing - 6 - - - QLayoutWidget - - name - Layout10 - - - - margin - 0 - - - spacing - 6 - - - QListView - - - text - Removedincode - - - clickable - false - - - resizeable - true - - - - name - events_list - - - minimumSize - - 250 - 0 - - - - selectionMode - Multi - - - toolTip - Available events - - - - QLayoutWidget - - name - Layout9 - - - - margin - 0 - - - spacing - 6 - - - QCheckBox - - name - os_ring_count_cb - - - text - Profile &kernel - - - toolTip - Profile kernel code - - - - QCheckBox - - name - user_ring_count_cb - - - text - Profile &user binaries - - - toolTip - Profile user libraries and applications - - - - QLayoutWidget - - name - Layout16 - - - - margin - 0 - - - spacing - 6 - - - QLabel - - name - TextLabel1_2 - - - text - C&ount - - - buddy - event_count_edit - - - - QLineEdit - - name - event_count_edit - - - sizePolicy - - 1 - 0 - - - - toolTip - Set the count value - - - - - name - Spacer13_2 - - - orientation - Horizontal - - - sizeType - Expanding - - - sizeHint - - 20 - 20 - - - - - - - QButtonGroup - - name - unit_mask_group - - - sizePolicy - - 1 - 5 - - - - title - Unit mask - - - toolTip - Unit mask settings for this event - - - - margin - 11 - - - spacing - 6 - - - QCheckBox - - name - check0 - - - text - check0 - - - - QCheckBox - - name - check1 - - - text - check1 - - - - QCheckBox - - name - check2 - - - text - check2 - - - - QCheckBox - - name - check3 - - - text - check3 - - - - QCheckBox - - name - check4 - - - text - check4 - - - - QCheckBox - - name - check5 - - - text - check5 - - - - QCheckBox - - name - check6 - - - text - check6 - - - - QCheckBox - - name - check7 - - - text - check7 - - - - - name - Spacer14 - - - orientation - Vertical - - - sizeType - Expanding - - - sizeHint - - 20 - 20 - - - - - QCheckBox - - name - check11 - - - text - check11 - - - - QCheckBox - - name - check13 - - - text - check13 - - - - QCheckBox - - name - check15 - - - text - check15 - - - - QCheckBox - - name - check10 - - - text - check10 - - - - QCheckBox - - name - check14 - - - text - check14 - - - - QCheckBox - - name - check9 - - - text - check9 - - - - QCheckBox - - name - check8 - - - text - check8 - - - - QCheckBox - - name - check12 - - - text - check12 - - - - - - - - - - QLabel - - name - event_help_label - - - enabled - true - - - sizePolicy - - 1 - 1 - - - - frameShape - WinPanel - - - frameShadow - Sunken - - - text - - - - - - - - - QWidget - - name - configuration_page - - - title - &Configuration - - - - margin - 11 - - - spacing - 6 - - - QLayoutWidget - - name - Layout11 - - - - margin - 0 - - - spacing - 6 - - - QLabel - - name - TextLabel1 - - - text - &Kernel image file - - - buddy - kernel_filename_edit - - - - QLineEdit - - name - kernel_filename_edit - - - toolTip - The vmlinux file of the running kernel - - - - QToolButton - - name - kernel_filename_tb - - - text - ... - - - - QCheckBox - - name - no_vmlinux - - - text - No kernel image - - - toolTip - No kernel image available. Disables kernel profiling. - - - - - - QLayoutWidget - - name - Layout16 - - - - margin - 0 - - - spacing - 6 - - - - name - Spacer11 - - - orientation - Horizontal - - - sizeType - Expanding - - - sizeHint - - 20 - 20 - - - - - QLayoutWidget - - name - Layout15 - - - - margin - 0 - - - spacing - 6 - - - QLineEdit - - name - buffer_size_edit - - - toolTip - The size of the profiler's buffers - - - - QLineEdit - - name - note_table_size_edit - - - - QLabel - - name - note_table_size_label - - - text - Note Size - - - buddy - note_table_size_edit - - - - QLabel - - name - buffer_size_label - - - text - &Buffer size - - - buddy - buffer_size_edit - - - - - - - - QLayoutWidget - - name - Layout11 - - - - margin - 0 - - - spacing - 6 - - - QLayoutWidget - - name - Layout10 - - - - margin - 0 - - - spacing - 6 - - - QCheckBox - - name - verbose - - - text - &Verbose - - - toolTip - Very verbose output in log file - - - - QCheckBox - - name - separate_lib_cb - - - text - Per-application profiles - - - toolTip - Separate samples for each shared library. This increases the time and space overhead of OProfile. - - - - QCheckBox - - name - separate_kernel_cb - - - text - Per-application profiles, including kernel - - - toolTip - Separate samples for each shared library and kernel samples. This increases the time and space overhead of OProfile. - - - - QCheckBox - - name - separate_cpu_cb - - - text - Per-CPU profiles - - - toolTip - Separate samples for each shared library and kernel samples. This increases the time and space overhead of OProfile. - - - - QCheckBox - - name - separate_thread_cb - - - text - Per-thread/task profiles - - - toolTip - Separate samples for each shared library and kernel samples. This increases the time and space overhead of OProfile. - - - - - - - name - Spacer12 - - - orientation - Horizontal - - - sizeType - Expanding - - - sizeHint - - 20 - 20 - - - - - - - - name - Spacer9 - - - orientation - Vertical - - - sizeType - Expanding - - - sizeHint - - 20 - 20 - - - - - - - - QLabel - - name - daemon_label - - - frameShape - Panel - - - frameShadow - Sunken - - - text - - - - toolTip - Current daemon status - - - - QLayoutWidget - - name - Layout11 - - - - margin - 0 - - - spacing - 6 - - - QPushButton - - name - start_profiler_btn - - - text - Start &profiler - - - - QPushButton - - name - flush_profiler_data_btn - - - text - &Flush profiler data - - - - QPushButton - - name - stop_profiler_btn - - - text - Stop profiler - - - - - name - Spacer5 - - - orientation - Horizontal - - - sizeType - Expanding - - - sizeHint - - 20 - 20 - - - - - QPushButton - - name - quit_and_save_btn - - - text - Save and &quit - - - autoDefault - true - - - - - - - - - start_profiler_btn - clicked() - oprof_start_base - on_start_profiler() - - - stop_profiler_btn - clicked() - oprof_start_base - on_stop_profiler() - - - flush_profiler_data_btn - clicked() - oprof_start_base - on_flush_profiler_data() - - - quit_and_save_btn - clicked() - oprof_start_base - accept() - - - kernel_filename_tb - clicked() - oprof_start_base - choose_kernel_filename() - - - no_vmlinux - toggled(bool) - kernel_filename_tb - setDisabled(bool) - - - no_vmlinux - toggled(bool) - kernel_filename_edit - setDisabled(bool) - - - no_vmlinux - toggled(bool) - TextLabel1 - setDisabled(bool) - - - events_list - selectionChanged() - oprof_start_base - event_selected() - - - events_list - onItem(QListViewItem*) - oprof_start_base - event_over(QListViewItem *) - - - separate_kernel_cb - stateChanged(int) - oprof_start_base - on_separate_kernel_cb_changed(int) - - choose_kernel_filename() - event_over(QListViewItem *) - event_selected() - on_flush_profiler_data() - on_separate_kernel_cb_changed(int) - on_start_profiler() - on_stop_profiler() - - - setup_config_tab - events_list - os_ring_count_cb - user_ring_count_cb - event_count_edit - check0 - check1 - check2 - check3 - check4 - check5 - check6 - check7 - check8 - check9 - check10 - check11 - check12 - check13 - check14 - check15 - start_profiler_btn - flush_profiler_data_btn - stop_profiler_btn - quit_and_save_btn - kernel_filename_edit - no_vmlinux - buffer_size_edit - note_table_size_edit - verbose - separate_kernel_cb - separate_lib_cb - - -- cgit v1.2.3