[llvm-bugs] [Bug 38278] New: llvm-readelf incorrectly reports stackmap version.

via llvm-bugs llvm-bugs at lists.llvm.org
Mon Jul 23 08:03:41 PDT 2018


https://bugs.llvm.org/show_bug.cgi?id=38278

            Bug ID: 38278
           Summary: llvm-readelf incorrectly reports stackmap version.
           Product: new-bugs
           Version: unspecified
          Hardware: PC
                OS: OpenBSD
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: new bugs
          Assignee: unassignedbugs at nondot.org
          Reporter: vext01 at gmail.com
                CC: llvm-bugs at lists.llvm.org

```
$ llvm-readelf -stackmap a.out
LLVM StackMap Version: 2
...
```

But if we look in the binary:
```
$ r2 a.out
[0x00400450]> s section..llvm_stackmaps
[0x00400680]> px 16
- offset -   0 1  2 3  4 5  6 7  8 9  A B  C D  E F  0123456789ABCDEF
0x00400680  0300 0000 0100 0000 0000 0000 0200 0000  ................
```

Byte 0 is the version field in the stackmap header.

2 versus 3.

The docs say 3 is correct:
https://llvm.org/docs/StackMaps.html#stack-map-format

```
$ clang -v
clang version 7.0.0 (trunk 336996) (llvm/trunk 336905)
Target: x86_64-unknown-linux-gnu
```

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20180723/fb37c7cf/attachment.html>


More information about the llvm-bugs mailing list