From: Jeffrey W. <nol...@gm...> - 2018-05-20 18:49:30
Attachments:
config.log.tar.gz
|
I'm working on Fedora 27 x86_64 from Master trying to sidestep https://bugs.kde.org/show_bug.cgi?id=387773. I configured Valgrind with the following: PKGCONFIG: /usr/local/lib64/pkgconfig CPPFLAGS: -I/usr/local/include -DNDEBUG CFLAGS: -g2 -O2 -m64 -march=native -fPIC CXXFLAGS: -g2 -O2 -m64 -march=native -fPIC LDFLAGS: -L/usr/local/lib64 -m64 -Wl,-R,/usr/local/lib64 -Wl,--enable-new-dtags LDLIBS: -ldl -lpthread Make'ing results in: $ make ... gcc -DHAVE_CONFIG_H -I. -I.. -I.. -I../include -I../include -I../VEX/pub -I../VEX/pub -DVGA_x86=1 -DVGO_linux=1 -DVGP_x86_linux=1 -DVGPV_x86_linux_vanilla=1 -Ipriv -I/usr/local/include -DNDEBUG -m32 -mpreferred-stack-boundary=2 -O2 -finline-functions -g -Wall -Wmissing-prototypes -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-declarations -Wcast-align -Wcast-qual -Wwrite-strings -Wempty-body -Wformat -Wformat-security -Wignored-qualifiers -Wmissing-parameter-type -Wlogical-op -Wold-style-declaration -fno-stack-protector -fno-strict-aliasing -fno-builtin -fomit-frame-pointer -Wbad-function-cast -fstrict-aliasing -g2 -O2 -m64 -march=native -fPIC -MT priv/libvex_x86_linux_a-main_main.o -MD -MP -MF priv/.deps/libvex_x86_linux_a-main_main.Tpo -c -o priv/libvex_x86_linux_a-main_main.o `test -f 'priv/main_main.c' || echo './'`priv/main_main.c cc1: error: -mpreferred-stack-boundary=2 is not between 3 and 12 gmake[3]: *** [Makefile:1907: priv/libvex_x86_linux_a-main_globals.o] Error 1 gmake[3]: *** Waiting for unfinished jobs.... cc1: error: -mpreferred-stack-boundary=2 is not between 3 and 12 gmake[3]: *** [Makefile:1921: priv/libvex_x86_linux_a-main_main.o] Error 1 mv -f priv/.deps/libvex_amd64_linux_a-host_mips_isel.Tpo priv/.deps/libvex_amd64_linux_a-host_mips_isel.Po Should we specify -mpreferred-stack-boundary=3 as additional CFLAGS and CXXFLAGS? Or maybe something else? Would you like it added to the bug reporter? Config log is attached. Jeff |
From: John R. <jr...@bi...> - 2018-05-20 21:27:29
|
On 05/20/2018 11:49 AM, Jeffrey Walton wrote: > I'm working on Fedora 27 x86_64 from Master trying to sidestep > https://bugs.kde.org/show_bug.cgi?id=387773. > > I configured Valgrind with the following: > > PKGCONFIG: /usr/local/lib64/pkgconfig > CPPFLAGS: -I/usr/local/include -DNDEBUG > CFLAGS: -g2 -O2 -m64 -march=native -fPIC > CXXFLAGS: -g2 -O2 -m64 -march=native -fPIC > LDFLAGS: -L/usr/local/lib64 -m64 -Wl,-R,/usr/local/lib64 > -Wl,--enable-new-dtags > LDLIBS: -ldl -lpthread > > Make'ing results in: > > $ make > ... > > gcc ... -m32 ... 'priv/main_main.c' ... > cc1: error: -mpreferred-stack-boundary=2 is not between 3 and 12 This is peculiar: "I am working on ... x86_64" but invoking "gcc -m32" which requests "generate code for i686". Also, if the value is not at least 4 then some generated SSE instructions (even on i686) will fault because they demand 16-byte alignment, and any call involving a variable number of arguments which includes any argument that requires 16-byte alignment will generate incorrect code. The best strategy is to omit "-mpreferred-stack-boudnary" entirely. |
From: Philippe W. <phi...@sk...> - 2018-05-20 21:43:04
|
On Sun, 2018-05-20 at 14:49 -0400, Jeffrey Walton wrote: > I'm working on Fedora 27 x86_64 from Master trying to sidestep > https://bugs.kde.org/show_bug.cgi?id=387773. > > I configured Valgrind with the following: > > PKGCONFIG: /usr/local/lib64/pkgconfig > CPPFLAGS: -I/usr/local/include -DNDEBUG > CFLAGS: -g2 -O2 -m64 -march=native -fPIC > CXXFLAGS: -g2 -O2 -m64 -march=native -fPIC > LDFLAGS: -L/usr/local/lib64 -m64 -Wl,-R,/usr/local/lib64 > -Wl,--enable-new-dtags > LDLIBS: -ldl -lpthread Not too sure what you did/how you obtained the above. The valgrind configure machinery is very special. Unless you dig into the deep gory details of this machinery, you should not try to set any variable yourself. In particular, on dual arch systems (32 and 64 bits), changing CFLAGS like the above are very likely to give problems. Also, the valgrind core/tools cannot be linked with any library, so it is unclear why LDLIBS is set above. I suggest to start with a very basic configure, e.g. ./configure --prefix=<somewhere> and if that works, then that is a good start :). If after that, you have problems, you might try to solve them by playing with configure setup/args/env var, but that is very fragile. Philippe |
From: Mark W. <ma...@kl...> - 2018-05-20 21:50:52
|
On Sun, May 20, 2018 at 02:49:21PM -0400, Jeffrey Walton wrote: > I'm working on Fedora 27 x86_64 from Master trying to sidestep > https://bugs.kde.org/show_bug.cgi?id=387773. Fixes for that bug should already be in the Fedora 27 valgrind package. What issues are you seeing? Are you using the latest valgrind rpm version? Cheers, Mark |
From: Jeffrey W. <nol...@gm...> - 2018-05-20 22:41:41
|
On Sun, May 20, 2018 at 5:50 PM, Mark Wielaard <ma...@kl...> wrote: > On Sun, May 20, 2018 at 02:49:21PM -0400, Jeffrey Walton wrote: >> I'm working on Fedora 27 x86_64 from Master trying to sidestep >> https://bugs.kde.org/show_bug.cgi?id=387773. > > Fixes for that bug should already be in the Fedora 27 valgrind package. > What issues are you seeing? Are you using the latest valgrind rpm > version? -march=native and additional VEX codes pretty much ensures we have to work from Master. (I tried to get Fedora to pickup some VEX codes that were added after a release but they declined). Jeff |
From: Tom H. <to...@co...> - 2018-05-20 22:01:11
|
On 20/05/18 21:15, John Reiser wrote: > This is peculiar: "I am working on ... x86_64" but invoking "gcc -m32" > which requests "generate code for i686". > Also, if the value is not at least 4 then some generated SSE instructions > (even on i686) will fault because they demand 16-byte alignment, > and any call involving a variable number of arguments which includes > any argument that requires 16-byte alignment will generate incorrect code. > The best strategy is to omit "-mpreferred-stack-boudnary" entirely. It's not peculiar really - by default when building on x86_64 valgrind will try and build both the x86 and x86_64 backends. Use --enable-only64bit to configure if you want to stop it trying to build the 32 bit backend. Tom -- Tom Hughes (to...@co...) http://compton.nu/ |
From: Jeffrey W. <nol...@gm...> - 2018-05-20 22:39:53
|
On Sun, May 20, 2018 at 5:42 PM, Tom Hughes <to...@co...> wrote: > On 20/05/18 21:15, John Reiser wrote: > >> This is peculiar: "I am working on ... x86_64" but invoking "gcc -m32" >> which requests "generate code for i686". >> Also, if the value is not at least 4 then some generated SSE instructions >> (even on i686) will fault because they demand 16-byte alignment, >> and any call involving a variable number of arguments which includes >> any argument that requires 16-byte alignment will generate incorrect code. >> The best strategy is to omit "-mpreferred-stack-boudnary" entirely. > > > It's not peculiar really - by default when building on x86_64 valgrind > will try and build both the x86 and x86_64 backends. > > Use --enable-only64bit to configure if you want to stop it trying to > build the 32 bit backend. Oh, thanks. I did not look at the configuration options closely enough. Sorry about the extra noise. |