summaryrefslogtreecommitdiff
path: root/gnu/llvm/tools
AgeCommit message (Collapse)Author
2018-06-12Merge '.openbsd.randomdata.*' sections into a single '.openbsd.randomdata'Philip Guenther
section when linking, as we do when using ld from binutils. ok mortimer@ deraadt@
2018-06-07Pass -nopie to the linker when -pg is specified to make theYASUOKA Masahiko
profiler(gprof) work properly. ok mpi
2018-06-06Add RETGUARD to clang for amd64. This security mechanism uses per-functionmortimer
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@
2016-09-03Use the space freed up by sparc and zaurus to import LLVM.Pascal Stumpf
ok hackroom@
2018-06-03Add ret protctor options as no-ops.mortimer
2018-06-03Work around a bug where discarding the .ARM.exidx section in the armv7 kernelMark Kettenis
linker script makes ld.lld(1) crash. This has been fixed in a different (proper?) way upstream but backporting their fix is a bit too invasive. ok patrick@
2018-05-05Switch armv7 to the "softfp" floating-point ABI. The ABI is identical toMark Kettenis
the "soft" floating-point ABI but this does allow the compiler to generate FPU instructions. ok deraadt@
2017-10-04Import LLVM 5.0.0 release including clang, lld and lldb.Patrick Wildt
2018-04-12keep the STT_FILE symbol in the table so that we know what fileRobert Nagy
was used to compile and object ok kettenis@
2018-04-07add back ld.lld 6.0 changesJonathan Gray
2018-04-06Tedu files that got removed in LLVM 6.0.0.Patrick Wildt
2018-04-06Merge LLVM 6.0.0 release.Patrick Wildt
2018-04-06Import LLVM 6.0.1 release including clang, lld and lldb.Patrick Wildt
"where is the kaboom?" deraadt@
2017-01-24Import LLVM 4.0.0 rc1 including clang and lld to help the currentPatrick Wildt
development effort on OpenBSD/arm64.
2017-01-14Import LLVM 3.9.1 including clang and lld.Patrick Wildt
2016-09-03Use the space freed up by sparc and zaurus to import LLVM.Pascal Stumpf
ok hackroom@
2018-03-02Add a manual page for lld from lld svn rev 326463 with options notJonathan Gray
present in lld 5.0.1 removed (--build-id=fast, -z muldefs, -z retpolineplt). This includes a bunch of mdoc changes suggested by schwarze@ that were recently committed upstream. ok jmc@ schwarze@ kettenis@ deraadt@
2018-01-22add clang-local(1) to SEE ALSOJonathan Gray
suggested by jmc@ ok patrick@
2016-09-03Use the space freed up by sparc and zaurus to import LLVM.Pascal Stumpf
ok hackroom@
2018-01-01Make lld respect ALIGN directives on output sections even with -r. FixesMark Kettenis
the generation of gap.o. ok patrick@
2017-01-14Import LLVM 3.9.1 including clang and lld.Patrick Wildt
2017-12-26Cherry-pick a change from LLD to make the behavior of the -v optionPatrick Wildt
more closer to GNU linkers. This should help with autoconf/libtool compatibility in ports. Requested by Brad "no objection" kettenis@
2017-12-25Tedu files that got removed in LLVM 5.0.1.Patrick Wildt
2017-12-24Merge LLVM 5.0.1 release.Patrick Wildt
2017-12-24Import LLVM 5.0.1 release including clang, lld and lldb.Patrick Wildt
2017-10-24kbind(2) for the win: we can always put .got.plt in RELROPhilip Guenther
ok kettenis@ deraadt@
2017-01-14Import LLVM 3.9.1 including clang and lld.Patrick Wildt
2017-10-04Tedu files that got removed in LLVM 5.0.0.Patrick Wildt
2017-10-04Tedu files that got removed in LLVM 5.0.0.Patrick Wildt
2017-10-04Merge LLVM 5.0.0 release.Patrick Wildt
2017-10-04Import LLVM 5.0.0 release including clang, lld and lldb.Patrick Wildt
2017-01-14Import LLVM 3.9.1 including clang and lld.Patrick Wildt
2016-09-03Use the space freed up by sparc and zaurus to import LLVM.Pascal Stumpf
ok hackroom@
2017-08-07Actually enable the kprintf format attribute.Mark Kettenis
ok florian@
2017-08-04Backport https://reviews.llvm.org/D29778. Fixes a bug where clang wasMark Kettenis
optimizing code around an lgamma(3) call a bit too much. Fixes the lib/libm/lgamma regress test. ok patrick@, millert@
2016-09-03Use the space freed up by sparc and zaurus to import LLVM.Pascal Stumpf
ok hackroom@
2017-07-29Disable -Waddress-of-packed-member by default.Mark Kettenis
While these warnings have the potential to be useful, there are too manu false positives right now. ok deraadt@
2017-07-28On OpenBSD disable the malloc/calloc/realloc/free/str*dup builtins, sinceTheo de Raadt
they can perform strange transforms and optimizations. Some of those could gain a slight advantage, but would avoid the variety of important runtime checks our malloc(3) code does. In essence, the transforms performed are considered "anti-mitigation". ok kettenis robert, discussions with others
2017-07-27teach clang about our syslog format attributeRobert Nagy
ok deraadt@
2017-07-27push back -pie to the linker if -pie is specified to avoid an unused argumentRobert Nagy
warning ok kettenis@, deraadt@
2016-09-03Use the space freed up by sparc and zaurus to import LLVM.Pascal Stumpf
ok hackroom@
2017-06-06Enable -fwrapv by default with clang to treat signed integer overflowsJonathan Gray
as defined. This is done to prevent dangerous optimisations which could remove security critical overflow checks. Base gcc has -fno-strict-overflow by default, with clang this is identical to -fwrapv. Prompted by naddy@ discovering a hang with a clang compiled i386 kernel that was resolved with -fwrapv. ok kettenis@ pascal@
2017-06-02Synonym -Wno-cpp for -Wno-#warnings. That one is not a headache forMarc Espie
scripting. (got it into upstream, it's just a backport) okay kettenis@, patrick@
2016-09-03Use the space freed up by sparc and zaurus to import LLVM.Pascal Stumpf
ok hackroom@
2017-05-09Enable TLS support but default to the emulatated TLS model. Enable theMark Kettenis
runtime support code libcompiler_rt for this. This code uses functions that live in libpthread, so code that uses TLS support will need to be linked with -lpthread. This should allow more ports to build with base clang. ok espie@
2017-04-16Disable colored diagnostics in LLVM's lld.Patrick Wildt
Requested by deraadt@
2017-03-24Add "supported targets" in lld --help output to be compatible with whatJonathan Gray
libtool generated configure scripts expect. Otherwise they might assume shared libraries aren't supported. From lld svn revisions 298568 and 298571. Discussed with kettenis@
2017-03-24Add "(compatible with GNU linkers)" to the lld version output to avoidJonathan Gray
problems with configure scripts generated with libtool.m4 that would otherwise have to be regenerated with a patched libtool. Among other things this fixes the build of Mesa on arm64 with lld. From lld svn revision 298532. ok kettenis@
2017-03-19Work around a problem where linker-generated symbols are not properlyMark Kettenis
versioned and end up as local symbols despite being explicitly listed as global in the version script. This breaks out brk()/sbrk() implementation. The diff is only a partial solution and unlikely to be accepted as-is upstream. We'll keep it as a local diff until a better solution is found. ok guenther@
2017-01-14Import LLVM 3.9.1 including clang and lld.Patrick Wildt