User forums > General (but related to Code::Blocks)
why is the result different in debug and release mode?
facat:
in addition,i uesed STL in my program. is there any posibility that STL has something to do my my strang program.
stahta01:
--- Quote from: facat on April 16, 2011, 02:33:28 am ---
--- Quote from: stahta01 on April 16, 2011, 02:25:29 am ---Do NOT try to add MSVC Libraries to your MinGW Debug Build.
--- End quote ---
i didn't use MSVC lib. by the way, my program is normal either in debug or release within VS2005.
--- End quote ---
Then why did you do so in the zipped project file.
Edit: If you do not believe me; just turn on Full Compiler Logging and look at the g++ linker command and you will see the .lib file trying to be linked on debug build.
http://wiki.codeblocks.org/index.php?title=FAQ#Q:_How_do_I_troubleshoot_an_compiler_problem.3F
Tim S.
huzhongshan:
maybe you have to check intermediate result of your function and compare it with correct one to find what cause the difference.
facat:
--- Quote from: stahta01 on April 16, 2011, 04:51:15 am ---
--- Quote from: facat on April 16, 2011, 02:33:28 am ---
--- Quote from: stahta01 on April 16, 2011, 02:25:29 am ---Do NOT try to add MSVC Libraries to your MinGW Debug Build.
--- End quote ---
i didn't use MSVC lib. by the way, my program is normal either in debug or release within VS2005.
--- End quote ---
Then why did you do so in the zipped project file.
Edit: If you do not believe me; just turn on Full Compiler Logging and look at the g++ linker command and you will see the .lib file trying to be linked on debug build.
http://wiki.codeblocks.org/index.php?title=FAQ#Q:_How_do_I_troubleshoot_an_compiler_problem.3F
Tim S.
--- End quote ---
i removed that lib from my project,but the result is still wrong. I tried to change my template argument from double to long double ,this time result is right.
facat:
does debug and release have different float precision?
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version