[PATCH] D73245: Depend stddef.h to provide max_align_t for C++11 and provide better fallback in

2020-03-17 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added inline comments. Comment at: libcxx/include/new:240 return __align > __STDCPP_DEFAULT_NEW_ALIGNMENT__; +#elif defined(_LIBCPP_CXX03_LANG) + return __align > alignment_of<__libcpp_max_align_t>::value; ldionne wrote: > joerg wrote: > >

[PATCH] D70048: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2020-01-02 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. LLVM Release Schedule: 10.0.0: Jan 15, 2020: branch, then rc1 It would be nice to get a reply to my mail proposal before the branch.. so we could push the code for LLVM 10. (If it was lost, I can resend it) It can likely upset both sides, but with the proposal in

[PATCH] D70048: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2020-01-01 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Ping? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D70048/new/ https://reviews.llvm.org/D70048 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D70048: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-12-20 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. @MaskRay I will mail you off-list with one question. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D70048/new/ https://reviews.llvm.org/D70048 ___ cfe-commits mailing list

[PATCH] D70048: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-12-20 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Herald added a subscriber: arichardson. Ping? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D70048/new/ https://reviews.llvm.org/D70048 ___ cfe-commits mailing list

[PATCH] D70048: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-12-13 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Stating it from a different side. If you do not care about GNU ld drop-in replacement property for Linux it's not our business, but we do care about this in NetBSD and we restrict this to our project only (from ELF targets). If you do not care about NetBSD, you

[PATCH] D70048: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-12-13 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. @joerg works on the ELF loader and we just need to wait for him. We wrote our temporary patch, but it was not ideal as the long term solution. compiler-rt is nicely maintained from our perspective and we have almost feature parity with Linux. We maintain and

[PATCH] D70048: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-12-13 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. We attempted to patch internally LLD rebasing our code for the buildbot purposes but LLD without being used rots quickly, see: https://reviews.llvm.org/D58892 We use LD as `ld` and there are no plans neither intentions to break it. It was already decided

[PATCH] D70958: [compiler-rt] [test] Disable ASLR on ASAN/MSAN/TSAN tests on NetBSD

2019-12-05 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added inline comments. Comment at: compiler-rt/test/sanitizer_common/netbsd_commands/run_noaslr.sh:4 +PATH=${PATH}:/usr/sbin +paxctl +a "${1}" +exec "${@}" eugenis wrote: > krytarowski wrote: > > I propose to use `/usr/bin/paxctl` as it will be PATH

[PATCH] D70958: [compiler-rt] [test] Disable ASLR on ASAN/MSAN/TSAN tests on NetBSD

2019-12-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D70958#1767912 , @eugenis wrote: > Could this go into the common lit config in compiler-rt/test? Do you mean to run this for all tests in compiler-rt? We intend to disable it only when needed and prevent leaking

[PATCH] D70048: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-11-30 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Ping? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D70048/new/ https://reviews.llvm.org/D70048 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D70048: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-11-19 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a reviewer: chandlerc. krytarowski added a comment. Ping? We are in the process of switching our buildbot to newer NetBSD snapshot (-8 to -9) and we keep waiting for this patch to land. If we could get this patch merged, we could build and link the whole LLVM with lld on

[PATCH] D70048: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-11-14 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. ping? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D70048/new/ https://reviews.llvm.org/D70048 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D70048: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-11-11 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Short summary: - FreeBSD/OpenBSD ship with mutations of the behavior of ELF/GNU/Linux in certain nits, we do the same with our driver. - MinGW ships with a frontend driver to COFF, we do the same with a driver to ELF/GNU/Linux. - Darwin ships with default search

[PATCH] D69755: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-11-09 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski abandoned this revision. krytarowski added a comment. Better patch in https://reviews.llvm.org/D70048 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69755/new/ https://reviews.llvm.org/D69755

[PATCH] D70048: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-11-09 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski updated this revision to Diff 228591. krytarowski added a comment. - fix a typo in a comment. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D70048/new/ https://reviews.llvm.org/D70048 Files: clang/lib/Driver/ToolChain.cpp

[PATCH] D70048: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-11-09 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Another approach to achieve the same goal as previous attempts. It is already better as it avoids two forks. Does this one look like fine for merging? The previous one for the reference: https://reviews.llvm.org/D69755 Repository: rG LLVM Github Monorepo

