1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-24 11:42:57 +01:00
llvm-mirror/test/tools/obj2yaml
George Rimar 60c8d3580e [yaml2obj][obj2yaml] - Change how symbol's binding is descibed when parsing/dumping.
Currently, YAML has the following syntax for describing the symbols:

Symbols:
  Local:
    LocalSymbol1:
    ...
    LocalSymbol2:
    ...
  ...
  Global:
    GlobalSymbol1:
  ...
  Weak:
  ...
  GNUUnique:

I.e. symbols are grouped by their bindings. That is not very convenient,
because:

It does not allow to set a custom binding, what can be useful for producing
broken/special outputs for test cases. Adding a new binding would require to
change a syntax (what we observed when added GNUUnique recently).

It does not allow to change the order of the symbols in .symtab/.dynsym,
i.e. currently all Local symbols are placed first, then Global, Weak and GNUUnique
are following, but we are not able to change the order.

It is not consistent. Binding is just one of the properties of the symbol,
we do not group them by other properties.

It makes the code more complex that it can be. This patch shows it can be simplified
with the change performed.

The patch changes the syntax to just:

Symbols:
  Symbol1:
  ...
  Symbol2:
  ...
...

With that, we are able to work with the binding field just like with any other symbol property.

Differential revision: https://reviews.llvm.org/D60122

llvm-svn: 357595
2019-04-03 14:53:42 +00:00
..
Inputs [obj2yaml] - Do not miss section index for special symbols. 2019-02-22 08:45:21 +00:00
basic-minidump.yaml Add minidump support to obj2yaml 2019-04-02 11:58:37 +00:00
dynamic-section-arch-tags.test [yaml2obj][obj2yaml] - Add support for the architecture specific dynamic tags. 2019-02-26 14:14:49 +00:00
dynamic-section.test [BinaryFormat] Add DT_USED tag into dynamic section. 2019-03-06 01:28:40 +00:00
elf-entsize.yaml
elf-gnu-unique-symbols.yaml [yaml2obj][obj2yaml] - Change how symbol's binding is descibed when parsing/dumping. 2019-04-03 14:53:42 +00:00
elf-shinfo.yaml [yaml2obj] - Allow setting custom sh_info for RawContentSection sections. 2019-03-01 10:18:16 +00:00
invalid_input_file.test
lit.local.cfg [obj2yaml][yaml2obj]Locate all .yaml and .test tests 2019-02-20 15:13:44 +00:00
missing_symtab.test [yaml2obj][obj2yaml] - Change how symbol's binding is descibed when parsing/dumping. 2019-04-03 14:53:42 +00:00
section-type.yaml [yaml2obj][obj2yaml] Remove section type range markers from allowed mappings and support hex values 2019-02-19 16:22:21 +00:00
special-symbol-indices.yaml [yaml2obj][obj2yaml] - Change how symbol's binding is descibed when parsing/dumping. 2019-04-03 14:53:42 +00:00
symbol-type.yaml [yaml2obj][obj2yaml] - Change how symbol's binding is descibed when parsing/dumping. 2019-04-03 14:53:42 +00:00
verdef-section.yaml [yaml2obj][obj2yaml] - Change how symbol's binding is descibed when parsing/dumping. 2019-04-03 14:53:42 +00:00
verneed-section.yaml [yaml2obj][obj2yaml] - Change how symbol's binding is descibed when parsing/dumping. 2019-04-03 14:53:42 +00:00
versym-section.yaml [yaml2obj][obj2yaml] - Change how symbol's binding is descibed when parsing/dumping. 2019-04-03 14:53:42 +00:00