VirtualBox

Changeset 103464 in vbox


Ignore:
Timestamp:
Feb 20, 2024 2:35:20 AM (15 months ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
161798
Message:

VBoxDbg,FE/Qt: Made it possible to configure the sub-tree filtering via the command line. bugref:10376

Location:
trunk
Files:
10 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/VBox/dbggui.h

    r98103 r103464  
    6969    DECLCALLBACKMEMBER(void, pfnAdjustRelativePos,(PDBGGUI pGui, int x, int y, unsigned cx, unsigned cy));
    7070    /** @copydoc DBGGuiShowStatistics */
    71     DECLCALLBACKMEMBER(int, pfnShowStatistics,(PDBGGUI pGui, const char *pszFilter, const char *pszExpand));
     71    DECLCALLBACKMEMBER(int, pfnShowStatistics,(PDBGGUI pGui, const char *pszFilter, const char *pszExpand, const char *pszConfig));
    7272    /** @copydoc DBGGuiShowCommandLine */
    7373    DECLCALLBACKMEMBER(int, pfnShowCommandLine,(PDBGGUI pGui));
     
    152152 * @param   pszFilter   Filter pattern.
    153153 * @param   pszExpand   Expand pattern.
     154 * @param   pszConfig   Advanced filter configuration (min/max/regexp on
     155 *                      sub-trees) and more.
    154156 */
    155 DBGDECL(int) DBGGuiShowStatistics(PDBGGUI pGui, const char *pszFilter, const char *pszExpand);
     157DBGDECL(int) DBGGuiShowStatistics(PDBGGUI pGui, const char *pszFilter, const char *pszExpand, const char *pszConfig);
    156158
    157159/**
  • trunk/src/VBox/Debugger/VBoxDbg.cpp

    r103462 r103464  
    223223 * @param   pszFilter   Filter pattern.
    224224 * @param   pszExpand   Expand pattern.
    225  */
    226 DBGDECL(int) DBGGuiShowStatistics(PDBGGUI pGui, const char *pszFilter, const char *pszExpand)
     225 * @param   pszConfig   Advanced filter configuration (min/max/regexp on
     226 *                      sub-trees) and more.
     227 */
     228DBGDECL(int) DBGGuiShowStatistics(PDBGGUI pGui, const char *pszFilter, const char *pszExpand, const char *pszConfig)
    227229{
    228230    AssertReturn(pGui, VERR_INVALID_PARAMETER);
    229231    AssertMsgReturn(pGui->u32Magic == DBGGUI_MAGIC, ("u32Magic=%#x\n", pGui->u32Magic), VERR_INVALID_PARAMETER);
    230     return pGui->pVBoxDbgGui->showStatistics(pszFilter, pszExpand);
     232    return pGui->pVBoxDbgGui->showStatistics(pszFilter, pszExpand, pszConfig);
    231233}
    232234
  • trunk/src/VBox/Debugger/VBoxDbgGui.cpp

    r103462 r103464  
    182182
    183183int
    184 VBoxDbgGui::showStatistics(const char *pszFilter, const char *pszExpand)
     184VBoxDbgGui::showStatistics(const char *pszFilter, const char *pszExpand, const char *pszConfig)
    185185{
    186186    if (!m_pDbgStats)
     
    189189                                       pszFilter && *pszFilter ? pszFilter :  "*",
    190190                                       pszExpand && *pszExpand ? pszExpand : NULL,
     191                                       pszConfig && *pszConfig ? pszConfig : NULL,
    191192                                       2, m_pParent);
    192193        connect(m_pDbgStats, SIGNAL(destroyed(QObject *)), this, SLOT(notifyChildDestroyed(QObject *)));
  • trunk/src/VBox/Debugger/VBoxDbgGui.h

    r103462 r103464  
    105105     * @param   pszFilter   Filter pattern.
    106106     * @param   pszExpand   Expand pattern.
    107      */
    108     int showStatistics(const char *pszFilter, const char *pszExpand);
     107     * @param   pszConfig   Advanced filter configuration (min/max/regexp on
     108     *                      sub-trees) and more.
     109     */
     110    int showStatistics(const char *pszFilter, const char *pszExpand, const char *pszConfig);
    109111
    110112    /**
  • trunk/src/VBox/Debugger/VBoxDbgStatsQt.cpp

    r103463 r103464  
    144144            && pRegexName == NULL;
    145145    }
     146
     147    void reset(void)
     148    {
     149        uMinValue = 0;
     150        uMaxValue = UINT64_MAX;
     151        if (pRegexName)
     152        {
     153            delete pRegexName;
     154            pRegexName = NULL;
     155        }
     156    }
     157
     158    struct VBoxGuiStatsFilterData *duplicate(void) const
     159    {
     160        VBoxGuiStatsFilterData *pDup = new VBoxGuiStatsFilterData();
     161        pDup->uMinValue = uMinValue;
     162        pDup->uMaxValue = uMaxValue;
     163        if (pRegexName)
     164            pDup->pRegexName = new QRegularExpression(*pRegexName);
     165        return pDup;
     166    }
     167
    146168} VBoxGuiStatsFilterData;
    147169
     
    254276    bool m_fUpdateInsertRemove;
    255277
     278    /** Container indexed by node path and giving a filter config in return. */
     279    QHash<QString, VBoxGuiStatsFilterData *> m_FilterHash;
    256280
    257281public:
     
    259283     * Constructor.
    260284     *
    261      * @param   a_pParent       The parent object. See QAbstractItemModel in the Qt
    262      *                          docs for details.
    263      */
    264     VBoxDbgStatsModel(QObject *a_pParent);
     285     * @param   a_pszConfig Advanced filter configuration (min/max/regexp on
     286     *                      sub-trees) and more.
     287     * @param   a_pParent   The parent object. See QAbstractItemModel in the Qt
     288     *                      docs for details.
     289     */
     290    VBoxDbgStatsModel(const char *a_pszConfig, QObject *a_pParent);
    265291
    266292    /**
     
    358384
    359385    /** Creates the root node. */
    360     static PDBGGUISTATSNODE createRootNode(void);
     386    PDBGGUISTATSNODE createRootNode(void);
    361387
    362388    /** Creates and insert a node under the given parent. */
    363     static PDBGGUISTATSNODE createAndInsertNode(PDBGGUISTATSNODE pParent, const char *pszName, size_t cchName, uint32_t iPosition);
     389    PDBGGUISTATSNODE createAndInsertNode(PDBGGUISTATSNODE pParent, const char *pchName, size_t cchName, uint32_t iPosition,
     390                                         const char *pchFullName, size_t cchFullName);
    364391
    365392    /** Creates and insert a node under the given parent with correct Qt
    366393     * signalling. */
    367     PDBGGUISTATSNODE createAndInsert(PDBGGUISTATSNODE pParent, const char *pszName, size_t cchName, uint32_t iPosition);
     394    PDBGGUISTATSNODE createAndInsert(PDBGGUISTATSNODE pParent, const char *pszName, size_t cchName, uint32_t iPosition,
     395                                     const char *pchFullName, size_t cchFullName);
    368396
    369397    /**
     
    410438     * @param   pszName     The name of the tree element to update.
    411439     */
    412     PDBGGUISTATSNODE updateCallbackHandleOutOfOrder(const char *pszName);
     440    PDBGGUISTATSNODE updateCallbackHandleOutOfOrder(const char * const pszName);
    413441
    414442    /**
     
    648676    }
    649677
     678protected:
     679    /**
     680     * Populates m_FilterHash with configurations from @a a_pszConfig.
     681     *
     682     * @note This currently only work at construction time.
     683     */
     684    void loadFilterConfig(const char *a_pszConfig);
     685
    650686public:
    651687
     
    676712     * @param   a_pDbgGui       Pointer to the debugger gui object.
    677713     * @param   a_rPatStr       The selection pattern.
    678      * @param   a_pParent       The parent object. NULL is fine.
     714     * @param   a_pszConfig     Advanced filter configuration (min/max/regexp on
     715     *                          sub-trees) and more.
    679716     * @param   a_pVMM          The VMM function table.
    680      */
    681     VBoxDbgStatsModelVM(VBoxDbgGui *a_pDbgGui, QString &a_rPatStr, QObject *a_pParent, PCVMMR3VTABLE a_pVMM);
     717     * @param   a_pParent       The parent object. NULL is fine and default.
     718     */
     719    VBoxDbgStatsModelVM(VBoxDbgGui *a_pDbgGui, QString &a_rPatStr, const char *a_pszConfig,
     720                        PCVMMR3VTABLE a_pVMM, QObject *a_pParent = NULL);
    682721
    683722    /** Destructor */
     
    688727
    689728protected:
     729    typedef struct
     730    {
     731        PDBGGUISTATSNODE     pRoot;
     732        VBoxDbgStatsModelVM *pThis;
     733    } CreateNewTreeCallbackArgs_T;
     734
    690735    /**
    691736     * Enumeration callback used by createNewTree.
     
    726771    virtual ~VBoxDbgStatsSortFileProxyModel()
    727772    {}
     773
     774    /** Gets the unused-rows visibility status. */
     775    bool isShowingUnusedRows() const { return m_fShowUnusedRows; }
    728776
    729777    /** Sets whether or not to show unused rows (all zeros). */
     
    9991047
    10001048
    1001 VBoxDbgStatsModel::VBoxDbgStatsModel(QObject *a_pParent)
    1002     : QAbstractItemModel(a_pParent),
    1003     m_pRoot(NULL), m_iUpdateChild(UINT32_MAX), m_pUpdateParent(NULL), m_cchUpdateParent(0)
    1004 {
     1049VBoxDbgStatsModel::VBoxDbgStatsModel(const char *a_pszConfig, QObject *a_pParent)
     1050    : QAbstractItemModel(a_pParent)
     1051    , m_pRoot(NULL)
     1052    , m_iUpdateChild(UINT32_MAX)
     1053    , m_pUpdateParent(NULL)
     1054    , m_cchUpdateParent(0)
     1055{
     1056    /*
     1057     * Parse the advance filtering string as best as we can and
     1058     * populate the map of pending node filter configs with it.
     1059     */
     1060    loadFilterConfig(a_pszConfig);
    10051061}
    10061062
     
    10881144
    10891145
    1090 /*static*/ PDBGGUISTATSNODE
     1146PDBGGUISTATSNODE
    10911147VBoxDbgStatsModel::createRootNode(void)
    10921148{
     
    11001156    pRoot->cchName = 1;
    11011157    pRoot->enmState = kDbgGuiStatsNodeState_kRoot;
     1158    pRoot->pFilter = m_FilterHash.take("/");
    11021159
    11031160    return pRoot;
     
    11051162
    11061163
    1107 /*static*/ PDBGGUISTATSNODE
    1108 VBoxDbgStatsModel::createAndInsertNode(PDBGGUISTATSNODE pParent, const char *pszName, size_t cchName, uint32_t iPosition)
     1164PDBGGUISTATSNODE
     1165VBoxDbgStatsModel::createAndInsertNode(PDBGGUISTATSNODE pParent, const char *pchName, size_t cchName, uint32_t iPosition,
     1166                                       const char *pchFullName, size_t cchFullName)
    11091167{
    11101168    /*
     
    11171175    pNode->enmType = STAMTYPE_INVALID;
    11181176    pNode->pszUnit = "";
    1119     pNode->pszName = (char *)RTMemDupEx(pszName, cchName, 1);
     1177    pNode->pszName = (char *)RTMemDupEx(pchName, cchName, 1);
    11201178    pNode->cchName = cchName;
    11211179    pNode->enmState = kDbgGuiStatsNodeState_kVisible;
     1180    if (m_FilterHash.size() > 0 && cchFullName > 0)
     1181    {
     1182        char *pszTmp = RTStrDupN(pchFullName, cchFullName);
     1183        pNode->pFilter = m_FilterHash.take(QString(pszTmp));
     1184        RTStrFree(pszTmp);
     1185    }
    11221186
    11231187    /*
     
    11641228
    11651229PDBGGUISTATSNODE
    1166 VBoxDbgStatsModel::createAndInsert(PDBGGUISTATSNODE pParent, const char *pszName, size_t cchName, uint32_t iPosition)
     1230VBoxDbgStatsModel::createAndInsert(PDBGGUISTATSNODE pParent, const char *pszName, size_t cchName, uint32_t iPosition,
     1231                                   const char *pchFullName, size_t cchFullName)
    11671232{
    11681233    PDBGGUISTATSNODE pNode;
    11691234    if (m_fUpdateInsertRemove)
    1170         pNode = createAndInsertNode(pParent, pszName, cchName, iPosition);
     1235        pNode = createAndInsertNode(pParent, pszName, cchName, iPosition, pchFullName, cchFullName);
    11711236    else
    11721237    {
    11731238        beginInsertRows(createIndex(pParent->iSelf, 0, pParent), iPosition, iPosition);
    1174         pNode = createAndInsertNode(pParent, pszName, cchName, iPosition);
     1239        pNode = createAndInsertNode(pParent, pszName, cchName, iPosition, pchFullName, cchFullName);
    11751240        endInsertRows();
    11761241    }
     
    17361801
    17371802PDBGGUISTATSNODE
    1738 VBoxDbgStatsModel::updateCallbackHandleOutOfOrder(const char *pszName)
     1803VBoxDbgStatsModel::updateCallbackHandleOutOfOrder(const char * const pszName)
    17391804{
    17401805#if defined(VBOX_STRICT) || defined(LOG_ENABLED)
     
    18011866        {
    18021867            /* first child */
    1803             pNode = createAndInsert(pNode, pszSubName, cchSubName, 0);
     1868            pNode = createAndInsert(pNode, pszSubName, cchSubName, 0, pszName, pszEnd - pszName);
    18041869            AssertReturn(pNode, NULL);
    18051870        }
     
    18271892                    if (iStart > iLast)
    18281893                    {
    1829                         pNode = createAndInsert(pNode, pszSubName, cchSubName, iStart);
     1894                        pNode = createAndInsert(pNode, pszSubName, cchSubName, iStart, pszName, pszEnd - pszName);
    18301895                        AssertReturn(pNode, NULL);
    18311896                        break;
     
    18371902                    if (iLast < iStart)
    18381903                    {
    1839                         pNode = createAndInsert(pNode, pszSubName, cchSubName, i);
     1904                        pNode = createAndInsert(pNode, pszSubName, cchSubName, i, pszName, pszEnd - pszName);
    18401905                        AssertReturn(pNode, NULL);
    18411906                        break;
     
    19221987            ||  pNode->papChildren[pNode->cChildren - 1]->pszName[cchCur])
    19231988        {
    1924             pNode = createAndInsert(pNode, pszCur, pszNext - pszCur, pNode->cChildren);
     1989            pNode = createAndInsert(pNode, pszCur, pszNext - pszCur, pNode->cChildren, pszName, pszNext - pszName);
    19251990            AssertReturn(pNode, NULL);
    19261991        }
     
    30933158
    30943159
     3160void
     3161VBoxDbgStatsModel::loadFilterConfig(const char *a_pszConfig)
     3162{
     3163    /* Skip empty stuff. */
     3164    if (!a_pszConfig)
     3165        return;
     3166    a_pszConfig = RTStrStripL(a_pszConfig);
     3167    if (!*a_pszConfig)
     3168        return;
     3169
     3170    /*
     3171     * The list elements are separated by colons.  Paths must start with '/' to
     3172     * be accepted as such.
     3173     *
     3174     * Example: "/;min=123;max=9348;name='.*cmp.*';/CPUM;"
     3175     */
     3176    char * const pszDup  = RTStrDup(a_pszConfig);
     3177    AssertReturnVoid(pszDup);
     3178    char        *psz     = pszDup;
     3179    const char  *pszPath = NULL;
     3180    VBoxGuiStatsFilterData Data;
     3181    do
     3182    {
     3183        /* Split out this item, strip it and move 'psz' to the next one. */
     3184        char *pszItem = psz;
     3185        psz = strchr(psz, ';');
     3186        if (psz)
     3187            *psz++ = '\0';
     3188        else
     3189            psz = strchr(psz, '\0');
     3190        pszItem = RTStrStrip(pszItem);
     3191
     3192        /* Is it a path or a variable=value pair. */
     3193        if (*pszItem == '/')
     3194        {
     3195            if (pszPath && !Data.isAllDefaults())
     3196                m_FilterHash[QString(pszPath)] = Data.duplicate();
     3197            Data.reset();
     3198            pszPath = pszItem;
     3199        }
     3200        else
     3201        {
     3202            /* Split out the value, if any.  */
     3203            char *pszValue = strchr(pszItem, '=');
     3204            if (pszValue)
     3205            {
     3206                *pszValue++ = '\0';
     3207                pszValue = RTStrStripL(pszValue);
     3208                RTStrStripR(pszItem);
     3209
     3210                /* Switch on the variable name. */
     3211                uint64_t const uValue = RTStrToUInt64(pszValue);
     3212                if (strcmp(pszItem, "min") == 0)
     3213                    Data.uMinValue = uValue;
     3214                else if (strcmp(pszItem, "max") == 0)
     3215                    Data.uMaxValue = uValue != 0 ? uValue : UINT64_MAX;
     3216                else if (strcmp(pszItem, "name") == 0)
     3217                {
     3218                    if (!Data.pRegexName)
     3219                        Data.pRegexName = new QRegularExpression(QString(pszValue));
     3220                    else
     3221                        Data.pRegexName->setPattern(QString(pszValue));
     3222                    if (!Data.pRegexName->isValid())
     3223                    {
     3224                        delete Data.pRegexName;
     3225                        Data.pRegexName = NULL;
     3226                    }
     3227                }
     3228            }
     3229            /* else: Currently no variables w/o values. */
     3230        }
     3231    } while (*psz != '\0');
     3232
     3233    /* Add the final entry, if any. */
     3234    if (pszPath && !Data.isAllDefaults())
     3235        m_FilterHash[QString(pszPath)] = Data.duplicate();
     3236
     3237    RTStrFree(pszDup);
     3238}
    30953239
    30963240
     
    31083252
    31093253
    3110 VBoxDbgStatsModelVM::VBoxDbgStatsModelVM(VBoxDbgGui *a_pDbgGui, QString &a_rPatStr, QObject *a_pParent, PCVMMR3VTABLE a_pVMM)
    3111     : VBoxDbgStatsModel(a_pParent), VBoxDbgBase(a_pDbgGui), m_pVMM(a_pVMM)
     3254VBoxDbgStatsModelVM::VBoxDbgStatsModelVM(VBoxDbgGui *a_pDbgGui, QString &a_rPatStr, const char *a_pszConfig,
     3255                                         PCVMMR3VTABLE a_pVMM, QObject *a_pParent /*= NULL*/)
     3256    : VBoxDbgStatsModel(a_pszConfig, a_pParent), VBoxDbgBase(a_pDbgGui), m_pVMM(a_pVMM)
    31123257{
    31133258    /*
     
    31543299                                           const char *pszUnit, STAMVISIBILITY enmVisibility, const char *pszDesc, void *pvUser)
    31553300{
    3156     PDBGGUISTATSNODE pRoot = (PDBGGUISTATSNODE)pvUser;
     3301    CreateNewTreeCallbackArgs_T * const pArgs = (CreateNewTreeCallbackArgs_T *)pvUser;
    31573302    Log3(("createNewTreeCallback: %s\n", pszName));
    31583303    RT_NOREF(enmUnit);
     
    31703315     */
    31713316    AssertReturn(*pszName == '/' && pszName[1] != '/', VERR_INTERNAL_ERROR);
    3172     PDBGGUISTATSNODE pNode = pRoot;
     3317    PDBGGUISTATSNODE pNode = pArgs->pRoot;
    31733318    const char *pszCur = pszName + 1;
    31743319    while (*pszCur)
     
    31853330            ||  pNode->papChildren[pNode->cChildren - 1]->pszName[cchCur])
    31863331        {
    3187             pNode = createAndInsertNode(pNode, pszCur, pszNext - pszCur, UINT32_MAX);
     3332            pNode = pArgs->pThis->createAndInsertNode(pNode, pszCur, pszNext - pszCur, UINT32_MAX, pszName, pszNext - pszName);
    31883333            if (!pNode)
    31893334                return VERR_NO_MEMORY;
     
    32093354    if (pRoot)
    32103355    {
    3211         int rc = stamEnum(a_rPatStr, createNewTreeCallback, pRoot);
     3356        CreateNewTreeCallbackArgs_T Args = { pRoot, this };
     3357        int rc = stamEnum(a_rPatStr, createNewTreeCallback, &Args);
    32123358        if (RT_SUCCESS(rc))
    32133359            return pRoot;
     
    38784024     */
    38794025    QModelIndex Idx = m_pCurMenu ? m_CurIndex : currentIndex();
    3880     if (Idx.isValid())
     4026    if (!Idx.isValid())
    38814027        Idx = myGetRootIndex();
    38824028    Idx = m_pProxyModel->mapToSource(Idx);
     
    40064152    if (m_Data.isAllDefaults())
    40074153        return NULL;
    4008     VBoxGuiStatsFilterData *pRet = new VBoxGuiStatsFilterData();
    4009     pRet->uMinValue  = m_Data.uMinValue;
    4010     pRet->uMaxValue  = m_Data.uMaxValue;
    4011     if (m_Data.pRegexName)
    4012         pRet->pRegexName = new QRegularExpression(*m_Data.pRegexName);
    4013     return pRet;
     4154    return m_Data.duplicate();
    40144155}
    40154156
     
    40874228
    40884229VBoxDbgStats::VBoxDbgStats(VBoxDbgGui *a_pDbgGui, const char *pszFilter /*= NULL*/, const char *pszExpand /*= NULL*/,
    4089                            unsigned uRefreshRate/* = 0*/, QWidget *pParent/* = NULL*/)
     4230                           const char *pszConfig /*= NULL*/, unsigned uRefreshRate/* = 0*/, QWidget *pParent/* = NULL*/)
    40904231    : VBoxDbgBaseWindow(a_pDbgGui, pParent, "Statistics")
    40914232    , m_PatStr(pszFilter), m_pPatCB(NULL), m_uRefreshRate(0), m_pTimer(NULL), m_pView(NULL)
     
    41454286     * Create the tree view and setup the layout.
    41464287     */
    4147     VBoxDbgStatsModelVM *pModel = new VBoxDbgStatsModelVM(a_pDbgGui, m_PatStr, NULL, a_pDbgGui->getVMMFunctionTable());
     4288    VBoxDbgStatsModelVM *pModel = new VBoxDbgStatsModelVM(a_pDbgGui, m_PatStr, pszConfig, a_pDbgGui->getVMMFunctionTable());
    41484289#ifdef VBOXDBG_WITH_SORTED_AND_FILTERED_STATS
    41494290    VBoxDbgStatsSortFileProxyModel *pProxyModel = new VBoxDbgStatsSortFileProxyModel(this);
    41504291    m_pView = new VBoxDbgStatsView(a_pDbgGui, pModel, pProxyModel, this);
     4292    pCheckBox->setCheckState(pProxyModel->isShowingUnusedRows() ? Qt::Checked : Qt::Unchecked);
    41514293#else
    41524294    m_pView = new VBoxDbgStatsView(a_pDbgGui, pModel, NULL, this);
  • trunk/src/VBox/Debugger/VBoxDbgStatsQt.h

    r103462 r103464  
    244244     * @param   pszExpand       Initial expansion pattern. NULL means nothing is
    245245     *                          expanded.
     246     * @param   pszConfig       Advanced filter configuration (min/max/regexp on
     247     *                          sub-trees) and more.
     248     *
    246249     * @param   uRefreshRate    The refresh rate. 0 means not to refresh and is the default.
    247250     * @param   pParent         Parent widget.
    248251     */
    249252    VBoxDbgStats(VBoxDbgGui *a_pDbgGui, const char *pszFilter = NULL, const char *pszExpand = NULL,
    250                  unsigned uRefreshRate = 0, QWidget *pParent = NULL);
     253                 const char *pszConfig = NULL, unsigned uRefreshRate = 0, QWidget *pParent = NULL);
    251254
    252255    /** Destructor. */
  • trunk/src/VBox/Frontends/VirtualBox/src/globals/UICommon.cpp

    r103280 r103464  
    595595            m_strDbgStatisticsFilter = arguments.at(i).section('=', 1);
    596596        }
     597        else if (!::strcmp(arg, "--statistics-config") || !::strcmp(arg, "--stats-config"))
     598        {
     599            enmOptType = OptType_VMRunner;
     600            if (++i < argc)
     601                m_strDbgStatisticsConfig = arguments.at(i);
     602        }
     603        else if (!::strncmp(arg, RT_STR_TUPLE("--statistics-config=")) || !::strncmp(arg, RT_STR_TUPLE("--stats-config=")))
     604        {
     605            enmOptType = OptType_VMRunner;
     606            m_strDbgStatisticsConfig = arguments.at(i).section('=', 1);
     607        }
    597608        else if (!::strcmp(arg, "-no-debug") || !::strcmp(arg, "--no-debug"))
    598609        {
  • trunk/src/VBox/Frontends/VirtualBox/src/globals/UICommon.h

    r102750 r103464  
    308308        /** Returns the --statistics-filter value. */
    309309        QString const getDebuggerStatisticsFilter() const { return m_strDbgStatisticsFilter; }
     310        /** Returns the --statistics-config value. */
     311        QString const getDebuggerStatisticsConfig() const { return m_strDbgStatisticsConfig; }
    310312
    311313        /** VBoxDbg module handle. */
     
    732734        /** Pattern of statistics to expand when opening the viewer. */
    733735        QString      m_strDbgStatisticsExpand;
    734         /** The statistics viewer filter. */
     736        /** The statistics viewer main filter pattern. */
    735737        QString      m_strDbgStatisticsFilter;
     738        /** The statistics viewer advanced filter configuration and possibly more. */
     739        QString      m_strDbgStatisticsConfig;
    736740
    737741        /** VBoxDbg module handle. */
  • trunk/src/VBox/Frontends/VirtualBox/src/main.cpp

    r103246 r103464  
    286286        "  --statistics-expand <pat>  expand the matching statistics (can be repeated)\n"
    287287        "  --statistics-filter <pat>  statistics filter\n"
     288        "  --statistics-config <str>  statistics configuration\n"
    288289        "  --no-debug                 disable the GUI debug menu and debug windows\n"
    289290        "  --start-paused             start the VM in the paused state\n"
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/UISession.cpp

    r103362 r103464  
    23002300void UISession::dbgShowStatistics()
    23012301{
     2302    const QByteArray &filterBytes = uiCommon().getDebuggerStatisticsFilter().toUtf8();
    23022303    const QByteArray &expandBytes = uiCommon().getDebuggerStatisticsExpand().toUtf8();
    2303     const QByteArray &filterBytes = uiCommon().getDebuggerStatisticsFilter().toUtf8();
    2304     m_pDbgGuiVT->pfnShowStatistics(m_pDbgGui, filterBytes.constData(), expandBytes.constData());
     2304    const QByteArray &configBytes = uiCommon().getDebuggerStatisticsConfig().toUtf8();
     2305    m_pDbgGuiVT->pfnShowStatistics(m_pDbgGui, filterBytes.constData(), expandBytes.constData(), configBytes.constData());
    23052306}
    23062307
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette