mirror of
https://github.com/llvm/llvm-project.git
synced 2025-04-27 17:26:06 +00:00

Summary: FileEntry.Dir can be empty if debug info only contains relative path. This caused an assertion failure when gsym segmentation is trying to copy a file entry with empty dir. As the fitst entry of StringTable is always empty (and is preserved), `StringOffsetMap` doesn't have key 0. Hence, `find(0)` returns `End` and `operator->()` fails the assertion Test Plan: ./bin/llvm-lit -sv llvm/test/tools/llvm-gsymutil/X86/elf-empty-dir.yaml