From: Mathieu Desnoyers Date: Mon, 12 Apr 2021 18:04:36 +0000 (-0400) Subject: sequence type: use previous field for length if length_name is NULL X-Git-Tag: v2.13.0-rc1~2 X-Git-Url: http://git.lttng.org/?a=commitdiff_plain;h=28db08270297a0e0654ce359069954bdc6c904f1;hp=28db08270297a0e0654ce359069954bdc6c904f1;p=lttng-ust.git sequence type: use previous field for length if length_name is NULL A common use-case for sequences is to use the field located immediately prior to the sequence as sequence length. The fact that the sequence type needs to explicitly contain its length name ties the sequence type to where it is placed within the structure fields, preventing re-use of the sequence type. In order to reduce the memory footprint of the field descriptions and allow re-use of common field types, special-case the NULL length_name to use the field prior to the sequence as length. This allows more efficient type descriptions without reducing the overall flexibility of sequence layout. Signed-off-by: Mathieu Desnoyers Change-Id: I5f2ae22ecc4d872d56f9302751990452fc34cb15 ---