[PATCH] D83624: [DWARFYAML] Implement the .debug_rnglists section.
Xing GUO via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 14 03:46:58 PDT 2020
Higuoxing added a comment.
In D83624#2149554 <https://reviews.llvm.org/D83624#2149554>, @jhenderson wrote:
> Couple of other test case suggestions:
>
> 1. What is the value of the AddrSize field by default, if using a 32-bit object.
Added in test case (f).
> 2. An empty list is allowed for a table.
Added in test case (k).
Thanks for reviewing.
================
Comment at: llvm/test/tools/yaml2obj/ELF/DWARF/debug-rnglists.yaml:205-216
+ - Entries:
+ - Operator: DW_RLE_base_addressx
+ Values: [ 0x1234 ]
+ - Operator: DW_RLE_startx_endx
+ Values: [ 0x1234, 0x1234 ]
+ - Operator: DW_RLE_end_of_list
+ - Entries:
----------------
jhenderson wrote:
> Is there a motivation for having so many operators in the DWARF64 case? Could you simplify it down so that there's only end-of-list markers?
It's not really a motivation. I want to test the offsets for multiple entries in the DWARF64 section. Seems that the operators are useless here, I will delete them.
================
Comment at: llvm/test/tools/yaml2obj/ELF/DWARF/debug-rnglists.yaml:274
+
+## f) Test that the offset_entry_count field can be specified manually.
+
----------------
jhenderson wrote:
> Rather than have the fields tested in independent inputs, it's probably safe to test these all in one input which overwrites each of the fields.
They are merged into the test case (e), where the length, version, offset_entry_count and offsets are overwritten.
================
Comment at: llvm/test/tools/yaml2obj/ELF/DWARF/debug-rnglists.yaml:327
+ - Version: 5
+ Offsets: [ 0x12, 0x34 ]
+ Lists:
----------------
jhenderson wrote:
> I'd specify a different number of offsets (perhaps fewer) than the actual number of lists.
See test case (e).
================
Comment at: llvm/test/tools/yaml2obj/ELF/DWARF/debug-rnglists.yaml:417-418
+
+## j) Test that yaml2obj emits an error message if we try to assign an invalid value to
+## 'AddressSize' when there is an entry whose operands contain address.
+
----------------
jhenderson wrote:
> You also need a test showing that an invalid size can be used when there are no operands with addresses.
>
> You might also want multiple copies of case j), testing each of the different address-using operators individually.
> You also need a test showing that an invalid size can be used when there are no operands with addresses.
See test case (i).
> You might also want multiple copies of case j), testing each of the different address-using operators individually.
See test case (h).
================
Comment at: llvm/test/tools/yaml2obj/ELF/DWARF/debug-rnglists.yaml:441-442
+
+## k) Test that yaml2obj emits an error message if we specify invalid numbers of operands
+## to operator.
+
----------------
jhenderson wrote:
> You need to test this for every operator, I think.
>
> The easiest way to do that would be to use -D for the operator kind and values.
> You need to test this for every operator, I think.
See test case (j).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D83624/new/
https://reviews.llvm.org/D83624
More information about the llvm-commits
mailing list