summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJussi Pakkanen <jpakkane@gmail.com>2021-03-10 21:41:15 +0200
committerJussi Pakkanen <jpakkane@gmail.com>2021-03-23 17:26:08 +0200
commit9ab4dadef99cacb6a556154b7f520afba0877dc4 (patch)
treeeebee3b11ea28dc2b69764c0cf4ff09e9658a9cd
parentea48edbb0fcd567b26d94e27b9b61612f56728f5 (diff)
downloadmeson-9ab4dadef99cacb6a556154b7f520afba0877dc4.tar.gz
Remove -pipe from default list of args. Closes #8508.
-rw-r--r--docs/markdown/snippets/nopipe.md10
-rw-r--r--mesonbuild/compilers/fortran.py6
-rw-r--r--mesonbuild/compilers/mixins/clike.py2
-rw-r--r--mesonbuild/interpreter.py3
4 files changed, 11 insertions, 10 deletions
diff --git a/docs/markdown/snippets/nopipe.md b/docs/markdown/snippets/nopipe.md
new file mode 100644
index 000000000..431205bcf
--- /dev/null
+++ b/docs/markdown/snippets/nopipe.md
@@ -0,0 +1,10 @@
+## `-pipe` no longer used by default
+
+Meson used to add the `-pipe` command line argument to all compilers
+that supported it, but no longer does. If you need this, then you can
+add it manually. However note that you should not do this unless you
+have actually measured that it provides performance improvements. In
+our tests we could not find a case where adding `-pipe` made
+compilation faster and using `-pipe` [can cause sporadic build
+failures in certain
+cases](https://github.com/mesonbuild/meson/issues/8508).
diff --git a/mesonbuild/compilers/fortran.py b/mesonbuild/compilers/fortran.py
index 0cff60a64..826463865 100644
--- a/mesonbuild/compilers/fortran.py
+++ b/mesonbuild/compilers/fortran.py
@@ -336,12 +336,6 @@ class IntelFortranCompiler(IntelGnuLikeCompiler, FortranCompiler):
def get_preprocess_only_args(self) -> T.List[str]:
return ['-cpp', '-EP']
- def get_always_args(self) -> T.List[str]:
- """Ifort doesn't have -pipe."""
- val = super().get_always_args()
- val.remove('-pipe')
- return val
-
def language_stdlib_only_link_flags(self) -> T.List[str]:
return ['-lifcore', '-limf']
diff --git a/mesonbuild/compilers/mixins/clike.py b/mesonbuild/compilers/mixins/clike.py
index 3932244f2..70dde6042 100644
--- a/mesonbuild/compilers/mixins/clike.py
+++ b/mesonbuild/compilers/mixins/clike.py
@@ -155,7 +155,7 @@ class CLikeCompiler(Compiler):
'''
Args that are always-on for all C compilers other than MSVC
'''
- return ['-pipe'] + self.get_largefile_args()
+ return self.get_largefile_args()
def get_no_stdinc_args(self) -> T.List[str]:
return ['-nostdinc']
diff --git a/mesonbuild/interpreter.py b/mesonbuild/interpreter.py
index 5cf3dde9a..812f7bd1c 100644
--- a/mesonbuild/interpreter.py
+++ b/mesonbuild/interpreter.py
@@ -4716,9 +4716,6 @@ This warning will become a hard error in a future Meson release.
elif arg == '-g':
mlog.warning(f'Consider using the built-in debug option instead of using "{arg}".',
location=self.current_node)
- elif arg == '-pipe':
- mlog.warning("You don't need to add -pipe, Meson will use it automatically when it is available.",
- location=self.current_node)
elif arg.startswith('-fsanitize'):
mlog.warning(f'Consider using the built-in option for sanitizers instead of using "{arg}".',
location=self.current_node)