[PATCH] D70048: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-11-09 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski created this revision. krytarowski added reviewers: joerg, mgorny, ruiu, MaskRay. krytarowski added a project: lld. Herald added subscribers: llvm-commits, cfe-commits, mstorsjo, fedor.sergeev, aheejin, emaste, dschuff. Herald added projects: clang, LLVM. The NetBSD target wraps the

[PATCH] D69755: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-11-05 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. > burden with the upstream We are the part of mainstream and have 4 developers in LLVM + few others contributing. We run the NetBSD buildbot that builds and runs test of LLD. http://lab.llvm.org:8014/builders/netbsd-amd64 Repository: rG LLVM Github Monorepo

[PATCH] D69755: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-11-05 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. I don't want to diverge this patch on offtopic or general discussion. Does it look good for landing? We need this support to be functional out of the box and as a part of LLVM. E.g. `clang -fuse-ld=` currently tries to call `ld.lld`, with this patch it will go

[PATCH] D69755: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-11-02 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D69755#1731394 , @MaskRay wrote: > I still have the feeling that such configurations should be added to > clangDriver/gcc specs or a shell script wrapper of lld. OK, as you allow now a shell wrapper of lld, this is a

[PATCH] D69755: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-11-02 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski marked an inline comment as done. krytarowski added inline comments. Comment at: lld/tools/nb.lld/nb.lld.cpp:94 + + // disable superfluous RUNPATH on NetBSD + args.push_back("--disable-new-dtags"); MaskRay wrote: > You can't use DT_RUNPATH probably

[PATCH] D69755: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-11-02 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski updated this revision to Diff 227593. krytarowski added a comment. - upload diff with wider context Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D69755/new/ https://reviews.llvm.org/D69755 Files: clang/lib/Driver/ToolChain.cpp

[PATCH] D69755: [LLD] Add NetBSD support as a new flavor of LLD (nb.lld)

2019-11-02 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski created this revision. krytarowski added reviewers: ruiu, joerg, mgorny, MaskRay. krytarowski added a project: lld. Herald added subscribers: llvm-commits, cfe-commits, fedor.sergeev, aheejin, emaste, dschuff. Herald added projects: clang, LLVM. The NetBSD target wraps the default

[PATCH] D56554: [ELF] Add '-z nognustack' opt to suppress emitting PT_GNU_STACK

2019-10-21 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. This looks good as an intermediate step to make lld saner. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56554/new/ https://reviews.llvm.org/D56554 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D52386: [Lexer] Add udefined_behavior_sanitizer feature

2019-09-21 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Herald added a project: LLVM. This is needed in the NetBSD kernel, more fine-grained checks would be acceptable too, but one global feature detection is what I need. Repository: rL LLVM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D52386/new/

[PATCH] D67719: [clang] [Basic] Enable __has_feature(leak_sanitizer)

2019-09-20 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Looks good to me but I will leave the final decision to someone else. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D67719/new/ https://reviews.llvm.org/D67719 ___ cfe-commits mailing list

[PATCH] D66361: Improve behavior in the case of stack exhaustion.

2019-09-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D66361#1656037 , @rsmith wrote: > In D66361#1655903 , @krytarowski > wrote: > > > This change broke on NetBSD. > > > >

[PATCH] D66361: Improve behavior in the case of stack exhaustion.

2019-09-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. This change broke on NetBSD. http://lab.llvm.org:8011/builders/netbsd-amd64/builds/22003/steps/run%20unit%20tests/logs/FAIL%3A%20Clang%3A%3Astack-exhaustion.cpp (view as text) TEST 'Clang :: SemaTemplate/stack-exhaustion.cpp' FAILED

[PATCH] D64488: [Driver] Support -fsanitize=function on Solaris/x86

2019-07-30 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D64488#1606758 , @ro wrote: > In D64488#1606716 , @krytarowski > wrote: > > > Something is broken between reviews. and my mailbox as I am not receiving > > any e-mails so pinging

[PATCH] D64488: [Driver] Support -fsanitize=function on Solaris/x86

