[PATCH] D64491: [Driver] Enable __cxa_atexit on Solaris
This revision was automatically updated to reflect the committed changes. Closed by commit rL366305: [Driver] Enable __cxa_atexit on Solaris (authored by ro, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.org/D64491?vs=208948=210265#toc Repository: rL LLVM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64491/new/ https://reviews.llvm.org/D64491 Files: cfe/trunk/lib/Driver/ToolChains/Clang.cpp cfe/trunk/test/Driver/cxa-atexit.cpp cfe/trunk/test/Driver/solaris-opts.c Index: cfe/trunk/test/Driver/solaris-opts.c === --- cfe/trunk/test/Driver/solaris-opts.c +++ cfe/trunk/test/Driver/solaris-opts.c @@ -1,4 +1,4 @@ // RUN: %clang %s --target=sparc-sun-solaris2.11 -### -o %t.o 2>&1 | FileCheck %s -// CHECK: "-fno-use-cxa-atexit" +// CHECK-NOT: "-fno-use-cxa-atexit" Index: cfe/trunk/test/Driver/cxa-atexit.cpp === --- cfe/trunk/test/Driver/cxa-atexit.cpp +++ cfe/trunk/test/Driver/cxa-atexit.cpp @@ -19,7 +19,7 @@ // RUN: %clang -### -target sparc-sun-solaris -c %s -o /dev/null 2>&1 | FileCheck %s -check-prefix CHECK-SOLARIS // CHECK-WINDOWS: "-fno-use-cxa-atexit" -// CHECK-SOLARIS: "-fno-use-cxa-atexit" +// CHECK-SOLARIS-NOT: "-fno-use-cxa-atexit" // CHECK-HEXAGON-NOT: "-fno-use-cxa-atexit" // CHECK-XCORE: "-fno-use-cxa-atexit" // CHECK-MTI: "-fno-use-cxa-atexit" Index: cfe/trunk/lib/Driver/ToolChains/Clang.cpp === --- cfe/trunk/lib/Driver/ToolChains/Clang.cpp +++ cfe/trunk/lib/Driver/ToolChains/Clang.cpp @@ -4749,7 +4749,6 @@ if (!Args.hasFlag( options::OPT_fuse_cxa_atexit, options::OPT_fno_use_cxa_atexit, !RawTriple.isOSWindows() && - RawTriple.getOS() != llvm::Triple::Solaris && TC.getArch() != llvm::Triple::xcore && ((RawTriple.getVendor() != llvm::Triple::MipsTechnologies) || RawTriple.hasEnvironment())) || Index: cfe/trunk/test/Driver/solaris-opts.c === --- cfe/trunk/test/Driver/solaris-opts.c +++ cfe/trunk/test/Driver/solaris-opts.c @@ -1,4 +1,4 @@ // RUN: %clang %s --target=sparc-sun-solaris2.11 -### -o %t.o 2>&1 | FileCheck %s -// CHECK: "-fno-use-cxa-atexit" +// CHECK-NOT: "-fno-use-cxa-atexit" Index: cfe/trunk/test/Driver/cxa-atexit.cpp === --- cfe/trunk/test/Driver/cxa-atexit.cpp +++ cfe/trunk/test/Driver/cxa-atexit.cpp @@ -19,7 +19,7 @@ // RUN: %clang -### -target sparc-sun-solaris -c %s -o /dev/null 2>&1 | FileCheck %s -check-prefix CHECK-SOLARIS // CHECK-WINDOWS: "-fno-use-cxa-atexit" -// CHECK-SOLARIS: "-fno-use-cxa-atexit" +// CHECK-SOLARIS-NOT: "-fno-use-cxa-atexit" // CHECK-HEXAGON-NOT: "-fno-use-cxa-atexit" // CHECK-XCORE: "-fno-use-cxa-atexit" // CHECK-MTI: "-fno-use-cxa-atexit" Index: cfe/trunk/lib/Driver/ToolChains/Clang.cpp === --- cfe/trunk/lib/Driver/ToolChains/Clang.cpp +++ cfe/trunk/lib/Driver/ToolChains/Clang.cpp @@ -4749,7 +4749,6 @@ if (!Args.hasFlag( options::OPT_fuse_cxa_atexit, options::OPT_fno_use_cxa_atexit, !RawTriple.isOSWindows() && - RawTriple.getOS() != llvm::Triple::Solaris && TC.getArch() != llvm::Triple::xcore && ((RawTriple.getVendor() != llvm::Triple::MipsTechnologies) || RawTriple.hasEnvironment())) || ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
[PATCH] D64491: [Driver] Enable __cxa_atexit on Solaris
rnk accepted this revision. rnk added a comment. This revision is now accepted and ready to land. lgtm Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64491/new/ https://reviews.llvm.org/D64491 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
[PATCH] D64491: [Driver] Enable __cxa_atexit on Solaris
ro added reviewers: mehdi_amini, rnk. ro added a comment. Ping? It's been a week and the patch seems completely in line with other ELF targets. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D64491/new/ https://reviews.llvm.org/D64491 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
[PATCH] D64491: [Driver] Enable __cxa_atexit on Solaris
ro created this revision. ro added reviewers: fedor.sergeev, rsmith. Herald added subscribers: dexonsmith, mehdi_amini, jyknight. Herald added a project: clang. Starting with Solaris 11.4 (which is now the required minimal version), Solaris does support `__cxa_atexit`. This patch reflects that. One might consider removing the affected tests altogether instead of inverting them, as is done on other targets. Besides, this lets two ASan tests PASS: AddressSanitizer-i386-sunos :: TestCases/init-order-atexit.cc AddressSanitizer-i386-sunos-dynamic :: TestCases/init-order-atexit.cc Tested on `x86_64-pc-solaris2.11` and `sparcv9-sun-solaris2.11`. Ok for trunk? Repository: rC Clang https://reviews.llvm.org/D64491 Files: lib/Driver/ToolChains/Clang.cpp test/Driver/cxa-atexit.cpp test/Driver/solaris-opts.c Index: test/Driver/solaris-opts.c === --- test/Driver/solaris-opts.c +++ test/Driver/solaris-opts.c @@ -1,4 +1,4 @@ // RUN: %clang %s --target=sparc-sun-solaris2.11 -### -o %t.o 2>&1 | FileCheck %s -// CHECK: "-fno-use-cxa-atexit" +// CHECK-NOT: "-fno-use-cxa-atexit" Index: test/Driver/cxa-atexit.cpp === --- test/Driver/cxa-atexit.cpp +++ test/Driver/cxa-atexit.cpp @@ -19,7 +19,7 @@ // RUN: %clang -### -target sparc-sun-solaris -c %s -o /dev/null 2>&1 | FileCheck %s -check-prefix CHECK-SOLARIS // CHECK-WINDOWS: "-fno-use-cxa-atexit" -// CHECK-SOLARIS: "-fno-use-cxa-atexit" +// CHECK-SOLARIS-NOT: "-fno-use-cxa-atexit" // CHECK-HEXAGON-NOT: "-fno-use-cxa-atexit" // CHECK-XCORE: "-fno-use-cxa-atexit" // CHECK-MTI: "-fno-use-cxa-atexit" Index: lib/Driver/ToolChains/Clang.cpp === --- lib/Driver/ToolChains/Clang.cpp +++ lib/Driver/ToolChains/Clang.cpp @@ -4750,7 +4750,6 @@ if (!Args.hasFlag( options::OPT_fuse_cxa_atexit, options::OPT_fno_use_cxa_atexit, !RawTriple.isOSWindows() && - RawTriple.getOS() != llvm::Triple::Solaris && TC.getArch() != llvm::Triple::xcore && ((RawTriple.getVendor() != llvm::Triple::MipsTechnologies) || RawTriple.hasEnvironment())) || Index: test/Driver/solaris-opts.c === --- test/Driver/solaris-opts.c +++ test/Driver/solaris-opts.c @@ -1,4 +1,4 @@ // RUN: %clang %s --target=sparc-sun-solaris2.11 -### -o %t.o 2>&1 | FileCheck %s -// CHECK: "-fno-use-cxa-atexit" +// CHECK-NOT: "-fno-use-cxa-atexit" Index: test/Driver/cxa-atexit.cpp === --- test/Driver/cxa-atexit.cpp +++ test/Driver/cxa-atexit.cpp @@ -19,7 +19,7 @@ // RUN: %clang -### -target sparc-sun-solaris -c %s -o /dev/null 2>&1 | FileCheck %s -check-prefix CHECK-SOLARIS // CHECK-WINDOWS: "-fno-use-cxa-atexit" -// CHECK-SOLARIS: "-fno-use-cxa-atexit" +// CHECK-SOLARIS-NOT: "-fno-use-cxa-atexit" // CHECK-HEXAGON-NOT: "-fno-use-cxa-atexit" // CHECK-XCORE: "-fno-use-cxa-atexit" // CHECK-MTI: "-fno-use-cxa-atexit" Index: lib/Driver/ToolChains/Clang.cpp === --- lib/Driver/ToolChains/Clang.cpp +++ lib/Driver/ToolChains/Clang.cpp @@ -4750,7 +4750,6 @@ if (!Args.hasFlag( options::OPT_fuse_cxa_atexit, options::OPT_fno_use_cxa_atexit, !RawTriple.isOSWindows() && - RawTriple.getOS() != llvm::Triple::Solaris && TC.getArch() != llvm::Triple::xcore && ((RawTriple.getVendor() != llvm::Triple::MipsTechnologies) || RawTriple.hasEnvironment())) || ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits