Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [tracecompass-dev] Beginner's (to a point) help needed.
  • From: Bernd Hufmann <bernd.hufmann@xxxxxxxxxxxx>
  • Date: Tue, 7 Jun 2022 13:21:40 +0000
  • Accept-language: en-CA, en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=ericsson.com; dmarc=pass action=none header.from=ericsson.com; dkim=pass header.d=ericsson.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=t0lesHGmp/eNUdmfU6Fe/SsNV1873YuIiF8ZpR9Tg40=; b=DUEoltfTDtjIUhnBSSaxeKXzC6BI/srkmxWfIsurSmqDtZFLUPxUGUFzS29Ca13z+s0xZKCUGYnB8eP2BrUdoUTnoUDGhyeopmn0sPwTYfk4ndxmwPc0XJOBg9AkiD3audj5JmmsFDPsZo1zRmWmEFqPTBZEY59Xq7XPQtTdcgUJVYjWUrmO28ohaJNrsyIf8UJjJeeBFfK61tnf6915hhkTBTGwNsw5DhU4QjK3BsPVTUkRgOf855LPknSU2/4BB8ytlwjVwVVIpuE3tezKUySw3nQftwy1LUwhiOAHVYPgi1WT788IbCnfqrYTzpBomFxioYH9iv7RfwY2IgvsGQ==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Ko5k084v9lB1nGWs5kJmSO1dQK7BlCFLa5ZlzjLX464XhYWmeSmBZbHsXiOtJu6WrDuWfwMmptk3ZEECF/9gVBXLXferlVRQiSpoUNXkdcIUzs+x+e5BY5WcpZL/YtrLaIEwOlYrFMB/R+oXffN0m+IHiiDnqNwwBNgYeE+K6hm73KBulNobKTt6pDh8b2wBNDdjFEJCEt/qHZIDIIDuSjLirSEuJzyDjP7uajm4EdOkTMaUaIwH9OjqFuF97TlpFzBbXblwYDs9YPWbdAjpfHwCNuWbzMH87237gcPxML2375Wr4eG4s/DK9QwSMmcIXQdL4/ZFK2+fYuDK6CGH5w==
  • Delivered-to: tracecompass-dev@xxxxxxxxxxx
  • List-archive: <https://www.eclipse.org/mailman/private/tracecompass-dev/>
  • List-help: <mailto:tracecompass-dev-request@eclipse.org?subject=help>
  • List-subscribe: <https://www.eclipse.org/mailman/listinfo/tracecompass-dev>, <mailto:tracecompass-dev-request@eclipse.org?subject=subscribe>
  • List-unsubscribe: <https://www.eclipse.org/mailman/options/tracecompass-dev>, <mailto:tracecompass-dev-request@eclipse.org?subject=unsubscribe>
  • Suggested_attachment_session_id: 014198b5-2418-5211-8036-157b148e90b7
  • Thread-index: AQHYbhnwf0u1PLj3c0K+lhVlmYg81K03cWhIgAAR/4CADHihWQ==
  • Thread-topic: [tracecompass-dev] Beginner's (to a point) help needed.

Hi Harvey,

Thanks for sending the error log. The following exception logged in the error log points to an issue with the input CTF binary:

!ENTRY org.eclipse.tracecompass.tmf.ctf.core 4 0 2022-05-24 12:39:31.012
!MESSAGE Cannot create packet entry at bit 0
!STACK 0
org.eclipse.tracecompass.ctf.core.CTFException: Cannot create packet entry at bit 0
at org.eclipse.tracecompass.ctf.core.trace.CTFStreamInput.createPacketIndexEntry(CTFStreamInput.java:277)
at org.eclipse.tracecompass.ctf.core.trace.CTFStreamInput.addPacketHeaderIndex(CTFStreamInput.java:237)
at org.eclipse.tracecompass.ctf.core.trace.CTFStreamInputReader.<init>(CTFStreamInputReader.java:118)
at org.eclipse.tracecompass.ctf.core.trace.CTFTraceReader.createStreamInputReaders(CTFTraceReader.java:219)
at org.eclipse.tracecompass.ctf.core.trace.CTFTraceReader.<init>(CTFTraceReader.java:106)
at org.eclipse.tracecompass.internal.tmf.ctf.core.trace.iterator.CtfIterator.<init>(CtfIterator.java:78)
at org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace.createIterator(CtfTmfTrace.java:704)
at org.eclipse.tracecompass.internal.tmf.ctf.core.trace.iterator.CtfIteratorManager.getIterator(CtfIteratorManager.java:108)
at org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace.createIteratorFromContext(CtfTmfTrace.java:739)
at org.eclipse.tracecompass.tmf.ctf.core.context.CtfTmfContext.getIterator(CtfTmfContext.java:205)
at org.eclipse.tracecompass.tmf.ctf.core.context.CtfTmfContext.getCurrentEvent(CtfTmfContext.java:127)
at org.eclipse.tracecompass.tmf.ctf.core.trace.CtfTmfTrace.initTrace(CtfTmfTrace.java:232)
at org.eclipse.tracecompass.tmf.core.trace.TmfTrace.initTrace(TmfTrace.java:227)
at org.eclipse.tracecompass.tmf.ui.project.model.TmfOpenTraceHelper.openTraceElement(TmfOpenTraceHelper.java:294)
at org.eclipse.tracecompass.tmf.ui.project.model.TmfOpenTraceHelper.openProjectElement(TmfOpenTraceHelper.java:353)
at org.eclipse.tracecompass.tmf.ui.project.model.TmfOpenTraceHelper$OpenProjectElementJob.run(TmfOpenTraceHelper.java:478)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)
Caused by: org.eclipse.tracecompass.ctf.core.CTFException: Content size (80384) > packet size (0)
at org.eclipse.tracecompass.ctf.core.trace.CTFStreamInput.createPacketIndexEntry(CTFStreamInput.java:267)
... 16 more

