lkml.org 
[lkml]   [2010]   [Mar]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [RFC PATCH 2/7] perf: add pipe-specific header read/write and event processing code
    Em Sat, Mar 27, 2010 at 07:57:47PM -0300, Arnaldo Carvalho de Melo escreveu:
    > Em Sat, Mar 27, 2010 at 04:14:57AM +0100, Frederic Weisbecker escreveu:
    > > On Wed, Mar 03, 2010 at 01:05:24AM -0600, Tom Zanussi wrote:
    > > >
    > > > +int perf_header__write_pipe(struct perf_header *self, int fd)
    > > > +{
    > > > + struct perf_file_header_pipe f_header;
    > > > + int err;
    > > > +
    > > > + f_header = (struct perf_file_header_pipe){
    > > > + .magic = PERF_MAGIC,
    > > > + .size = sizeof(f_header),
    > > > + };
    >
    > > I actually wonder why you bother with a header in the pipe mode,
    > > since it only contains MAGIC and its size.
    >
    > Because he wants to detect endianness :-)

    Elaborating: piping over netcat from a big endian to a little endian
    machine works because he used the ->needs_swap logic I implemented to
    allow cross platform analysis.

    Its just a matter of having the DSOS with matching build-ids in the
    cache of the machine running 'perf report'.

    - Arnaldo


    \
     
     \ /
      Last update: 2010-03-28 00:07    [W:0.021 / U:31.760 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site