Support OpenBSD's native frame protection conventions.
authorRafael Espindola <rafael.espindola@gmail.com>
Fri, 7 Jun 2013 16:35:57 +0000 (16:35 +0000)
committerRafael Espindola <rafael.espindola@gmail.com>
Fri, 7 Jun 2013 16:35:57 +0000 (16:35 +0000)
commit62ed8d3e35d25853e32db946a0a60da0bbf862e1
tree75efb8772a0567777f39114fbce38e526f85807d
parent47b0c0a9a0d920917e1fb10ac1c851c6e3b8aa27
Support OpenBSD's native frame protection conventions.

OpenBSD's stack smashing protection differs slightly from other
platforms:

  1. The smash handler function is "__stack_smash_handler(const char
     *funcname)" instead of "__stack_chk_fail(void)".

  2. There's a hidden "long __guard_local" object that gets linked
     into each executable and DSO.

Patch by Matthew Dempsky.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@183533 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/StackProtector.cpp
test/CodeGen/X86/stack-protector.ll