Index: clang/CMakeLists.txt =================================================================== --- clang/CMakeLists.txt +++ clang/CMakeLists.txt @@ -189,17 +189,6 @@ option(CLANG_DEFAULT_PIE_ON_LINUX "Default to -fPIE and -pie on linux-gnu" ON) -# Manually handle default so we can change the meaning of a cached default. -set(CLANG_ENABLE_OPAQUE_POINTERS "DEFAULT" CACHE STRING - "Enable opaque pointers by default") -if(CLANG_ENABLE_OPAQUE_POINTERS STREQUAL "DEFAULT") - set(CLANG_ENABLE_OPAQUE_POINTERS_INTERNAL ON) -elseif(CLANG_ENABLE_OPAQUE_POINTERS) - set(CLANG_ENABLE_OPAQUE_POINTERS_INTERNAL ON) -else() - set(CLANG_ENABLE_OPAQUE_POINTERS_INTERNAL OFF) -endif() - # TODO: verify the values against LangStandards.def? set(CLANG_DEFAULT_STD_C "" CACHE STRING "Default standard to use for C/ObjC code (IDENT from LangStandards.def, empty for platform default)") Index: clang/include/clang/Config/config.h.cmake =================================================================== --- clang/include/clang/Config/config.h.cmake +++ clang/include/clang/Config/config.h.cmake @@ -101,7 +101,4 @@ /* Spawn a new process clang.exe for the CC1 tool invocation, when necessary */ #cmakedefine01 CLANG_SPAWN_CC1 -/* Whether to enable opaque pointers by default */ -#cmakedefine01 CLANG_ENABLE_OPAQUE_POINTERS_INTERNAL - #endif Index: clang/lib/Driver/ToolChains/Clang.cpp =================================================================== --- clang/lib/Driver/ToolChains/Clang.cpp +++ clang/lib/Driver/ToolChains/Clang.cpp @@ -6697,9 +6697,6 @@ false)) CmdArgs.push_back("-fmodules-debuginfo"); - if (!CLANG_ENABLE_OPAQUE_POINTERS_INTERNAL) - CmdArgs.push_back("-no-opaque-pointers"); - ObjCRuntime Runtime = AddObjCRuntimeArgs(Args, Inputs, CmdArgs, rewriteKind); RenderObjCOptions(TC, D, RawTriple, Args, Runtime, rewriteKind != RK_None, Input, CmdArgs); Index: clang/lib/Driver/ToolChains/CommonArgs.cpp =================================================================== --- clang/lib/Driver/ToolChains/CommonArgs.cpp +++ clang/lib/Driver/ToolChains/CommonArgs.cpp @@ -558,9 +558,6 @@ CmdArgs.push_back( Args.MakeArgString("-plugin-opt=jobs=" + Twine(Parallelism))); - if (!CLANG_ENABLE_OPAQUE_POINTERS_INTERNAL) - CmdArgs.push_back(Args.MakeArgString("-plugin-opt=no-opaque-pointers")); - // If an explicit debugger tuning argument appeared, pass it along. if (Arg *A = Args.getLastArg(options::OPT_gTune_Group, options::OPT_ggdbN_Group)) { Index: clang/test/CMakeLists.txt =================================================================== --- clang/test/CMakeLists.txt +++ clang/test/CMakeLists.txt @@ -5,7 +5,6 @@ CLANG_BUILD_EXAMPLES CLANG_BUILT_STANDALONE CLANG_DEFAULT_PIE_ON_LINUX - CLANG_ENABLE_OPAQUE_POINTERS_INTERNAL CLANG_ENABLE_ARCMT CLANG_ENABLE_STATIC_ANALYZER CLANG_PLUGIN_SUPPORT Index: clang/test/Driver/lto-no-opaque-pointers.c =================================================================== --- clang/test/Driver/lto-no-opaque-pointers.c +++ /dev/null @@ -1,5 +0,0 @@ -// UNSUPPORTED: enable-opaque-pointers -// RUN: %clang --target=x86_64-unknown-linux -### %s -flto 2> %t -// RUN: FileCheck %s < %t - -// CHECK: -plugin-opt=no-opaque-pointers Index: clang/test/Driver/lto-opaque-pointers.c =================================================================== --- clang/test/Driver/lto-opaque-pointers.c +++ /dev/null @@ -1,5 +0,0 @@ -// REQUIRES: enable-opaque-pointers -// RUN: %clang --target=x86_64-unknown-linux -### %s -flto 2> %t -// RUN: FileCheck %s < %t - -// CHECK-NOT: -plugin-opt=no-opaque-pointers Index: clang/test/Driver/opaque-pointers-off.c =================================================================== --- clang/test/Driver/opaque-pointers-off.c +++ /dev/null @@ -1,11 +0,0 @@ -// UNSUPPORTED: enable-opaque-pointers -/// Test -DCLANG_ENABLE_OPAQUE_POINTERS=OFF. - -// RUN: %clang -### --target=aarch64-linux-gnu %s 2>&1 | FileCheck %s -/// User -Xclang -opaque-pointers overrides the default. -// RUN: %clang -### --target=aarch64-linux-gnu -Xclang -opaque-pointers %s 2>&1 | FileCheck %s --check-prefix=CHECK2 - -// CHECK: "-no-opaque-pointers" - -// CHECK2: "-no-opaque-pointers" -// CHECK2-SAME: "-opaque-pointers" Index: clang/test/lit.cfg.py =================================================================== --- clang/test/lit.cfg.py +++ clang/test/lit.cfg.py @@ -126,9 +126,6 @@ if config.clang_default_pie_on_linux: config.available_features.add('default-pie-on-linux') -if config.clang_enable_opaque_pointers: - config.available_features.add('enable-opaque-pointers') - if config.clang_default_std_cxx != '': config.available_features.add('default-std-cxx') Index: clang/test/lit.site.cfg.py.in =================================================================== --- clang/test/lit.site.cfg.py.in +++ clang/test/lit.site.cfg.py.in @@ -24,7 +24,6 @@ config.have_zstd = @LLVM_ENABLE_ZSTD@ config.clang_arcmt = @CLANG_ENABLE_ARCMT@ config.clang_default_pie_on_linux = @CLANG_DEFAULT_PIE_ON_LINUX@ -config.clang_enable_opaque_pointers = @CLANG_ENABLE_OPAQUE_POINTERS_INTERNAL@ config.clang_default_std_cxx = "@CLANG_DEFAULT_STD_CXX@" config.clang_default_cxx_stdlib = "@CLANG_DEFAULT_CXX_STDLIB@" config.clang_staticanalyzer = @CLANG_ENABLE_STATIC_ANALYZER@