This is a split patch of D115862 which adds a --bits-endian option to
extract-section to make it possible to print bits in specified endianness.
It means that we can print instruction encoding of some targets like LoongArch
as bits[0] to bits[31] from right to left by specifing --bits-endian little.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Unit Tests
Time | Test | |
---|---|---|
80 ms | x64 debian > LLVM.Bindings/Go::go.test |
Event Timeline
llvm/utils/extract-section.py | ||
---|---|---|
64 | Fixed grammar and punctuation: Print out bits in specified endianness (little or big); defaults to big | |
72 | This probably should be bits_endian to agree with the addition above; while looking at the surrounding it seems tool_path should be readobj_path too. I'm not entirely sure though. | |
88–90 | While we're at it, add a space after every comma for general PEP8 cleanness? |
Reply to @xen0n
llvm/utils/extract-section.py | ||
---|---|---|
64 | No problem. I will change that. Thanks. | |
72 | OK, I will rename endian to bits_endian. Thanks. | |
88–90 | Good suggestion. But seems that LLVM doesn't define a coding standard for python in https://llvm.org/docs/CodingStandards.html |
My comments are all addressed, but I'm not too familiar with this piece of code, so would anyone else please take a look at this too?
LGTM.
Actually you can break the dependency with other patches in this series since this one is self-contained. But it's up to you.
Thanks @myhsu. You're right and I have removed the dependency with other patches but keep the dependency with it's child patch (D115862).
Hi @rengolin, could we land this patch now since author of the modified file has accepted the change or we should wait other patches to be accepted and land together?
BTW, I don't have commit access yet, please help to commit the change if possible.
Sure, no problems. Let's just land all patches at once, in order, after they're all approved.
Hi @rengolin. Now all the 6 initial patches are approved and could you help to commit them? Thanks.
Fixed grammar and punctuation: Print out bits in specified endianness (little or big); defaults to big