[PATCH] D46882: [X86][CET] Changing -fcf-protection behavior to comply with gcc (LLVM part)

Mikhail Dvoretckii via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue May 15 07:43:05 PDT 2018


mike.dvoretsky created this revision.
mike.dvoretsky added a reviewer: craig.topper.
Herald added subscribers: llvm-commits, hiraditya.

This patch aims to match the changes introduced in gcc by https://gcc.gnu.org/ml/gcc-cvs/2018-04/msg00534.html. The IBT feature definition is removed, with the IBT instructions being freely available on all X86 targets. The shadow stack instructions are also being made freely available, and the use of all these CET instructions is controlled by the module flags derived from the -fcf-protection clang option. The hasSHSTK option remains since clang uses it to determine availability of shadow stack instruction intrinsics, but it is no longer directly used.

Comes with a clang patch (https://reviews.llvm.org/D46881).


Repository:
  rL LLVM

https://reviews.llvm.org/D46882

Files:
  llvm/lib/Support/Host.cpp
  llvm/lib/Target/X86/X86.td
  llvm/lib/Target/X86/X86IndirectBranchTracking.cpp
  llvm/lib/Target/X86/X86InstrControl.td
  llvm/lib/Target/X86/X86InstrInfo.td
  llvm/lib/Target/X86/X86InstrSystem.td
  llvm/lib/Target/X86/X86Subtarget.cpp
  llvm/lib/Target/X86/X86Subtarget.h
  llvm/test/CodeGen/X86/indirect-branch-tracking.ll
  llvm/test/CodeGen/X86/nocf_check.ll
  llvm/test/CodeGen/X86/x32-cet-intrinsics.ll
  llvm/test/CodeGen/X86/x64-cet-intrinsics.ll
  llvm/test/Transforms/LoopVectorize/X86/pr23997.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D46882.146820.patch
Type: text/x-patch
Size: 10985 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180515/1aa4de4a/attachment.bin>


More information about the llvm-commits mailing list