2019-07-30 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Something is broken between reviews. and my mailbox as I am not receiving any e-mails so pinging does not make any effect... no LLVM admin replied to my questions on this to validate whether my mail was blacklisted or similar. I have decided to change server of my

[PATCH] D56650: [lld] [ELF] Support customizing behavior on target triple

2019-07-02 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. > Personally I am opposed to this change. The compiler driver (gcc,clang) has a > set of arch/OS dependent defaults. It seems weird/redundant to add another > sets of defaults on the linker side. The NetBSD toolchain relies on internal knowledge in a linker that

[PATCH] D56650: [lld] [ELF] Support customizing behavior on target triple

2019-07-01 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Herald added a subscriber: MaskRay. @ruiu ping? LLVM 9 is branching soon and we would like to unearth from local patches. From the internal discussions it was decided that we want to maintain our current behavior that differs to Linux. CHANGES SINCE LAST ACTION

[PATCH] D59744: Fix i386 ABI "__m64" type bug

2019-06-04 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D59744#1529218 , @mgorny wrote: > In D59744#1529182 , @krytarowski > wrote: > > > In D59744#1527412 , @wxiao3 wrote: > > > > > Consider

[PATCH] D59744: Fix i386 ABI "__m64" type bug

2019-06-04 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added subscribers: mgorny, joerg. krytarowski added a comment. In D59744#1527412 , @wxiao3 wrote: > Consider other Systems (e.g Darwin, PS4 and FreeBSD) don't want to spend any > effort dealing with the ramifications of ABI breaks (as

[PATCH] D62638: [analyzer] A Python script to prettify the ExplodedGraph dumps.

2019-06-04 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. This commit breaks the NetBSD buildbot node. http://lab.llvm.org:8011/builders/netbsd-amd64/builds/20359 The problem is that this patch hardcodes python specific binary name, while it has to be detected dynamically or ideally passed from CMake. Afair lit has a

[PATCH] D59744: Fix i386 ABI "__m64" type bug

2019-06-02 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. sysv abi is not only for UNIX but most non-Windows ones (BSDs, HAIKU, ...). CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59744/new/ https://reviews.llvm.org/D59744 ___ cfe-commits mailing list

[PATCH] D60748: Fix i386 struct and union parameter alignment

2019-05-29 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added subscribers: mgorny, joerg. krytarowski added inline comments. Comment at: lib/CodeGen/TargetInfo.cpp:1501 +// +// Exclude other System V OS (e.g Darwin, PS4 and FreeBSD) since we don't +// want to spend any effort dealing with the ramifications of

[PATCH] D62005: [libunwind] [test] Fix inferring source paths

2019-05-22 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski resigned from this revision. krytarowski added a comment. Herald added a subscriber: krytarowski. It is probably fine.. but I will defer review to lit/libc++ maintainers. Repository: rUNW libunwind CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62005/new/

[PATCH] D60728: [clang] [test] Add a (xfailing) test for PR41027

2019-04-17 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D60728#1469794 , @hans wrote: > In D60728#1468713 , @krytarowski > wrote: > > > In D60728#1468486 , @hans wrote: > > > > > What's the value

[PATCH] D60728: [clang] [test] Add a (xfailing) test for PR41027

2019-04-16 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D60728#1468486 , @hans wrote: > What's the value in checking in this xfail'ed test without an actual fix for > the problem? Raise awareness about the problem. CHANGES SINCE LAST ACTION

[PATCH] D60728: [clang] [test] Add a (xfailing) test for PR41027

2019-04-16 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a reviewer: void. krytarowski added a subscriber: void. krytarowski added a comment. Adding @void, regression introduced with D55616 . CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60728/new/ https://reviews.llvm.org/D60728

[PATCH] D55616: Emit ASM input in a constant context

2019-04-16 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. @void hi, this broke assembly code on NetBSD for various archs and blocks upgrade of the toolchain. Could you please have a look? https://bugs.llvm.org/show_bug.cgi?id=41027 Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55616/new/

[PATCH] D52610: [Esan] Port cache frag to FreeBSD

2019-03-10 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski resigned from this revision. krytarowski added a comment. Herald added a project: clang. ESan is now discontinued. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D52610/new/ https://reviews.llvm.org/D52610

[PATCH] D56647: [WIP] [ELF] Implement --copy-dt-needed-entries

