syzaara created this revision. Add clang option -msave-toc-indirect for PowerPC.
https://reviews.llvm.org/D39376 Files: include/clang/Driver/Options.td test/Driver/ppc-features.cpp Index: test/Driver/ppc-features.cpp =================================================================== --- test/Driver/ppc-features.cpp +++ test/Driver/ppc-features.cpp @@ -134,6 +134,9 @@ // RUN: %clang -target powerpc64-unknown-linux-gnu %s -mno-vsx -mvsx -### -o %t.o 2>&1 | FileCheck -check-prefix=CHECK-VSX %s // CHECK-VSX: "-target-feature" "+vsx" +// RUN: %clang -target powerpc64-unknown-linux-gnu %s -msave-toc-indirect -### -o %t.o 2>&1 | FileCheck -check-prefix=CHECK-TOC %s +// CHECK-TOC: "-target-feature" "+save-toc-indirect" + // RUN: %clang -target powerpc64-unknown-linux-gnu %s -mno-htm -### -o %t.o 2>&1 | FileCheck -check-prefix=CHECK-NOHTM %s // CHECK-NOHTM: "-target-feature" "-htm" Index: include/clang/Driver/Options.td =================================================================== --- include/clang/Driver/Options.td +++ include/clang/Driver/Options.td @@ -1904,6 +1904,7 @@ def maltivec : Flag<["-"], "maltivec">, Group<m_ppc_Features_Group>; def mno_altivec : Flag<["-"], "mno-altivec">, Group<m_ppc_Features_Group>; def mvsx : Flag<["-"], "mvsx">, Group<m_ppc_Features_Group>; +def msave_toc_indirect : Flag<["-"], "msave-toc-indirect">, Group<m_ppc_Features_Group>; def mno_vsx : Flag<["-"], "mno-vsx">, Group<m_ppc_Features_Group>; def mpower8_vector : Flag<["-"], "mpower8-vector">, Group<m_ppc_Features_Group>;
Index: test/Driver/ppc-features.cpp =================================================================== --- test/Driver/ppc-features.cpp +++ test/Driver/ppc-features.cpp @@ -134,6 +134,9 @@ // RUN: %clang -target powerpc64-unknown-linux-gnu %s -mno-vsx -mvsx -### -o %t.o 2>&1 | FileCheck -check-prefix=CHECK-VSX %s // CHECK-VSX: "-target-feature" "+vsx" +// RUN: %clang -target powerpc64-unknown-linux-gnu %s -msave-toc-indirect -### -o %t.o 2>&1 | FileCheck -check-prefix=CHECK-TOC %s +// CHECK-TOC: "-target-feature" "+save-toc-indirect" + // RUN: %clang -target powerpc64-unknown-linux-gnu %s -mno-htm -### -o %t.o 2>&1 | FileCheck -check-prefix=CHECK-NOHTM %s // CHECK-NOHTM: "-target-feature" "-htm" Index: include/clang/Driver/Options.td =================================================================== --- include/clang/Driver/Options.td +++ include/clang/Driver/Options.td @@ -1904,6 +1904,7 @@ def maltivec : Flag<["-"], "maltivec">, Group<m_ppc_Features_Group>; def mno_altivec : Flag<["-"], "mno-altivec">, Group<m_ppc_Features_Group>; def mvsx : Flag<["-"], "mvsx">, Group<m_ppc_Features_Group>; +def msave_toc_indirect : Flag<["-"], "msave-toc-indirect">, Group<m_ppc_Features_Group>; def mno_vsx : Flag<["-"], "mno-vsx">, Group<m_ppc_Features_Group>; def mpower8_vector : Flag<["-"], "mpower8-vector">, Group<m_ppc_Features_Group>;
_______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits