[PATCH] D19170: [safestack] Link SafeStack runtime only when not using separate stack segment

2016-11-01 Thread Michael LeMay via cfe-commits
mlemay-intel updated this revision to Diff 76636. mlemay-intel added a comment. Disabled linking of the compiler-rt SafeStack runtime library for musl environments rather than for targets that use the separate stack segment feature. This reflects changes in my proposed musl libc patches to add

[PATCH] D19853: [safestack] Add -fruntime-init to support invoking functions during runtime init

2016-10-25 Thread Michael LeMay via cfe-commits
mlemay-intel abandoned this revision. mlemay-intel added a comment. I was able to setup a temporary thread control block early enough in musl libc initialization to obviate the need for an attribute like runtime_init. https://reviews.llvm.org/D19853

Re: [PATCH] D19170: [safestack] Link SafeStack runtime only when not using separate stack segment

2016-09-23 Thread Michael LeMay via cfe-commits
mlemay-intel added a comment. In https://reviews.llvm.org/D19170#551426, @Eugene.Zelenko wrote: > Looks like patch was not committed. This patch, https://reviews.llvm.org/D17092, https://reviews.llvm.org/D17094, and https://reviews.llvm.org/D17095 are all interdependent. I think it makes

Re: [PATCH] D19854: Define Contiki OS toolchain

2016-09-23 Thread Michael LeMay via cfe-commits
mlemay-intel added a comment. In https://reviews.llvm.org/D19854#551260, @Eugene.Zelenko wrote: > Looks like patch was not committed. This patch is only useful in combination with https://reviews.llvm.org/D19852, so I was waiting for that one to be approved so these can be committed at the

Re: [PATCH] D19854: Define Contiki OS toolchain

2016-09-01 Thread Michael LeMay via cfe-commits
mlemay-intel updated this revision to Diff 70076. mlemay-intel added a comment. Fixed indentation of Contiki constructor in ToolChains.h. https://reviews.llvm.org/D19854 Files: lib/Driver/Driver.cpp lib/Driver/ToolChains.cpp lib/Driver/ToolChains.h test/Driver/fsanitize.c Index:

Re: [PATCH] D19854: Define Contiki OS toolchain

2016-06-10 Thread Michael LeMay via cfe-commits
mlemay-intel updated this revision to Diff 60357. mlemay-intel added a comment. Added driver test. http://reviews.llvm.org/D19854 Files: lib/Driver/Driver.cpp lib/Driver/ToolChains.cpp lib/Driver/ToolChains.h test/Driver/fsanitize.c Index: test/Driver/fsanitize.c

[PATCH] D19854: Define Contiki OS toolchain

2016-05-02 Thread Michael LeMay via cfe-commits
mlemay-intel created this revision. mlemay-intel added reviewers: pcc, eugenis. mlemay-intel added a subscriber: cfe-commits. It is defined with support for the SafeStack sanitizer on x86. http://reviews.llvm.org/D19854 Files: lib/Driver/Driver.cpp lib/Driver/ToolChains.cpp

[PATCH] D19853: [safestack] Add -fruntime-init to support invoking functions during runtime init

2016-05-02 Thread Michael LeMay via cfe-commits
mlemay-intel created this revision. mlemay-intel added reviewers: pcc, eugenis. mlemay-intel added a subscriber: cfe-commits. SafeStack uses thread-local storage by default in most OSes for the unsafe stack pointer. For SafeStack to be applied to functions that may be invoked while initializing

Re: [PATCH] D19483: docs: Update SafeStack docs with separate-stack-seg feature and various USP storage modes

2016-04-30 Thread Michael LeMay via cfe-commits
mlemay-intel added a comment. In http://reviews.llvm.org/D19483#417865, @pcc wrote: > > This makes sense for the example I gave. However, there are also more > > complicated situations. Sometimes it is necessary to specify different > > options for different files that are compiled for the

Re: [PATCH] D19483: docs: Update SafeStack docs with separate-stack-seg feature and various USP storage modes

2016-04-30 Thread Michael LeMay via cfe-commits
mlemay-intel added a comment. In http://reviews.llvm.org/D19483#417857, @pcc wrote: > You should be using `-target x86-unknown-contiki` or similar. That should > tune the behaviour to what is required for that OS. See what we have in > `TargetLoweringBase::getSafeStackPointerLocation` to

Re: [PATCH] D19483: docs: Update SafeStack docs with separate-stack-seg feature and various USP storage modes

2016-04-30 Thread Michael LeMay via cfe-commits
mlemay-intel added a comment. In http://reviews.llvm.org/D19483#417844, @pcc wrote: > We shouldn't be adding (much less documenting) `-mllvm` flags. Is there any > reason why this behavior can't be gated on the OS? We actually already have added at least one `-mllvm` flag: `-mllvm

Re: [PATCH] D19483: docs: Update SafeStack docs with separate-stack-seg feature and single-thread storage

2016-04-29 Thread Michael LeMay via cfe-commits
mlemay-intel updated this revision to Diff 55706. mlemay-intel added a comment. Add documentation for -safe-stack-usp-storage=tcb, -safe-stack-usp-tcb-offset=, and -safe-stack-usp-init. http://reviews.llvm.org/D19483 Files: docs/SafeStack.rst Index: docs/SafeStack.rst

Re: [PATCH] D19458: Add address space 258 to Clang documentation

2016-04-25 Thread Michael LeMay via cfe-commits
mlemay-intel updated this revision to Diff 54877. mlemay-intel added a comment. Update heading. http://reviews.llvm.org/D19458 Files: docs/LanguageExtensions.rst Index: docs/LanguageExtensions.rst === ---

Re: [PATCH] D19170: [safestack] Link SafeStack runtime only when not using separate stack segment

2016-04-15 Thread Michael LeMay via cfe-commits
mlemay-intel updated this revision to Diff 53956. mlemay-intel added a comment. Add test. http://reviews.llvm.org/D19170 Files: lib/Driver/Tools.cpp test/Driver/sanitizer-ld.c Index: test/Driver/sanitizer-ld.c === ---

Re: [PATCH] D19170: [safestack] Link SafeStack runtime only when not using separate stack segment

2016-04-15 Thread Michael LeMay via cfe-commits
mlemay-intel added a comment. In http://reviews.llvm.org/D19170#402861, @eugenis wrote: > Test, please. Do you know of any examples of the sort of test that you would like to see for a feature like this? > Where is this runtime support implemented? Some platform's libc, or an > external

Re: [PATCH] D17092: [X86] Add -mseparate-stack-seg

2016-04-15 Thread Michael LeMay via cfe-commits
mlemay-intel updated this revision to Diff 53920. mlemay-intel added a comment. Revise patch to fix line alignment. http://reviews.llvm.org/D17092 Files: include/clang/Driver/Options.td lib/CodeGen/TargetInfo.cpp test/CodeGen/varargs.c Index: test/CodeGen/varargs.c

Re: [PATCH] D17092: [X86] Add -mseparate-stack-seg

2016-02-23 Thread Michael LeMay via cfe-commits
mlemay-intel added a comment. Thank you for your feedback! Comment at: lib/CodeGen/TargetInfo.cpp:1569 @@ +1568,3 @@ +CGF.getTarget().getTargetOpts().Features; + if (std::find(TargetFeatures.begin(), TargetFeatures.end(), +"+separate-stack-seg") !=