Archives
D Programming
DD.gnu digitalmars.D digitalmars.D.bugs digitalmars.D.dtl digitalmars.D.dwt digitalmars.D.announce digitalmars.D.learn digitalmars.D.debugger C/C++ Programming
c++c++.announce c++.atl c++.beta c++.chat c++.command-line c++.dos c++.dos.16-bits c++.dos.32-bits c++.idde c++.mfc c++.rtl c++.stl c++.stl.hp c++.stl.port c++.stl.sgi c++.stlsoft c++.windows c++.windows.16-bits c++.windows.32-bits c++.wxwindows digitalmars.empire digitalmars.DMDScript |
c++ - [bug?] compiler option -a4 causes abnormal program termination on
Walter, A bit of my code recently started causing grief. The minimum reproduction I eventually whittled it down to looks like this: #include <sstream> void f() { std::stringstream str; } #include <iostream> int main () { return 0; } If you compile this with 'dmc test.cpp', all is well. Compile it with 'dmc test.cpp -a4' and you get abnormal program terminations. The additional plethora of command line options I normally have make no difference, the alignment option is the culprit it seems. I hadn't compiled this code a while and am not sure when it last worked (or even if the -a4 was recently added in my makefiles), but I am currently updated to the latest beta (8.49). I don't particularly require struct alignment, so for me its just removing -a4 and I'm okay for now. Kind regards, Anton Sekeris. Jun 02 2006
Anton Sekeris wrote:Walter, A bit of my code recently started causing grief. The minimum reproduction I eventually whittled it down to looks like this: #include <sstream> void f() { std::stringstream str; } #include <iostream> int main () { return 0; } If you compile this with 'dmc test.cpp', all is well. Compile it with 'dmc test.cpp -a4' and you get abnormal program terminations. The additional plethora of command line options I normally have make no difference, the alignment option is the culprit it seems. I hadn't compiled this code a while and am not sure when it last worked (or even if the -a4 was recently added in my makefiles), but I am currently updated to the latest beta (8.49). I don't particularly require struct alignment, so for me its just removing -a4 and I'm okay for now. Jun 02 2006
Walter Bright wrote:Anton Sekeris wrote:Walter, A bit of my code recently started causing grief. The minimum reproduction I eventually whittled it down to looks like this: #include <sstream> void f() { std::stringstream str; } #include <iostream> int main () { return 0; } If you compile this with 'dmc test.cpp', all is well. Compile it with 'dmc test.cpp -a4' and you get abnormal program terminations. The additional plethora of command line options I normally have make no difference, the alignment option is the culprit it seems. I hadn't compiled this code a while and am not sure when it last worked (or even if the -a4 was recently added in my makefiles), but I am currently updated to the latest beta (8.49). I don't particularly require struct alignment, so for me its just removing -a4 and I'm okay for now. Jun 03 2006
Anton Sekeris wrote:Noted, the -a switch is out the window here, thanks. I figured out where something went wrong though. Some of our makefiles were generated by ultraedit/uemake. We recently switched to uestudio. Both applications support sc/dmc, which is cool. It seems uestudio by defaults adds a -a directive to the makefiles. I'll let the author of that program know that he may need to do something with this. Jun 03 2006
|