Re: Fw: call HPAK() in root

From: Piotr Adam Zolnierczuk (zolnie@pa.uky.edu)
Date: Thu Dec 02 1999 - 05:00:24 MET


Hi Rene,

How about SetContent(Stat_t *content)?

I believe it does exactly what you

wrote - it does execute a loop.



I belive, that for performance reasons, it is

important to have a 'hpak' equivalent -

it is much faster (and cheaper) to execute

memcpy(....) than a loop.

However in these days of cheap CPU power ...

it is probably an academic dispute

                Cheers

                            Piotr

Rene Brun wrote:

> Hi Jan,
> There is no equivalent og Hpak, simply because I do not want
> to implement this function for all possible data types.
> It is so simple and trivial to replace your loop by:
> h1=new TH1F("Test", 100, -5., 5.);
> for (int i=0;i<100;i++) h1->SetBinContent(i,i*i);
>
> Rene Brun
>


 ________________________________________________________________
 Piotr Adam Zolnierczuk
 Dept. of Physics and Astronomy   http://www.pa.uky.edu/~zolnie
 University of Kentucky           phone:  (606) 257-5565
 Lexington, KY 40506, USA         fax:    (606) 323-2846
 ________________________________________________________________
                   written on recycled electrons



This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:43:43 MET