diff options
author | Simon Hausmann <simon.hausmann@qt.io> | 2019-07-04 11:29:56 +0200 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@qt.io> | 2019-07-05 16:30:29 +0200 |
commit | 5a699e1416efe6a304d52df61b1a9247b7c4b3ed (patch) | |
tree | ef186631f85e19cd990b4b70451b7b8eb925b22b /src/qml/compiler/qv4compileddata_p.h | |
parent | 5cab256d3df331ee0795a3f5f9bb70eb48f12795 (diff) |
Reduce the size of signal parameters in qml cache data
We can reduce the distinction between a built-in type or a custom type
down to a single bit.
Change-Id: Ibe15d35357aa8c3948809f981221df29a40c400b
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Diffstat (limited to 'src/qml/compiler/qv4compileddata_p.h')
-rw-r--r-- | src/qml/compiler/qv4compileddata_p.h | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/qml/compiler/qv4compileddata_p.h b/src/qml/compiler/qv4compileddata_p.h index 8f427e0a7f..1656fd84aa 100644 --- a/src/qml/compiler/qv4compileddata_p.h +++ b/src/qml/compiler/qv4compileddata_p.h @@ -605,10 +605,13 @@ static_assert(sizeof(Enum) == 12, "Enum structure needs to have the expected siz struct Parameter { quint32_le nameIndex; - quint32_le type; - quint32_le customTypeNameIndex; + union { + quint32 _dummy; + quint32_le_bitfield<0, 1> indexIsBuiltinType; + quint32_le_bitfield<1, 31> typeNameIndexOrBuiltinType; + }; }; -static_assert(sizeof(Parameter) == 12, "Parameter structure needs to have the expected size to be binary compatible on disk when generated by host compiler and loaded by target"); +static_assert(sizeof(Parameter) == 8, "Parameter structure needs to have the expected size to be binary compatible on disk when generated by host compiler and loaded by target"); struct Signal { |