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

wasm-objdump: Report data segment names #1588

Merged
merged 1 commit into from
Dec 10, 2020
Merged

wasm-objdump: Report data segment names #1588

merged 1 commit into from
Dec 10, 2020

Conversation

sbc100
Copy link
Member

@sbc100 sbc100 commented Dec 9, 2020

Also fix ordering of data names and table segment names.

Comment on lines 673 to 674
LogOpcode(immediate_len, "%d <" PRIstringview ">", value,
WABT_PRINTF_STRING_VIEW_ARG(name));
Copy link
Member

Choose a reason for hiding this comment

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

Looks like value2 is missing here.

Copy link
Member Author

Choose a reason for hiding this comment

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

Good point.
Fixed.

000008d: 656c 656d 31 elem1 ; elem name 0
0000089: 08 ; FIXUP subsection size
000004a: 47 ; FIXUP section size
0000089: warning: out-of-order sub-section
Copy link
Member

Choose a reason for hiding this comment

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

Where did this warning go?

Copy link
Member Author

Choose a reason for hiding this comment

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

The order was wrong in src/binary-writer.cc .. this change has a fix that that. Want me to split it out?

Copy link
Member

Choose a reason for hiding this comment

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

Ah, got it, thanks! Keeping it in seems fine.

@@ -204,10 +208,12 @@ Custom:
- memory[0] <mem2>
- global[0] <g1>
- global[1] <g2>
- elemseg[0] <elem1>
Copy link
Member

Choose a reason for hiding this comment

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

Where does this "elem1" come from?

Copy link
Member Author

Choose a reason for hiding this comment

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

The out of order name section meant is wasn't being displayed here.

Also fix ordering of data names and table segment names.
@sbc100 sbc100 merged commit ed64732 into master Dec 10, 2020
@sbc100 sbc100 deleted the named_segments branch December 10, 2020 06:09
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.

None yet

2 participants