On Tue, Aug 18, 2009 at 11:51 AM, Pauli Nieminen<suok...@gmail.com> wrote:
> Using this call in OUT_BATCH_TABLE reduces radeonEmitState cpu usage from
> 9% to 5% and emit_vpu goes from 7% to 1.5%. I did use calgrind to profile
> gears for cpu hotspots with r500 card.
>
> Signed-off-by: Pauli Nieminen <suok...@gmail.com>

Acked-by: Alex Deucher <alexdeuc...@gmail.com>

> ---
>  libdrm/radeon/radeon_cs.h |    9 +++++++++
>  1 files changed, 9 insertions(+), 0 deletions(-)
>
> diff --git a/libdrm/radeon/radeon_cs.h b/libdrm/radeon/radeon_cs.h
> index 7efec7e..1117a85 100644
> --- a/libdrm/radeon/radeon_cs.h
> +++ b/libdrm/radeon/radeon_cs.h
> @@ -201,6 +201,15 @@ static inline void radeon_cs_write_qword(struct 
> radeon_cs *cs, uint64_t qword)
>     }
>  }
>
> +static inline void radeon_cs_write_table(struct radeon_cs *cs, void *data, 
> uint32_t size)
> +{
> +       memcpy(cs->packets + cs->cdw, data, size * 4);
> +       cs->cdw += size;
> +       if (cs->section) {
> +               cs->section_cdw += size;
> +       }
> +}
> +
>  static inline void radeon_cs_space_set_flush(struct radeon_cs *cs, void 
> (*fn)(void *), void *data)
>  {
>     cs->space_flush_fn = fn;
> --
> 1.6.0.4
>
>
> ------------------------------------------------------------------------------
> Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
> trial. Simplify your report design, integration and deployment - and focus on
> what you do best, core application coding. Discover what's new with
> Crystal Reports now.  http://p.sf.net/sfu/bobj-july
> --
> _______________________________________________
> Dri-devel mailing list
> Dri-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/dri-devel
>

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
--
_______________________________________________
Dri-devel mailing list
Dri-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dri-devel

Reply via email to