summaryrefslogtreecommitdiffstats
path: root/gnu/llvm/include (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Merge LLVM 8.0.0 release.patrick2019-06-2313-725/+166
| | | | | | | | | Prepared with help from jsg@ and mortimer@ Tested on amd64 by bcallah@, krw@, naddy@ Tested on arm64 by patrick@ Tested on macppc by kettenis@ Tested on octeon by visa@ Tested on sparc64 by claudio@
* Import LLVM 8.0.0 release including clang, lld and lldb.patrick2019-06-23552-17202/+38340
|
* Do not store the retguard cookie in frame in leaf functions if possible.mortimer2019-03-312-1/+7
| | | | | | | Makes things slightly faster and also improves security in these functions, since the retguard cookie can't leak via the stack. ok deraadt@
* implement -msave-args in clang/llvm, like the sun did for gccdlg2019-01-301-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | this is a bit different to gcc as gcc likes to use movs to move stuff on and off the stack, and directly updates the stack pointers with add and sub instructions. llvm prefers to use push and pop instructions, is a lot more careful about keeping track of how much stuff is currently on the stack, and generally pops the frame pointer rather than do maths on it. -msave-args adds a bunch of pushes as the first thing a function prologue does. to keep the stack aligned, if there's an odd number of arguments to the function it pushes the first one again to put the frame back on a 16 byte boundary. to undo the pushes the frame pointer needs to be updated in function epilogues. clang emits a series of pops to fix up the registers on the way out, but popping saved arguments is a waste of time and harmful to actual data in the function. rather than add an offset to the stack pointer, -msave-args emits a leaveq operation to fix up the frame again. leaveq is effectively mov rbp,rsp; pop rbp, and is a single byte, meaning there's less potential for gadgets compared to a direct add to rsp, or an explicit mov rbp,rsp. the only thing missing compared to the gcc implementation is adding the SUN_amd64_parmdump dwarf flag to affected functions. if someone can tell me how to add that from the frame lowering code, let me know. when enabled in kernel builds again, this will provide useful arguments in ddb stack traces again.
* Tedu files that got removed in LLVM 7.0.1.patrick2019-01-271-80/+0
|
* Re-add files that were previously removed but are now part of LLVM 7.0.1.patrick2019-01-271-0/+196
|
* Tedu files that got removed in LLVM 7.0.1.patrick2019-01-2718-3606/+0
|
* Merge LLVM 7.0.1 release.patrick2019-01-275-44/+152
| | | | | With fixes from mortimer@ (thanks!) Tested by many, especially naddy@ (thanks!)
* Import LLVM 7.0.1 release including clang, lld and lldb.patrick2019-01-27733-12406/+34940
|
* Refactor retguard to make adding additional arches easier.mortimer2018-08-123-27/+94
|
* Add RETGUARD to clang for amd64. This security mechanism uses per-functionmortimer2018-06-064-0/+35
| | | | | | | | | | | | | | | | | | | | | | | | | random cookies to protect access to function return instructions, with the effect that the integrity of the return address is protected, and function return instructions are harder to use in ROP gadgets. On function entry the return address is combined with a per-function random cookie and stored in the stack frame. The integrity of this value is verified before function return, and if this check fails, the program aborts. In this way RETGUARD is an improved stack protector, since the cookies are per-function. The verification routine is constructed such that the binary space immediately before each ret instruction is padded with int03 instructions, which makes these return instructions difficult to use in ROP gadgets. In the kernel, this has the effect of removing approximately 50% of total ROP gadgets, and 15% of unique ROP gadgets compared to the 6.3 release kernel. Function epilogues are essentially gadget free, leaving only the polymorphic gadgets that result from jumping into the instruction stream partway through other instructions. Work to remove these gadgets will continue through other mechanisms. Remaining work includes adding this mechanism to assembly routines, which must be done by hand. Many thanks to all those who helped test and provide feedback, especially deaadt, tb, espie and naddy. ok deraadt@
* Tedu files that got removed in LLVM 6.0.0.patrick2018-04-0626-10547/+0
|
* Merge LLVM 6.0.0 release.patrick2018-04-061-21/+26
|
* Import LLVM 6.0.1 release including clang, lld and lldb.patrick2018-04-06553-8906/+33147
| | | | "where is the kaboom?" deraadt@
* Import LLVM 5.0.1 release including clang, lld and lldb.patrick2017-12-244-0/+33
|
* Tedu files that got removed in LLVM 5.0.0.patrick2017-10-0441-3166/+0
|
* Tedu files that got removed in LLVM 5.0.0.patrick2017-10-0428-8890/+0
|
* Merge LLVM 5.0.0 release.patrick2017-10-042-37/+69
|
* Import LLVM 5.0.0 release including clang, lld and lldb.patrick2017-10-04826-16805/+52568
|
* Use int3 trap padding between functions instead of trapsleds with a leading jump.mortimer2017-08-011-0/+10
| | | | ok deraadt@
* Import LLVM 4.0.0 release including clang and lld.patrick2017-03-149-33/+71
|
* Merge LLVM 4.0.0 rc1patrick2017-01-2432-3216/+0
|
* Import LLVM 4.0.0 rc1 including clang and lld to help the currentpatrick2017-01-24654-17798/+38616
| | | | development effort on OpenBSD/arm64.
* Merge LLVM 3.9.1patrick2017-01-1425-4314/+0
|
* Import LLVM 3.9.1 including clang and lld.patrick2017-01-14692-13345/+42693
|
* Use the space freed up by sparc and zaurus to import LLVM.pascal2016-09-03810-0/+236256
ok hackroom@