GSoC Project | Basic Support for Trace Compass
Sebastian Huber
sebastian.huber at embedded-brains.de
Mon Jun 24 07:44:04 UTC 2019
On 24/06/2019 09:28, Ravindra Kumar Meena wrote:
>
>
> On Mon, Jun 24, 2019 at 12:06 PM Sebastian Huber
> <sebastian.huber at embedded-brains.de
> <mailto:sebastian.huber at embedded-brains.de>> wrote:
>
> On 24/06/2019 08:24, Ravindra Kumar Meena wrote:
> > *Plan of the week:*
> > Last I was able to store the event stream in the disk. Now, I
> plan to
> > convert the native stream into CTF format. Once the conversion is
> done
> > then I will make the metadata for the converted CTF format.
>
> The metadata is an essential part of CTF, so you cannot to this after a
> conversion. The metadata must describe your event stream. Please read
> the CTF specification again:
>
> https://diamon.org/ctf/
>
> All what you need to know about the metadata is described in this
> specification in detail. You should be able to write the metadata
> for an
> event stream consisting of struct ctf_event items until this Wednesday
> so that babeltrace can read it.
>
>
> Okay. I have figured out something very important.
>
> Babeltrace reads trace files only when the event stream file have ctf
> magic number(0xc1fc1fc1) and stream id(0000 0000 0000 0000 0000 0000).
>
> The stream data we are generating does not have these. I manually added
> these values in the stream file. Babeltrace was reading the trace stream.
>
> This reduced the babeltrace error from
>
> [error] Invalid magic number 0x30302E30 at packet 0 (file offset 0).
> [error] Stream index creation error.
> [error] Open file stream error.
> [warning] [Context] Cannot open_trace of format ctf at path ctf.
> [warning] [Context] cannot open trace "ctf" from ctf/ for reading.
> [error] Cannot open any trace for reading.
> [error] opening trace "ctf/" for reading.
> [error] none of the specified trace paths could be opened.
>
> to
>
> [warning] Unknown value 155263 in enum.
> 0 RTEMS_RECORDING_EVENT: { ns = 0, cpu = 0, events = ( <unknown> :
> container = 155263 ), data = 0 }
> [error] Event id 216 is outside range.
> [error] Reading event failed.
> Error printing trace.
>
> As you can see magic number and many others error are reduced. This
> proves that we have to add ctf magic number(0xc1fc1fc1) and stream
> id(0000 0000 0000 0000 0000 0000) in the generated stream file.
Your metadata in "misc/ctf/metadata" has little to do with the event
stream created by the record-client program. For example you don't write
a packet header before the events. I would not try to solve these issues
with trial and error. You really have to know how CTF works. So, please
read the CTF specification again.
--
Sebastian Huber, embedded brains GmbH
Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone : +49 89 189 47 41-16
Fax : +49 89 189 47 41-09
E-Mail : sebastian.huber at embedded-brains.de
PGP : Public key available on request.
Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.
More information about the devel
mailing list