aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/memory/qv4mmdefs_p.h
diff options
context:
space:
mode:
authorRobin Burchell <robin.burchell@crimson.no>2017-02-14 14:03:56 +0100
committerRobin Burchell <robin.burchell@crimson.no>2017-04-20 22:33:55 +0000
commit0745a27d82ab0b074dc2bc1c4c4f30624831b384 (patch)
tree2be24ca2721c74064d8859ebdd9717ebb6e06053 /src/qml/memory/qv4mmdefs_p.h
parent1f3d52ac9d877a960bd5c1a6123bec6c6df586c3 (diff)
MM: Provide information about object types on sweep
Helps give an idea about what kind of garbage is being tossed away. v8-bench shows no real change in performance outside "usual" variance, I didn't benchmark QV4_MM_STATS=1 but I assume there will be some penalty there. Change-Id: Ida0c5917289891279d95fd47480bd4869b42b0e6 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/qml/memory/qv4mmdefs_p.h')
-rw-r--r--src/qml/memory/qv4mmdefs_p.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/qml/memory/qv4mmdefs_p.h b/src/qml/memory/qv4mmdefs_p.h
index 9512722782..bf29b44a2c 100644
--- a/src/qml/memory/qv4mmdefs_p.h
+++ b/src/qml/memory/qv4mmdefs_p.h
@@ -61,6 +61,8 @@ namespace QV4 {
struct MarkStack;
+typedef void(*ClassDestroyStatsCallback)(const char *);
+
/*
* Chunks are the basic structure containing GC managed objects.
*
@@ -184,7 +186,7 @@ struct Chunk {
return usedSlots;
}
- void sweep();
+ void sweep(ClassDestroyStatsCallback classCountPtr);
void freeAll();
void resetBlackBits();
void collectGrayItems(QV4::MarkStack *markStack);