Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tracing to the Host interface #1198

Merged
merged 2 commits into from
Jan 17, 2024
Merged

Add tracing to the Host interface #1198

merged 2 commits into from
Jan 17, 2024

Conversation

Fumuran
Copy link
Contributor

@Fumuran Fumuran commented Jan 15, 2024

This PR:

  • Adds new trace.<trace_id> "decorator" instruction to the assembly
  • Adds new on_trace() method to the Host trait to handle trace instructions

TODO:

  • Update documentation

@Fumuran Fumuran linked an issue Jan 15, 2024 that may be closed by this pull request
@Fumuran Fumuran changed the title Add tracing to the Host interface Add tracing to the Host interface Jan 16, 2024
@Fumuran Fumuran force-pushed the andrew-add-tracing-to-host branch 2 times, most recently from 3c19637 to ddc0874 Compare January 16, 2024 12:22
@Fumuran Fumuran force-pushed the andrew-add-tracing-to-host branch from ddc0874 to 01d8984 Compare January 16, 2024 12:29
@Fumuran Fumuran requested a review from bobbinth January 16, 2024 12:36
@Fumuran
Copy link
Contributor Author

Fumuran commented Jan 16, 2024

I'm not sure where should we place the documentation for the trace instruction. I can create another file and place it near the event doc file, but they'll be very similar. Should we merge them to create something like Emitting file with docs for both trace and event?

@Fumuran Fumuran marked this pull request as ready for review January 16, 2024 12:39
Copy link
Contributor

@bobbinth bobbinth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Thank you! I left a few comments inline.

I'm not sure where should we place the documentation for the trace instruction. I can create another file and place it near the event doc file, but they'll be very similar. Should we merge them to create something like Emitting file with docs for both trace and event?

Yes, but I'd just use the same Events file and create a "Tracing" section in that file.

Also, looking at this now, I wonder if tracing can replace debug instruction. I think we can get all the same info from both - but there are different pros and cons. Let's create an issue for this.

@Fumuran Fumuran force-pushed the andrew-add-tracing-to-host branch from 73ae361 to a24f896 Compare January 17, 2024 13:49
@Fumuran Fumuran requested a review from bobbinth January 17, 2024 14:05
Copy link
Contributor

@bobbinth bobbinth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! Thank you!

@bobbinth bobbinth merged commit a9a1c6a into next Jan 17, 2024
15 checks passed
@bobbinth bobbinth deleted the andrew-add-tracing-to-host branch January 17, 2024 19:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Consider adding tracing to the Host interface
2 participants