From 1c4d51e96077798bf6bd0dfa82f65259a07bd314 Mon Sep 17 00:00:00 2001 From: Sam Clegg Date: Tue, 17 Oct 2017 12:24:27 -0700 Subject: wasm-objdump: Add support for data segment info (#656) --- src/binary-reader-logging.cc | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'src/binary-reader-logging.cc') diff --git a/src/binary-reader-logging.cc b/src/binary-reader-logging.cc index b167e63d..ff169c17 100644 --- a/src/binary-reader-logging.cc +++ b/src/binary-reader-logging.cc @@ -437,6 +437,16 @@ Result BinaryReaderLogging::OnSymbolInfo(string_view name, uint32_t flags) { return reader_->OnSymbolInfo(name, flags); } +Result BinaryReaderLogging::OnSegmentInfo(Index index, + string_view name, + uint32_t alignment, + uint32_t flags) { + LOGF("(OnSegmentInfo %d name: " PRIstringview + ", alignment: %d, flags: 0x%x)\n", + index, WABT_PRINTF_STRING_VIEW_ARG(name), alignment, flags); + return reader_->OnSegmentInfo(index, name, alignment, flags); +} + #define DEFINE_BEGIN(name) \ Result BinaryReaderLogging::name(Offset size) { \ LOGF(#name "(%" PRIzd ")\n", size); \ @@ -603,6 +613,7 @@ DEFINE_INDEX(OnSymbolInfoCount) DEFINE_INDEX(OnStackGlobal) DEFINE_INDEX(OnDataSize) DEFINE_INDEX(OnDataAlignment) +DEFINE_INDEX(OnSegmentInfoCount) DEFINE_END(EndLinkingSection) DEFINE_BEGIN(BeginExceptionSection); -- cgit v1.2.3