[PATCH] D28041: IR: Module summary representation for type identifiers; summary test scaffolding for lowertypetests.

Peter Collingbourne via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Dec 22 10:08:00 PST 2016


pcc added a comment.

In https://reviews.llvm.org/D28041#629749, @tejohnson wrote:

> In https://reviews.llvm.org/D28041#629442, @mehdi_amini wrote:
>
> > I don't have any strong feeling against YAML, but we should take this decision for the full summary and not just for the "type test", so I'd like to hear from Teresa about that (in the past we were considering a LLVM "metadata" serialization instead, or similar, so that it can round-trip in the IR itself).
>
>
> It would be optimal to have a serialization in the LLVM assembly format (I started to look into doing that some time ago but got side tracked - I was thinking not as metadata since we don't carry it internally as metadata, but a new format e.g. similar to the way attributes are emitted as a separate format not metadata). Rather than taking the trouble to emit as YAML, why not emit into the LLVM assembly from the start?


It's far from clear to me that in assembly is the right way to go. It might be for the individual summaries but not necessarily for the combined summary as it isn't really a property of any specific module.

Given that, and also given that this format is for debugging/testing purposes only, we might as well do the easiest thing we can while still making our tests readable. For me that meant leveraging the existing YAML support in LLVM. If we ultimately decide that some other format is better, I would imagine that converting the tests to the new format would be easier if we start from YAML rather than bcanalyzer output.


https://reviews.llvm.org/D28041





More information about the llvm-commits mailing list