i#7470: Fix order of unreading split trace entries#7469
Merged
abhinav92003 merged 8 commits intomasterfrom Apr 29, 2025
Merged
Conversation
Fixes the order in which split trace entries such as TRACE_MARKER_TYPE_SPLIT_VALUE are unread in unread_last_entry. TRACE_MARKER_TYPE_SPLIT_VALUE must be at the front of the pre_read so that it is returned _before_ the actual marker, in the same order it is read from the raw trace.
derekbruening
approved these changes
Apr 29, 2025
derekbruening
pushed a commit
that referenced
this pull request
May 13, 2025
Fixes the order in which split trace entries such as TRACE_MARKER_TYPE_SPLIT_VALUE are unread in unread_last_entry. TRACE_MARKER_TYPE_SPLIT_VALUE must be at the front of the pre_read deque so that it is returned _before_ the actual marker, in the same order it is read from the raw trace. Adds a raw2trace_unit_test that fails with "SPLIT_VALUE marker is not adjacent to 2nd entry" due to the previously incorrect order of the split_value marker wrt the actual marker in the deque. The error was demonstrated using a large enough kernel_event marker value. This was not seen on a real trace probably because kernel_event marker values do not need the additional marker usually. There is an additional bug where raw2trace does not fully take into account the fact that some markers may be preceded by the TRACE_MARKER_TYPE_SPLIT_VALUE marker. Added a TODO for now. Issue: #7470
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes the order in which split trace entries such as TRACE_MARKER_TYPE_SPLIT_VALUE are unread in unread_last_entry. TRACE_MARKER_TYPE_SPLIT_VALUE must be at the front of the pre_read deque so that it is returned before the actual marker, in the same order it is read from the raw trace.
Adds a raw2trace_unit_test that fails with "SPLIT_VALUE marker is not adjacent to 2nd entry" due to the previously incorrect order of the split_value marker wrt the actual marker in the deque. The error was demonstrated using a large enough kernel_event marker value. This was not seen on a real trace probably because kernel_event marker values do not need the additional marker usually.
There is an additional bug where raw2trace does not fully take into account the fact that some markers may be preceded by the TRACE_MARKER_TYPE_SPLIT_VALUE marker. Added a TODO for now.
Issue: #7470