-union flist_extras {
- uid_t uid; /* the user ID number */
- uid_t gid; /* the group ID number or GID_NONE */
- struct idev *idev; /* The hard-link info during matching */
- struct hlist *hlist; /* The hard-link info after matching */
- int32 num; /* A general-purpose number */
-};
+#define FILE_STRUCT_LEN (offsetof(struct file_struct, flags) \
+ + sizeof (unsigned short))
+#define EXTRA_LEN (sizeof (union flist_extras))
+#define SUM_EXTRA_CNT ((MD4_SUM_LENGTH + EXTRA_LEN - 1) / EXTRA_LEN)
+
+#define REQ_EXTRA(f,ndx) ((f)->extras - (ndx - 1))
+#define OPT_EXTRA(f,bump) ((f)->extras - flist_extra_cnt - (bump))
+#define LEN64_BUMP(f) ((f)->flags & FLAG_LENGTH64 ? 1 : 0)
+#define HLINK_BUMP(f) (F_IS_HLINKED(f) ? 1 : 0)
+
+/* Basename (AKA filename) and length applies to all items */
+#define F_BASENAME(f) ((const char*)(f) + FILE_STRUCT_LEN)
+#define F_LENGTH(f) ((OFF_T)(f)->len32 + ((f)->flags & FLAG_LENGTH64 \
+ ? (OFF_T)OPT_EXTRA(f, 0)->unum << 32 : 0u))