[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: FSFS caching doc strings

From: Stefan Fuhrmann <stefanfuhrmann_at_alice-dsl.de>
Date: Sun, 26 Jun 2011 23:28:44 +0200

On 15.06.2011 10:25, Julian Foad wrote:
> Stefan2, I'm posting this attempt to add more detail to some of the FSFS
> caching doc strings. It's incomplete but I've had this sitting in my WC
> for a couple of weeks now and am unlikely to look deeper in the short
> term.
Thanks for the suggestions!
> [[[
> Index: subversion/libsvn_fs_fs/fs.h
> ===================================================================
> --- subversion/libsvn_fs_fs/fs.h (revision 1135952)
> +++ subversion/libsvn_fs_fs/fs.h (working copy)
> @@ -238,8 +238,12 @@ typedef struct fs_fs_data_t
> rep key to svn_string_t. */
> svn_cache__t *fulltext_cache;
>
> - /* Pack manifest cache; maps revision numbers to offsets in their respective
> - pack files. */
> + /* Pack manifest cache; a cache mapping (svn_revnum_t) shard number to
> + a manifest; and a manifest is a mapping from (svn_revnum_t) revision
> + number offset within a shard to (apr_off_t) byte-offset in the
> + respective pack file.
> + ### Is this right?
Spot on.
> + */
> svn_cache__t *packed_offset_cache;
>
> /* Cache for txdelta_window_t objects; the key is (revFilePath, offset) */
> Index: subversion/libsvn_fs_fs/temp_serializer.h
> ===================================================================
> --- subversion/libsvn_fs_fs/temp_serializer.h (revision 1135952)
> +++ subversion/libsvn_fs_fs/temp_serializer.h (working copy)
> @@ -93,8 +93,8 @@ svn_fs_fs__deserialize_txdelta_window(vo
> apr_pool_t *pool);
>
> /**
> - * Implements #svn_cache__serialize_func_t for manifests
> - * (#apr_array_header_t).
> + * Implements #svn_cache__serialize_func_t for a manifest
> + * (@a in is an #apr_array_header_t of apr_off_t elements).
> */
> svn_error_t *
> svn_fs_fs__serialize_manifest(char **data,
> @@ -103,8 +103,8 @@ svn_fs_fs__serialize_manifest(char **dat
> apr_pool_t *pool);
>
> /**
> - * Implements #svn_cache__deserialize_func_t for manifests
> - * (#apr_array_header_t).
> + * Implements #svn_cache__deserialize_func_t for a manifest
> + * (@a *out is an #apr_array_header_t of apr_off_t elements).
> */
> svn_error_t *
> svn_fs_fs__deserialize_manifest(void **out,
> @@ -167,8 +167,13 @@ svn_fs_fs__deserialize_dir_entries(void
> apr_pool_t *pool);
>
> /**
> - * Implements #svn_cache__partial_getter_func_t for a single element
> - * identified by its offset in @a baton within a serialized manifest array.
> + * Implements #svn_cache__partial_getter_func_t.
> + * Set @a *out to the (apr_off_t) byte-offset within a pack file of the
> + * revision
> + * Set (apr_off_t) @a *out to the element
> + * indexed by (apr_int64_t) @a *baton within the serialized manifest array
> + * @a data and @a data_len.
> + * ### Caller thinks *out is apr_off_t; impl thinks it is apr_int64_t.
> */
Fixed in r1139945.
> svn_error_t *
> svn_fs_fs__get_sharded_offset(void **out,
> @@ -180,7 +185,7 @@ svn_fs_fs__get_sharded_offset(void **out
> /**
> * Implements #svn_cache__partial_getter_func_t for a single
> * #svn_fs_dirent_t within a serialized directory contents hash,
> - * identified by its name in @a baton.
> + * identified by its name (const char @a *baton).
> */
> svn_error_t *
> svn_fs_fs__extract_dir_entry(void **out,
> ]]]
>
> - Julian
Docstring changes committed as r1139946.

-- Stefan^2.
Received on 2011-06-27 08:54:13 CEST

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.