Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1304423
| From | Sedat Dilek <sedat.dilek@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: Thoughts about introducing OPTIMIZATION_CFLAG |
| Date | 2016-01-08 12:50 +0100 |
| Message-ID | <qODIm-67Q-19@gated-at.bofh.it> (permalink) |
| References | (1 earlier) <qNbEu-2Rt-23@gated-at.bofh.it> <qNbOa-2VD-1@gated-at.bofh.it> <qNlXd-1bV-47@gated-at.bofh.it> <qOC9A-5eo-11@gated-at.bofh.it> <qODyG-63D-23@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Fri, Jan 8, 2016 at 12:31 PM, Michal Marek <mmarek@suse.cz> wrote: > On 2016-01-08 11:03, Sedat Dilek wrote: >> On Mon, Jan 4, 2016 at 11:37 PM, Michal Marek <mmarek@suse.cz> wrote: >>> Dne 4.1.2016 v 12:47 Sedat Dilek napsal(a): >>>> But I think you did not get my problem - to have two different >>>> optimization-levels for a compiler in *one* make-line makes no sense >>>> to me. >>> >>> That we sometimes have -O2 ... -Os on the command line is not a problem, >>> since any same unix tool parses its options so that the last one of >>> mutually exclusive options wins. >> >> That is new to me and I haven't tested this by dropping arguments in >> my make-line(s). >> >> From where do have this information - sort of "business-life-experience" :-)? >> Is that documented somewhere in the Linux-sources? > > You override a previously set option by appending one with different value: > > $ yes | head -n 10 -n 999 -n 2 > y > y > $ > > This pattern is used all over in Makefiles. > > >> Do you agree that it is confusing to have two optlevel arguments in >> one make-line? > > It probably is, but fixing this problem would make the Makefiles unreadable. > > >> Linus suggested me to use a wrapper-script in case of using two >> different compiler and passing arguments... >> >> [ /usr/bin/mycompiler ] >> #!/bin/bash >> >> gcc-4.9 "$@" >> - EOF - >> >> According to your statement passing an optlevel here in this script >> will never-ever be recognized - as it is at the begin-of-(make)-line. > > Pass it as the last argument. > How do I do that? - Sedat - > >> So how should someone change the Linux-sources to test a different >> optlevel than -O2? > > make KCFLAGS=-O3 > > However, per-directory and per-file cflags set in Makefiles will take > precedence. If you want to override these as well, use the wrapper. > > Michal
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Thoughts about introducing OPTIMIZATION_CFLAG Sedat Dilek <sedat.dilek@gmail.com> - 2016-01-04 12:00 +0100
Re: Thoughts about introducing OPTIMIZATION_CFLAG Sedat Dilek <sedat.dilek@gmail.com> - 2016-01-04 12:30 +0100
Re: Thoughts about introducing OPTIMIZATION_CFLAG One Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk> - 2016-01-04 12:40 +0100
Re: Thoughts about introducing OPTIMIZATION_CFLAG Sedat Dilek <sedat.dilek@gmail.com> - 2016-01-04 12:50 +0100
Re: Thoughts about introducing OPTIMIZATION_CFLAG Michal Marek <mmarek@suse.cz> - 2016-01-04 23:40 +0100
Re: Thoughts about introducing OPTIMIZATION_CFLAG Sedat Dilek <sedat.dilek@gmail.com> - 2016-01-08 11:10 +0100
Re: Thoughts about introducing OPTIMIZATION_CFLAG Michal Marek <mmarek@suse.cz> - 2016-01-08 12:40 +0100
Re: Thoughts about introducing OPTIMIZATION_CFLAG Sedat Dilek <sedat.dilek@gmail.com> - 2016-01-08 12:50 +0100
Re: Thoughts about introducing OPTIMIZATION_CFLAG Michal Marek <mmarek@suse.cz> - 2016-01-08 13:40 +0100
Re: Thoughts about introducing OPTIMIZATION_CFLAG Sedat Dilek <sedat.dilek@gmail.com> - 2016-01-08 14:30 +0100
csiph-web