HSAIL needs to override this to avoid emission of any of the directives the standard MCAsmStreamer tries to emit, most notably anything indicating the start of a section.
Details
Diff Detail
Event Timeline
To be clear, the idea is to avoid *creating* the sections, no avoiding
printing them, correct?
Ins't all that you need to do is overload (or add an if to) InitSections?
For what it is worth, WebAssembly seems to manage to just use nullptr:
TextSection = nullptr; DataSection = nullptr; BSSSection = nullptr; ReadOnlySection = nullptr;
Yes, although the specific problem is they are printed. We don't have meaningful sections in the text format.
Ins't all that you need to do is overload (or add an if to) InitSections?
Probably, but that would still require a new custom MCAsmStreamer subclass. Essentially all we want out of the MCStreamer is what MCBasicAsmStreamer has in it. Essentially anything other than printing instructions and labels are going to be incorrect.
This was one of the first things I tried and it doesn't work. WebAssembly does current print .text / .data directives.