On 04/01/2019 17:48, Zachary Turner wrote:
For those kinds of cases, we could use obj2yaml and check in yaml right? Fwiw I tried to round-trip an exe through obj->yaml->obj recently and the resulting exe was incorrect but it was close, so I think there’s only some small fixes needed.


I agree yaml2obj should be used whenever possible, but here I'm talking specifically about things that cannot be repesented in yaml. For example, you can't get yaml2obj to produce a binary that's truncated in the middle of the section list. Or one whose section contents points back to the section list... And yet it makes sense to test that lldb doesn't crash or do other weird stuff when opening these files. It also probably doesn't make sense to write a special tool for generating these, as there aren't going to be many of these cases, and each of them will be special in some way.
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to