VirtualBox

source: vbox/trunk/src/VBox/VMM/VMMAll/MMAll.cpp@ 101189

Last change on this file since 101189 was 98103, checked in by vboxsync, 2 years ago

Copyright year updates by scm.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id Revision
File size: 3.9 KB
Line 
1/* $Id: MMAll.cpp 98103 2023-01-17 14:15:46Z vboxsync $ */
2/** @file
3 * MM - Memory Manager - Any Context.
4 */
5
6/*
7 * Copyright (C) 2006-2023 Oracle and/or its affiliates.
8 *
9 * This file is part of VirtualBox base platform packages, as
10 * available from https://www.virtualbox.org.
11 *
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License
14 * as published by the Free Software Foundation, in version 3 of the
15 * License.
16 *
17 * This program is distributed in the hope that it will be useful, but
18 * WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20 * General Public License for more details.
21 *
22 * You should have received a copy of the GNU General Public License
23 * along with this program; if not, see <https://www.gnu.org/licenses>.
24 *
25 * SPDX-License-Identifier: GPL-3.0-only
26 */
27
28
29/*********************************************************************************************************************************
30* Header Files *
31*********************************************************************************************************************************/
32#define LOG_GROUP LOG_GROUP_MM_HYPER
33#include <VBox/vmm/mm.h>
34#include <VBox/vmm/vmm.h>
35#include "MMInternal.h"
36#include <VBox/vmm/vmcc.h>
37#include <VBox/vmm/hm.h>
38#include <VBox/log.h>
39#include <iprt/assert.h>
40#include <iprt/string.h>
41
42
43/**
44 * Gets the string name of a memory tag.
45 *
46 * @returns name of enmTag.
47 * @param enmTag The tag.
48 */
49const char *mmGetTagName(MMTAG enmTag)
50{
51 switch (enmTag)
52 {
53 #define TAG2STR(tag) case MM_TAG_##tag: return #tag
54
55 TAG2STR(CFGM);
56 TAG2STR(CFGM_BYTES);
57 TAG2STR(CFGM_STRING);
58 TAG2STR(CFGM_USER);
59
60 TAG2STR(CPUM_CTX);
61 TAG2STR(CPUM_CPUID);
62 TAG2STR(CPUM_MSRS);
63
64 TAG2STR(CSAM);
65 TAG2STR(CSAM_PATCH);
66
67 TAG2STR(DBGF);
68 TAG2STR(DBGF_AS);
69 TAG2STR(DBGF_FLOWTRACE);
70 TAG2STR(DBGF_INFO);
71 TAG2STR(DBGF_LINE);
72 TAG2STR(DBGF_LINE_DUP);
73 TAG2STR(DBGF_MODULE);
74 TAG2STR(DBGF_OS);
75 TAG2STR(DBGF_REG);
76 TAG2STR(DBGF_STACK);
77 TAG2STR(DBGF_SYMBOL);
78 TAG2STR(DBGF_SYMBOL_DUP);
79 TAG2STR(DBGF_TYPE);
80 TAG2STR(DBGF_TRACER);
81
82 TAG2STR(EM);
83
84 TAG2STR(IEM);
85
86 TAG2STR(IOM);
87 TAG2STR(IOM_STATS);
88
89 TAG2STR(MM);
90 TAG2STR(MM_LOOKUP_GUEST);
91 TAG2STR(MM_LOOKUP_PHYS);
92 TAG2STR(MM_LOOKUP_VIRT);
93 TAG2STR(MM_PAGE);
94
95 TAG2STR(PARAV);
96
97 TAG2STR(PATM);
98 TAG2STR(PATM_PATCH);
99
100 TAG2STR(PDM);
101 TAG2STR(PDM_DEVICE);
102 TAG2STR(PDM_DEVICE_DESC);
103 TAG2STR(PDM_DEVICE_USER);
104 TAG2STR(PDM_DRIVER);
105 TAG2STR(PDM_DRIVER_DESC);
106 TAG2STR(PDM_DRIVER_USER);
107 TAG2STR(PDM_USB);
108 TAG2STR(PDM_USB_DESC);
109 TAG2STR(PDM_USB_USER);
110 TAG2STR(PDM_LUN);
111 TAG2STR(PDM_QUEUE);
112 TAG2STR(PDM_THREAD);
113 TAG2STR(PDM_ASYNC_COMPLETION);
114#ifdef VBOX_WITH_NETSHAPER
115 TAG2STR(PDM_NET_SHAPER);
116#endif /* VBOX_WITH_NETSHAPER */
117
118 TAG2STR(PGM);
119 TAG2STR(PGM_CHUNK_MAPPING);
120 TAG2STR(PGM_HANDLERS);
121 TAG2STR(PGM_HANDLER_TYPES);
122 TAG2STR(PGM_MAPPINGS);
123 TAG2STR(PGM_PHYS);
124 TAG2STR(PGM_POOL);
125
126 TAG2STR(REM);
127
128 TAG2STR(SELM);
129
130 TAG2STR(SSM);
131
132 TAG2STR(STAM);
133
134 TAG2STR(TM);
135
136 TAG2STR(TRPM);
137
138 TAG2STR(VM);
139 TAG2STR(VM_REQ);
140
141 TAG2STR(VMM);
142
143 TAG2STR(HM);
144
145 #undef TAG2STR
146
147 default:
148 {
149 AssertMsgFailed(("Unknown tag %d! forgot to add it to the switch?\n", enmTag));
150#ifdef IN_RING3
151 static char sz[48];
152 RTStrPrintf(sz, sizeof(sz), "%d", enmTag);
153 return sz;
154#else
155 return "unknown tag!";
156#endif
157 }
158 }
159}
160
Note: See TracBrowser for help on using the repository browser.

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