[RISCV] Use OS-specific stack-guard ABI for Fuchsia
authorRoland McGrath <mcgrathr@google.com>
Mon, 6 Feb 2023 02:09:20 +0000 (18:09 -0800)
committerRoland McGrath <mcgrathr@google.com>
Mon, 6 Feb 2023 02:45:59 +0000 (18:45 -0800)
commit34b21e817f19cebad4e0ae770b5d8ca4fd0ff21b
tree021311226ddcbb530bb1e5a7e79c8d9706c1a428
parentde4909312a2d5f238d27c83280e21b2770c4ebe1
[RISCV] Use OS-specific stack-guard ABI for Fuchsia

Fuchsia provides a slot relative to tp for the stack-guard value,
which is cheaper to materialize than the default GOT load.

Reviewed By: phosek

Differential Revision: https://reviews.llvm.org/D143353
llvm/lib/Target/RISCV/RISCVISelLowering.cpp
llvm/lib/Target/RISCV/RISCVISelLowering.h
llvm/lib/Target/RISCV/RISCVSubtarget.h
llvm/test/CodeGen/RISCV/stack-protector-target.ll [new file with mode: 0644]