SuccessChanges

Summary

  1. [MC] [Win64EH] Fill in FuncletOrFuncEnd if missing (details)
  2. [AArch64] Generate and parse SEH assembly directives (details)
  3. [InstCombine] Return replaceInstUsesWith() result (NFC) (details)
Commit 20f7773bb4bb458c3f3b4e46d1601465e6479746 by martin
[MC] [Win64EH] Fill in FuncletOrFuncEnd if missing

This can happen e.g. for code that declare .seh_proc/.seh_endproc
in assembly, or for code that use .seh_handlerdata (which triggers
the unwind info to be emitted before the end of the function).

The TextSection field must be made non-const to be able to use it
with Streamer.SwitchSection().

Differential Revision: https://reviews.llvm.org/D86528
The file was modifiedllvm/test/MC/AArch64/seh.s (diff)
The file was modifiedllvm/lib/MC/MCStreamer.cpp (diff)
The file was modifiedllvm/include/llvm/MC/MCWinEH.h (diff)
The file was modifiedllvm/lib/MC/MCWin64EH.cpp (diff)
Commit 5b86d130e2baed7221b09087c506f5974fe65f22 by martin
[AArch64] Generate and parse SEH assembly directives

This ensures that you get the same output regardless if generating
code directly to an object file or if generating assembly and
assembling that.

Add implementations of the EmitARM64WinCFI*() methods in
AArch64TargetAsmStreamer, and fill in one blank in MCAsmStreamer.

Add corresponding directive handlers in AArch64AsmParser and
COFFAsmParser.

Some SEH directive names have been picked to match the prior art
for SEH assembly directives for x86_64, e.g. the spelling of
".seh_startepilogue" matching the preexisting ".seh_endprologue".

For the directives for saving registers, the exact spelling
from the arm64 documentation is picked, e.g. ".seh_save_reg" (to follow
that naming for all the other ones, e.g. ".seh_save_fregp_x"), while
the corresponding one for x86_64 is plain ".seh_savereg" without the
second underscore.

Directives in the epilogues have the same names as in prologues,
e.g. .seh_savereg, even though the registers are restored, not
saved, at that point.

Differential Revision: https://reviews.llvm.org/D86529
The file was modifiedllvm/lib/Target/AArch64/AsmParser/AArch64AsmParser.cpp (diff)
The file was modifiedllvm/test/CodeGen/AArch64/arm64-windows-calls.ll (diff)
The file was modifiedllvm/test/CodeGen/AArch64/powi-windows.ll (diff)
The file was modifiedllvm/test/CodeGen/AArch64/win_cst_pool.ll (diff)
The file was modifiedllvm/test/CodeGen/AArch64/seh_funclet_x1.ll (diff)
The file was modifiedllvm/test/MC/AArch64/seh.s (diff)
The file was modifiedllvm/test/CodeGen/AArch64/lround-conv-win.ll (diff)
The file was modifiedllvm/lib/MC/MCParser/COFFAsmParser.cpp (diff)
The file was modifiedllvm/test/CodeGen/AArch64/wineh-try-catch-nobase.ll (diff)
The file was modifiedllvm/lib/MC/MCAsmStreamer.cpp (diff)
The file was modifiedllvm/test/CodeGen/AArch64/lrint-conv-win.ll (diff)
The file was modifiedllvm/test/CodeGen/AArch64/wineh-try-catch-cbz.ll (diff)
The file was modifiedllvm/test/CodeGen/AArch64/wineh1.mir (diff)
The file was modifiedllvm/test/CodeGen/AArch64/win64-jumptable.ll (diff)
The file was modifiedllvm/test/CodeGen/AArch64/lrint-conv-fp16-win.ll (diff)
The file was modifiedllvm/test/CodeGen/AArch64/wineh-try-catch-realign.ll (diff)
The file was modifiedllvm/test/CodeGen/AArch64/wineh-try-catch-vla.ll (diff)
The file was modifiedllvm/lib/Target/AArch64/MCTargetDesc/AArch64ELFStreamer.cpp (diff)
The file was modifiedllvm/test/CodeGen/AArch64/windows-extern-weak.ll (diff)
The file was modifiedllvm/test/CodeGen/AArch64/lround-conv-fp16-win.ll (diff)
Commit 6093b14c2c1fc785bfb7040ecebfe4127e1ab9ab by nikita.ppv
[InstCombine] Return replaceInstUsesWith() result (NFC)

Follow the usual usage pattern for this function and return the
result.
The file was modifiedllvm/lib/Transforms/InstCombine/InstCombinePHI.cpp (diff)
The file was modifiedllvm/lib/Transforms/InstCombine/InstCombineVectorOps.cpp (diff)