The exception is thrown at CTFStreamInput.java:267 when the content size is bigger than the packet size. In your case, the error message states: "Content size (80384) > packet size (0)"

At this point I suspect that there is an error in the generated CTF trace. Please make sure that the input trace is correct. You could run Trace Compass in the development environment and debug the source code, which can help you to find the culprit. If you have an open source trace example that you allowed to share, we can help with debugging.

Unrelated, to your comment:
>The init routine writes the main header and packet context, then writes one event packet per event.  The ARM processor is single core.

It is more efficient for the trace and parser to have put more than one event into a packet, because of the packet header overhead.

Best Regards
Bernd



From: tracecompass-dev <tracecompass-dev-bounces@xxxxxxxxxxx> on behalf of Harvey white <madyn@xxxxxxxxxxxxxxxx>
Sent: May 30, 2022 10:16 AM
To: Bernd Hufmann via tracecompass-dev <tracecompass-dev@xxxxxxxxxxx>
Subject: Re: [tracecompass-dev] Beginner's (to a point) help needed.
 

Replies interleaved, thanks:

On 5/30/2022 9:19 AM, Bernd Hufmann via tracecompass-dev wrote:
Hi Harvey,

thanks for the interest in Trace Compass.
I was happy to find it, if I can get it to work, I'll save myself some time.  I rather refused to pay some 3000 USD for a license to percepio.  If I can get this to work, I'll write up something for you on how to add tracecompass to an ARM project, more on a step by step (including the FreeRTOS part, not obvious), and why.

I was browsing the code to understand when this error message is created. I noticed that there might be some errors logged into the Error Log when getting an CTFIterator that will hopefully give us some more information about the root cause of the issue. Could you please provide the error log? It can be found in the Trace Compass workspace under ".metadata/.log". The Trace Compass workspace is, when running the Trace Compass stand-alone RCP by default, "$user.home/.tracecompass", which results in:

$user.home/.tracecompass/.metadata/.log

I've attached a zip of the error log.  I'd been trying various things, and have accumulated a list of error messages.  What I don't see (and I'm not sure why) is that in the import process, I'm not getting data copied, or links put in, so it seems.

The error message itself, while informative to the developers, does seem to be a trifle opaque to others (eg: me....). 

Thanks,

Harvey


Best Regards
Bernd


From: tracecompass-dev <tracecompass-dev-bounces@xxxxxxxxxxx> on behalf of Harvey white <madyn@xxxxxxxxxxxxxxxx>
Sent: May 22, 2022 4:23 PM
To: TraceCompass Development <tracecompass-dev@xxxxxxxxxxx>
Subject: [tracecompass-dev] Beginner's (to a point) help needed.
 
ARM processor running FreeRTOS.

I have the trace hooks worked out.  And that calls a specific routine to
generate a trace packet.

I did have it working for task_switched_in and task_switched_out.

Something broke.

The init routine writes the main header and packet context, then writes
one event packet per event.  The ARM processor is single core.

I get the usual error (I suppose): error initializing trace. "Failed to
get CTF Iterator for path (path)"  The path exists, the file is there.

I've searched for a set of error messages with causes, haven't found them.

I've gotten the same error regardless of a number of changes.  To me,
the error message says "file does not exist", which may really mean
"file can't be parsed".  The metadata file seems fine, doesn't generate
any error messages.

So something is wrong, but I'm not sure what, and at this point, don't
know how to find out what.  The binary file output seems correct to me. 
(maybe obviously not).

Processor dumps binary trace data to a 1 mbyte buffer (QSPI RAM), then
that's sent to a file by using the eclipse memory manager. File looks
good.  metadata looks good.

Assistance, please.


Harvey


_______________________________________________
tracecompass-dev mailing list
tracecompass-dev@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/tracecompass-dev

_______________________________________________
tracecompass-dev mailing list
tracecompass-dev@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/tracecompass-dev

Back to the top