Skip to content

trace output should include component names from topology #508

Closed

Description

@lgirdwood

Currently trace output only contains the component type but not the component name used by topology. This could make trace confusing if a pipeline had multiple components of the same type or multiple pipelines were running simultaneously.
e.g.

0      2     HOST  56308262.447917         2.395833               host.c:650        cpy
0      2     HOST  56308265.312500         2.864583            hda-dma.c:229        GwU
0      2     HOST  56308268.802083         3.489583               host.c:145        irq
0      2   BUFFER  56308272.291667         3.489583             buffer.c:145        pro
0      2  unknown  56308274.843750         2.552083             buffer.c:146        value 25165824
0      2  unknown  56308277.291667         2.447917             buffer.c:147        value 131456
0      2  unknown  56308279.635417         2.343750             buffer.c:148        value 12583104
0      2    POWER  56308282.552083         2.916667         pm_runtime.c:78         put
0      2     PIPE  56308317.135417        34.583332           pipeline.c:914        CD+
0      2   VOLUME  56308319.739583         2.604167             volume.c:445        cpy
0      2   BUFFER  56308350.781250        31.041666             buffer.c:145        pro
0      2  unknown  56308353.281250         2.500000             buffer.c:146        value 50331648
0      2  unknown  56308355.729167         2.447917             buffer.c:147        value 197376
0      2  unknown  56308358.072917         2.343750             buffer.c:148   

Output should also contain topology name e.g. "BUFFER 1.1" in the above output.

Activity

  1. bkokoszx commented on Oct 30, 2018

    @bkokoszx
    Collaborator

    @lgirdwood What do you mean by topology name? Do you think about pipeline_id.component_id?
    Does it not be sufficient if we only print component_id as it is unique?

  2. lgirdwood commented on Oct 30, 2018

    @lgirdwood
    MemberAuthor

    @bkokoszx the topology name for a component or pipeline (they should all be unique). So yes, we will need pipeline->id and component->id for components, pipeline->id for pipelines and also dai->id for SSP, HDA etc.

    The intention is to be able to globally identify any part of the trace against topology.

  3. akloniex commented on Oct 31, 2018

    @akloniex
    Member

    @lgirdwood I don't see an easy way to automate collection of these IDs, and it would be tedious to pass IDs to each and every trace_event macro. And adding separate macro that also accepts IDs will miss the point, as it is suboptimal. Do you have any idea how to implement this feature user-friendly?

  4. lgirdwood commented on Oct 31, 2018

    @lgirdwood
    MemberAuthor

    @akloniex Add pipeline and comp ID fields to the data format then make sure all the trace macros accept these 2 IDs. If a trace user has no IDs then we can just set them as 0s.

    logger will then take the pipeline ID and comp ID and then sprintf() it with component type.

  5. akloniex commented on Nov 7, 2018

    @akloniex
    Member

    FW part done with merged PR #530

  6. bkokoszx commented on Nov 22, 2018

    @bkokoszx
    Collaborator

    Logger part was made here: thesofproject/soft#118
    I think we can close this issue/enhancement.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions