[PATCH] D70757: [ms] Add @feat.00 magic symbol to COFF object files from AsmParser

Reid Kleckner via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 2 13:15:10 PST 2019


rnk added a comment.

In D70757#1762398 <https://reviews.llvm.org/D70757#1762398>, @epastor wrote:

> Thanks, Reid! So to clarify: our standards for this are to match nasm for the current interface?


No, LLVM MC is modeled after GNU binutils as. It's not strictly compatible, since we had to extend the `.section` directive for COFF to express certain extensions, but binutils is usually the first place we look for prior art. Nasm is just a good second place to look for how other assemblers handle common issues.

> As for roundtripping... I'll have to check, but it seems likely to be a problem. If necessary, I'll withdraw this and leave it to be managed by whatever interface ends up used to emulate MASM. (ml.exe and ml64.exe both emit @feat.00 implicitly into their symbol tables, with ml.exe setting the LSB if /safeseh is passed.)

In the spirit of following gnu as when possible, I think it would be better to make this conditional on some kind of masm mode setting.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D70757/new/

https://reviews.llvm.org/D70757





More information about the llvm-commits mailing list