On 3/19/2012 00:57, Davidson, Josh wrote:
> Kai,
> 
> Everything you said about the code is correct.  It's a simple 10 line hack to 
> demonstrate the problem that in no way resembles any production code I have 
> that is currently failing.  If it is working properly, the exit value should 
> be 183.  So your toolchain does not exhibit the problem I'm describing.  Yes, 
> any (system error code % 256) == 183 would be a false positive.  I'm also not 
> assuming that GetLastError doesn't return 0.  It should return 183 
> (ERROR_ALREADY_EXISTS).  In an effort to make the example as concise as 
> possible, I removed the print statements (although I now see I failed to 
> remove the #includes) and just used the value as the exit value.  The issue 
> is that mingw-w64 (or at least Ruben's latest build of it), clears the system 
> error code while unwinding the stack.
> 
> What host are you running on and is your gcc configured with win32 or the 
> posix thread api?   These are the settings for my current toolchain that 
> fails under 32-bit Windows XP:
> C:\Temp>c:\MinGW.ruben\bin\gcc -v
> Using built-in specs.
> COLLECT_GCC=c:\MinGW.ruben\bin\gcc
> COLLECT_LTO_WRAPPER=c:/mingw.ruben/bin/../libexec/gcc/i686-w64-mingw32/4.7.0/lto-wrapper.exe
> Target: i686-w64-mingw32
> Configured with: /home/ruben/mingw-w64/toolchain/src/gcc/configure 
> --host=i686-w64-mingw32 --build=x86_64-linux-gnu --target=i686-w64-mingw32 
> --with-sysr
> oot=/home/ruben/mingw-w64/toolchain/mingw32mingw32/mingw32 
> --prefix=/home/ruben/mingw-w64/toolchain/mingw32mingw32/mingw32 
> --with-libiconv-prefix=/home/r
> uben/mingw-w64/toolchain/mingw32mingw32/prereq_install 
> --with-gmp=/home/ruben/mingw-w64/toolchain/mingw32mingw32/prereq_install 
> --with-mpfr=/home/ruben/m
> ingw-w64/toolchain/mingw32mingw32/prereq_install 
> --with-mpc=/home/ruben/mingw-w64/toolchain/mingw32mingw32/prereq_install 
> --with-ppl=/home/ruben/mingw-w6
> 4/toolchain/mingw32mingw32/prereq_install 
> --with-cloog=/home/ruben/mingw-w64/toolchain/mingw32mingw32/prereq_install 
> --enable-cloog-backend=isl --with-ho
> st-libstdcxx='-static -lstdc++ -lm' --enable-shared --enable-static 
> --enable-threads=posix --disable-multilib 
> --enable-languages=c,lto,c++,objc,obj-c++,f
> ortran,java --enable-libgomp --enable-libstdcxx-debug 
> --enable-sjlj-exceptions --enable-fully-dynamic-string --disable-nls 
> --disable-werror --enable-chec
> king=release --disable-win32-registry --disable-rpath --disable-werror 
> CFLAGS='-O2 -mtune=corei7 -fomit-frame-pointer -momit-leaf-frame-pointer 
> -fgraphit
> e-identity -floop-interchange -floop-block -floop-parallelize-all' LDFLAGS=
> Thread model: posix
> gcc version 4.7.0 20120311 (prerelease) (GCC) 
> 
> The only thing that stands out to me is maybe the enabled extensions for 
> using the POSIX thread model has something to do with it.  Previously, I've 
> only used builds that use the win32 thread model.
> 
>

Note --enable-threads=posix, so yes, its POSIX thread. Its mainly to
support C++11 threads.


Attachment: signature.asc
Description: OpenPGP digital signature

------------------------------------------------------------------------------
This SF email is sponsosred by:
Try Windows Azure free for 90 days Click Here 
http://p.sf.net/sfu/sfd2d-msazure
_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to