2019-03-04 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. NetBSD patches GNU linker to behave in the original way. This behavior is mandated from lld as well in order to treat it as a drop-in replacement. Preference here and of other lld characteristics is so strong that the NetBSD community in case of rejected patches

[PATCH] D56647: [WIP] [ELF] Implement --copy-dt-needed-entries

2019-03-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Herald added a subscriber: MaskRay. Herald added a project: LLVM. @ruiu ping? Repository: rLLD LLVM Linker CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56647/new/ https://reviews.llvm.org/D56647 ___

[PATCH] D58592: [clang] [ToolChains/NetBSD] Support relative libc++ header path

2019-02-24 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski accepted this revision. krytarowski added a comment. This revision is now accepted and ready to land. This will make life much more easier now with this change. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D58592/new/ https://reviews.llvm.org/D58592

[PATCH] D58592: [clang] [ToolChains/NetBSD] Support relative libc++ header path

2019-02-24 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added inline comments. Comment at: clang/lib/Driver/ToolChains/NetBSD.cpp:430 +// system install from src +getDriver().SysRoot + "/usr/include/c++", + }; mgorny wrote: > krytarowski wrote: > > mgorny wrote: > > > krytarowski wrote: > > > > I

[PATCH] D58592: [clang] [ToolChains/NetBSD] Support relative libc++ header path

2019-02-24 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added inline comments. Comment at: clang/lib/Driver/ToolChains/NetBSD.cpp:430 +// system install from src +getDriver().SysRoot + "/usr/include/c++", + }; mgorny wrote: > krytarowski wrote: > > I propose to go for: > > > >

[PATCH] D58592: [clang] [ToolChains/NetBSD] Support relative libc++ header path

2019-02-24 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added inline comments. Comment at: clang/lib/Driver/ToolChains/NetBSD.cpp:430 +// system install from src +getDriver().SysRoot + "/usr/include/c++", + }; I propose to go for: `getDriver().SysRoot + "/usr/include/c++/v1",` with a fallback

[PATCH] D57592: Replace uses of %T with %t in from previous frontend test differential

2019-02-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. The NetBSD buildbot breaks in these tests now: http://lab.llvm.org:8011/builders/lldb-amd64-ninja-netbsd8/builds/18721 Both tests break in a similar way: Command Output (stderr): -- + : 'RUN: at line 1' + not /home/motus/netbsd8/netbsd8/build/bin/clang -cc1

[PATCH] D56650: [lld] [ELF] Support customizing behavior on target triple

2019-01-30 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. > chandlerc added a comment. > > There was a long discussion between two NetBSD maintainers about this (both > already in the reviewers list of this patch). I'm not sure if there is an > existing thread that would be better to follow up on as opposed to starting a

[PATCH] D56650: [lld] [ELF] Support customizing behavior on target triple

2019-01-30 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D56650#1377546 , @ruiu wrote: > If you still need to patch GNU ld, it doesn't seems like this patch makes > things easier for you. (But even if this would make it easier for you, this > patch's approach is not okay by

[PATCH] D56650: [lld] [ELF] Support customizing behavior on target triple

2019-01-30 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. If we pass flags from clang, we sacrifice: - lld usable as a standalone executable - gcc capable to use lld as a functional linker - clang driver not capable to call unpatched gnu ld/gold as we grow local flags to workaroud the customization (such as -z nognustack)

[PATCH] D56650: [lld] [ELF] Support customizing behavior on target triple

