Commit c3235e2
KVM: s390: add stat counter for shadow gmap events
The shadow gmap tracks memory of nested guests (guest-3). In certain
scenarios, the shadow gmap needs to be rebuilt, which is a costly operation
since it involves a SIE exit into guest-1 for every entry in the respective
shadow level.
Add kvm stat counters when new shadow structures are created at various
levels. Also add a counter gmap_shadow_create when a completely fresh
shadow gmap is created as well as a counter gmap_shadow_reuse when an
existing gmap is being reused.
Note that when several levels are shadowed at once, counters on all
affected levels will be increased.
Also note that not all page table levels need to be present and a ASCE
can directly point to e.g. a segment table. In this case, a new segment
table will always be equivalent to a new shadow gmap and hence will be
counted as gmap_shadow_create and not as gmap_shadow_segment.
Signed-off-by: Nico Boehr <[email protected]>
Reviewed-by: David Hildenbrand <[email protected]>
Reviewed-by: Claudio Imbrenda <[email protected]>
Reviewed-by: Janosch Frank <[email protected]>
Signed-off-by: Janosch Frank <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Message-Id: <[email protected]>1 parent ce9ecca commit c3235e2
File tree
4 files changed
+26
-2
lines changed- arch/s390
- include/asm
- kvm
4 files changed
+26
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
777 | 777 | | |
778 | 778 | | |
779 | 779 | | |
| 780 | + | |
| 781 | + | |
| 782 | + | |
| 783 | + | |
| 784 | + | |
| 785 | + | |
| 786 | + | |
780 | 787 | | |
781 | 788 | | |
782 | 789 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1382 | 1382 | | |
1383 | 1383 | | |
1384 | 1384 | | |
| 1385 | + | |
1385 | 1386 | | |
1386 | 1387 | | |
1387 | 1388 | | |
| |||
1390 | 1391 | | |
1391 | 1392 | | |
1392 | 1393 | | |
| 1394 | + | |
1393 | 1395 | | |
1394 | 1396 | | |
1395 | 1397 | | |
| |||
1450 | 1452 | | |
1451 | 1453 | | |
1452 | 1454 | | |
| 1455 | + | |
1453 | 1456 | | |
1454 | 1457 | | |
1455 | 1458 | | |
| |||
1478 | 1481 | | |
1479 | 1482 | | |
1480 | 1483 | | |
| 1484 | + | |
1481 | 1485 | | |
1482 | 1486 | | |
1483 | 1487 | | |
| |||
1515 | 1519 | | |
1516 | 1520 | | |
1517 | 1521 | | |
| 1522 | + | |
1518 | 1523 | | |
1519 | 1524 | | |
1520 | 1525 | | |
| |||
1548 | 1553 | | |
1549 | 1554 | | |
1550 | 1555 | | |
| 1556 | + | |
1551 | 1557 | | |
1552 | 1558 | | |
1553 | 1559 | | |
| |||
1618 | 1624 | | |
1619 | 1625 | | |
1620 | 1626 | | |
| 1627 | + | |
1621 | 1628 | | |
1622 | 1629 | | |
1623 | 1630 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
66 | 66 | | |
67 | 67 | | |
68 | 68 | | |
69 | | - | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
70 | 77 | | |
71 | 78 | | |
72 | 79 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1214 | 1214 | | |
1215 | 1215 | | |
1216 | 1216 | | |
1217 | | - | |
| 1217 | + | |
| 1218 | + | |
1218 | 1219 | | |
| 1220 | + | |
1219 | 1221 | | |
1220 | 1222 | | |
1221 | 1223 | | |
1222 | 1224 | | |
1223 | 1225 | | |
1224 | 1226 | | |
1225 | 1227 | | |
| 1228 | + | |
1226 | 1229 | | |
1227 | 1230 | | |
1228 | 1231 | | |
| |||
0 commit comments