[Mesa-dev] [PATCH 3/4] i965/tiled_memcpy: Add tiled-to-linear paths

Chad Versace chad.versace at intel.com
Mon Jan 5 14:40:52 PST 2015


On 01/03/2015 11:54 AM, Jason Ekstrand wrote:
> From: Sisinty Sasmita Patra <sisinty.patra at intel.com>
> 
> This commit addes tiled copy functions for coping from tiled memory to
> linear memory.  These are very similar to the existing linear-to-tiled
> paths.
> 
> v2: Jason Ekstrand <jason.ekstrand at intel.com>
>    - New commit message
>    - Various whitespace fixes
>    - Added ptrdiff_t casts as done in commit 225a09790
> 
> Signed-off-by: Jason Ekstrand <jason.ekstrand at intel.com>
> ---
>  src/mesa/drivers/dri/i965/intel_tiled_memcpy.c | 265 +++++++++++++++++++++++++
>  src/mesa/drivers/dri/i965/intel_tiled_memcpy.h |   9 +
>  2 files changed, 274 insertions(+)



> +/**
> + * Copy texture data from X tile layout to linear, faster.
> + *
> + * Same as \ref xtile_copy but faster, because it passes constant parameters
                   ^^^^^^^^^^
Function name needs updating.

> + * for common cases, allowing the compiler to inline code optimized for those
> + * cases.
> + *
> + * \copydoc tile_copy_fn
> + */
> +static FLATTEN void
> +xtiled_to_linear_faster(uint32_t x0, uint32_t x1, uint32_t x2, uint32_t x3,
> +                        uint32_t y0, uint32_t y1,
> +                        char *dst, const char *src,
> +                        uint32_t dst_pitch,
> +                        uint32_t swizzle_bit,
> +                        mem_copy_fn mem_copy)


> +/**
> + * Copy texture data from Y tile layout to linear, faster.
> + *
> + * Same as \ref ytile_copy but faster, because it passes constant parameters
                   ^^^^^^^^^^
Again, function name needs updating.

> + * for common cases, allowing the compiler to inline code optimized for those
> + * cases.
> + *
> + * \copydoc tile_copy_fn
> + */
> +static FLATTEN void
> +ytiled_to_linear_faster(uint32_t x0, uint32_t x1, uint32_t x2, uint32_t x3,
> +                        uint32_t y0, uint32_t y1,
> +                        char *dst, const char *src,
> +                        uint32_t dst_pitch,
> +                        uint32_t swizzle_bit,
> +                        mem_copy_fn mem_copy)


With the above comments fixed, patch 3 is
Reviewed-by: Chad Versace <chad.versace at intel.com>


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 884 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20150105/dd16db9a/attachment.sig>


More information about the mesa-dev mailing list