2019-01-30 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. @rui we need some resolution here. We have stronger feelings from the community to customize the linker directly based on detected triple. At least other !GNU platforms will benefit from it too (at least FreeBSD, OpenBSD and other BSD derivations like mentioned

[PATCH] D57303: [ToolChains] [NetBSD] Append -rpath for shared compiler-rt runtimes

2019-01-27 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D57303#1373077 , @phosek wrote: > In D57303#1373061 , @krytarowski > wrote: > > > How do you resolve paths? Linker cache with registry of libraries? > > > `DT_NEEDED` aren't treated

[PATCH] D57303: [ToolChains] [NetBSD] Append -rpath for shared compiler-rt runtimes

2019-01-27 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D57303#1373057 , @phosek wrote: > In D57303#1373035 , @krytarowski > wrote: > > > + vitalybuka > > > > Can we fix it for everybody? It's certainly not restricted to NetBSD. > > > As

[PATCH] D57303: [ToolChains] [NetBSD] Append -rpath for shared compiler-rt runtimes

2019-01-27 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a reviewer: vitalybuka. krytarowski added a comment. + vitalybuka Can we fix it for everybody? It's certainly not restricted to NetBSD. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D57303/new/ https://reviews.llvm.org/D57303

[PATCH] D56554: [ELF] Add '-z nognustack' opt to suppress emitting PT_GNU_STACK

2019-01-11 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D56554#1354885 , @ruiu wrote: > In D56554#1353572 , @krytarowski > wrote: > > > What do you think about this new logic: > > > > 1. specified `-z execstack` -> do not emit GNU STACK

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-11 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D56215#1350179 , @ruiu wrote: > To be honest, I don't think I would lgtm a patch that changes lld's default > behavior depending on host/target only for NetBSD, and it seems like a > NetBSD's issue rather than an lld's

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-11 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Actually probably Linux MIPS used it and some proprietary OSes.. but we skip them for now. Only FreeBSD sets OSABI in lld and uses an emulation name detection hack. Once we will get merged TripleTarget detection we can switch it to use proper Triple check.

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-11 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added inline comments. Comment at: ELF/Driver.cpp:375 +switch (Config->EMachine) { + case EM_386: +Config->SearchPaths.push_back("=/usr/lib/i386"); As we have TargetTriple now, I would use it here instead of `Config->EMachine`, it

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-11 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D56215#1354603 , @krytarowski wrote: > @mgorny could you check if we can get crossbuilding functional for: > > - to !NetBSD from NetBSD > - from !NetBSD to NetBSD. > - from NetBSD/amd64 to NetBSD/aarch64 > > I wonder

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-11 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. @mgorny could you check if we can get crossbuilding functional for: - to !NetBSD from NetBSD - from !NetBSD to NetBSD. - from NetBSD/amd64 to NetBSD/aarch64 I wonder whether it can work if we will keep using 'ld' file name for a linker. Comment

[PATCH] D56554: [ELF] Add '-z nognustack' opt to suppress emitting PT_GNU_STACK

2019-01-11 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. @ruiu actually if we can get D56215 merged we will be able to tune it specifically for NetBSD (with `if (Config->TargetTriple.isOSNetBSD()) {`) and retain intact the current Linux-biased logic for everybody who deserves to use it.

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-11 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added inline comments. Comment at: ELF/Driver.cpp:770 + // Start with a default initial triple + Config->TargetTriple = llvm::Triple(getDefaultTargetTriple()); + krytarowski wrote: > arichardson wrote: > > arichardson wrote: > > > If I invoke an

[PATCH] D56607: [clang] [NetBSD] Enable additional sanitizer types

2019-01-11 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Please check these options in regression test-suite. There are also some missing entries and please add them too. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56607/new/ https://reviews.llvm.org/D56607

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-11 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added inline comments. Comment at: ELF/Driver.cpp:770 + // Start with a default initial triple + Config->TargetTriple = llvm::Triple(getDefaultTargetTriple()); + arichardson wrote: > arichardson wrote: > > If I invoke an unprefixed ld.lld on NetBSD

[PATCH] D56554: [ELF] Add '-z nognustack' opt to suppress emitting PT_GNU_STACK

2019-01-10 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. What do you think about this new logic: 1. specified `-z execstack` -> do not emit GNU STACK segment 2. specified `-z noexecstack` -> emit GNU STACK segment 3. no option specified -> detect `findSection(".note.GNU-stack")` (I might miss offhand some details here to

[PATCH] D56554: [ELF] Add '-z nognustack' opt to suppress emitting PT_GNU_STACK

2019-01-10 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. I understand the concerns, but lld is biased with being a Linux linker. We need to customize it (restore defaults?) for NetBSD. Repository: rLLD LLVM Linker CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56554/new/ https://reviews.llvm.org/D56554

[PATCH] D56554: [ELF] Add '-z nognustack' opt to suppress emitting PT_GNU_STACK

2019-01-10 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Shouldn't the logic of emitting/not-emitting be based on `findSection(".note.GNU-stack")`? @mgorny can you please investigate it? Repository: rLLD LLVM Linker CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56554/new/ https://reviews.llvm.org/D56554

[PATCH] D56554: [ELF] Add '-z nognustack' opt to suppress emitting PT_GNU_STACK

2019-01-10 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Actually looking at GNU ld(1) source code, the logic is a little bit more complex and it depends on more aspects like relocations. Repository: rLLD LLVM Linker CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56554/new/ https://reviews.llvm.org/D56554

[PATCH] D56554: [ELF] Add '-z nognustack' opt to suppress emitting PT_GNU_STACK

2019-01-10 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D56554#1353513 , @ruiu wrote: > In D56554#1353487 , @krytarowski > wrote: > > > In D56554#1353368 , @ruiu wrote: > > > > > The absence of

[PATCH] D56554: [ELF] Add '-z nognustack' opt to suppress emitting PT_GNU_STACK

2019-01-10 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D56554#1353368 , @ruiu wrote: > The absence of PT_GNU_STACK segment makes stack area executable on systems > that recognizes PT_GNU_STACK segment. So, I think if `-z execstack` is > specified, we should omit PT_GNU_STACK

[PATCH] D56554: [ELF] Add '-z nognustack' opt to suppress emitting PT_GNU_STACK

2019-01-10 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added inline comments. Comment at: ELF/Driver.cpp:874 Config->ZGlobal = hasZOption(Args, "global"); + Config->ZNognustack = hasZOption(Args, "nognustack"); Config->ZHazardplt = hasZOption(Args, "hazardplt"); I would add `gnustack` vs

[PATCH] D56554: [ELF] Add '-z nognustack' opt to suppress emitting PT_GNU_STACK

2019-01-10 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added inline comments. Comment at: ELF/Writer.cpp:1980 + if (!Config->ZNognustack) { +// PT_GNU_STACK is a special section to tell the loader to make the +// pages for the stack non-executable. If you really want an executable section ->

[PATCH] D56554: [ELF] Add '-z nognustack' opt to suppress emitting PT_GNU_STACK

2019-01-10 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Looks good, we don't GNU STACK on NetBSD. Repository: rLLD LLVM Linker CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56554/new/ https://reviews.llvm.org/D56554 ___ cfe-commits mailing list

[PATCH] D56554: [ELF] Add '-z nognustack' opt to suppress emitting PT_GNU_STACK

2019-01-10 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added inline comments. Comment at: docs/ld.lld.1:515 +.Dv PT_GNU_STACK +segment. .It Cm norelro section? Repository: rLLD LLVM Linker CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56554/new/ https://reviews.llvm.org/D56554

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-10 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. @joerg if you think that this patch is OK, please click accept so we can be aware that this is what you want. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56215/new/ https://reviews.llvm.org/D56215 ___

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-08 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added inline comments. Comment at: ELF/Driver.cpp:781 + } +} + There is need to add a fallback for a native triple. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56215/new/ https://reviews.llvm.org/D56215

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-08 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D56215#1350134 , @joerg wrote: > Thanks, this looks like a good starting point. What's the final state you want? CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56215/new/ https://reviews.llvm.org/D56215

[PATCH] D56288: [ELF] Do not enable 'new dtags' on NetBSD by default

2019-01-07 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. On NetBSD the 'new' semantics was already implemented with 'old' RPATH. I don't know the timing whether there already existed RUNPATH, but the result is that we never implemented it and never needed it. The core of NetBSD was convinced to add an alias as it was

[PATCH] D56288: [ELF] Do not enable 'new dtags' on NetBSD by default

2019-01-07 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D56288#1348148 , @mgorny wrote: > Ok, maybe I'm being silly but since clang driver has to pass > `--enable-new-dtags` for GNU ld compatibility anyway, wouldn't it make sense > to keep the default as disabled in order to

[PATCH] D52610: [Esan] Port cache frag to FreeBSD

2019-01-06 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Can you try to port this mutant thread-process in ESan to FreeBSD? I don't want to see changes in generic LLVM code. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D52610/new/ https://reviews.llvm.org/D52610

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-05 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. I've grepped FreeBSD, OpenBSD and pkgsrc. OpenBSD ports = Total 2 packages there have issues with LLD. $ grep -r USE_LLD . ./devel/libcoap/Makefile:USE_LLD= No ./sysutils/firmware/vmm/Makefile:USE_LLD= No FreeBSD ports =

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-04 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D56215#1346342 , @arichardson wrote: > In D56215#1346061 , @mgorny wrote: > > > For the record, another option is to actually fix other software not to > > call LD directly. > > >

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D56215#1345845 , @ruiu wrote: > Not sure what I understand the point, but as to make lld work on/for NetBSD, > I wonder if you can just add -L to the command line in the compiler > driver. Isn't a NetBSD triple passed to

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Actually I think that we can handle two cases witch a combination of proposals: - native mode - cross mode For the native mode we go for something like: #if defined(__NetBSD__) #define NATIVE_TARGET LLD_NETBSD #else ... and for cross mode read `argv[0]` to

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D56215#1345695 , @ruiu wrote: > In D56215#1345417 , @joerg wrote: > > > Talking from the perspective of having had to deal with thousands of > > packages in pkgsrc over the years:

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. On 03.01.2019 23:15, Joerg Sonnenberger wrote: > On Thu, Jan 03, 2019 at 09:38:49PM +0000, Kamil Rytarowski via Phabricator via cfe-commits wrote: >> I think that this place is not the right place to bash GNU ld for performance issues. >

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. On Thu, Jan 03, 2019 at 08:31:53PM +, Kamil Rytarowski via Phabricator via cfe-commits wrote: > krytarowski added a comment. > > On 03.01.2019 21:19, Joerg Sonnenberger wrote: > >> On Thu, Jan 03, 2019 at 06:34:22PM +, Ka

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. I think that ifdefining the linker options with `__NetBSD__` is no-go. In D56215#1345563 , @mgorny wrote: > We've discussed this a bit and given other changes we need to do, and I see > pretty much three options here: > > 1.

[PATCH] D56288: [ELF] Do not enable 'new dtags' on NetBSD by default

2019-01-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. We want to keep it disabled by default on NetBSD.. but it would be to keep dynamic detection of target NetBSD rather than hardcoded ifdef. GNU ld sets it by default to false, following it would be the easiest option. Repository: rLLD LLVM Linker CHANGES SINCE

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. On 03.01.2019 21:19, Joerg Sonnenberger wrote: > On Thu, Jan 03, 2019 at 06:34:22PM +0000, Kamil Rytarowski via Phabricator > via cfe-commits wrote: > >> krytarowski added a comment. >> >> Actually I find it frustrating and unfair as

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added inline comments. Comment at: ELF/Driver.cpp:369 +void LinkerDriver::appendDefaultSearchPaths() { +#if defined(__NetBSD__) + // NetBSD driver relies on the linker knowing the default search paths. is it possible to use some Triple NetBSD target

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added inline comments. Comment at: ELF/Driver.cpp:377 + break; +case EM_MIPS: + if (Config->EKind == ELF64LEKind || Config->EKind == ELF64BEKind) Please drop MIPS/PPC for now. CHANGES SINCE LAST ACTION

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. We will prepare a patch for i386 x86_64 only for now. Until we will get lld fully functional on NetBSD/amd64 we will skip other architectures. Repository: rLLD LLVM Linker CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56215/new/

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. In D56215#1345400 , @ruiu wrote: > Joerg, what is special about NetBSD? Nothing. But the result is that we don't have GNU gold either and are stuck with 40min linking times of LLVM. It's destructive to productivity and

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. Actually I find it frustrating and unfair as GNU ld doesn't have builtin knowledge either.. it's passed with gross 'super hack' comments from build scripts... but we are forced to push it to lld in order to move on. Repository: rLLD LLVM Linker CHANGES SINCE

[PATCH] D56215: [lld] [ELF] Include default search paths for NetBSD driver

2019-01-03 Thread Kamil Rytarowski via Phabricator via cfe-commits
krytarowski added a comment. It's an option but Joerg insists on using lld standalone. Repository: rLLD LLVM Linker CHANGES SINCE LAST ACTION https://reviews.llvm.org/D56215/new/ https://reviews.llvm.org/D56215 ___ cfe-commits mailing list

  1   2   3   >