On 29/02/16 06:54, Olaf Hering wrote: > On Sun, Feb 28, Wei Liu wrote: > >> If the current set of compiler flags is not good enough, we should >> improve it. I'm afraid having a third set of maintainer mode flags that >> nobody else uses is going to cause us more headache. > There is nothing wrong with the CFLAGS. They are perfect for developers. > But the commiters hopefully do some sort of compile test before doing a > push. And this compile test must include -O2 to enable enough > diagnostic to catch developer errors.
gcc -O1 -fno-omit-frame-pointer -m64 -g -fno-strict-aliasing -std=gnu99 -Wall -Wstrict-prototypes -Wdeclaration-after-statement -Wno-unused-but-set-variable -Wno-unused-local-typedefs -O0 -g3 -D__XEN_INTERFACE_VERSION__=__XEN_LATEST_INTERFACE_VERSION__ -MMD -MF .libxl_dom_save.o.d -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -fno-optimize-sibling-calls -fmessage-length=0 -grecord-gcc-switches -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -g -Werror -Wno-format-zero-length -Wmissing-declarations -Wno-declaration-after-statement -Wformat-nonliteral -I. -fPIC -pthread This set of options is very messy. We have both an -O1, an -O0 and an -O2, as well as three different -g's Frankly, at no point ever should -O0 be used, even for debugging. -Og if available or -O1 if not. In this case, the -O2, being latest, should take priority. However, it would be useful to identify which flags are coming from where, and see if we usefully reduce them. ~Andrew _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel