This is an archive of the discontinued LLVM Phabricator instance.

Emit code16 in assembly in 16-bit mode
ClosedPublic

Authored by niravd on Apr 21 2016, 2:44 PM.

Details

Summary

When generating assembly using -m16 we must explicitly mark it as
16-bit. Emit .code16 at beginning of file. Fixes wrong results when
using -fno-integrated-as.

Diff Detail

Repository
rL LLVM

Event Timeline

niravd updated this revision to Diff 54584.Apr 21 2016, 2:44 PM
niravd retitled this revision from to Emit code16 in assembly in 16-bit mode.
niravd added a reviewer: dwmw2.
niravd updated this object.
niravd added a subscriber: llvm-commits.
dwmw2 accepted this revision.Apr 21 2016, 3:00 PM
dwmw2 edited edge metadata.

LGTM. Thanks.

This revision is now accepted and ready to land.Apr 21 2016, 3:00 PM

I didn't think we supported code16 compilation (only assembly). This appears to be the very first CodeGen test mentioning the triple and there's basically no reference to it in the actual X86 code.

Tim.

This revision was automatically updated to reflect the committed changes.