SIGABRT when running tests
benwad opened this issue · comments
Ben Wadsworth commented
When running standard tests (passed in the path of the test folder to main) I get a SIGABRT on line 130 of typeSamplers.cpp, and can't work out why. Changing assignment to another string gives the same result. Here is the stack trace:
* thread #1: tid = 0x2303, 0x94e8ea6a libsystem_kernel.dylib`__pthread_kill + 10, stop reason = signal SIGABRT
frame #0: 0x94e8ea6a libsystem_kernel.dylib`__pthread_kill + 10
frame #1: 0x91b6eacf libsystem_c.dylib`pthread_kill + 101
frame #2: 0x91ba54f8 libsystem_c.dylib`abort + 168
frame #3: 0x91b87da3 libsystem_c.dylib`free + 428
frame #4: 0x91231826 libstdc++.6.dylib`std::string::_M_mutate(unsigned long, unsigned long, unsigned long) + 244
frame #5: 0x912324e3 libstdc++.6.dylib`std::string::_M_replace_safe(unsigned long, unsigned long, char const*, unsigned long) + 41
frame #6: 0x91232452 libstdc++.6.dylib`std::string::assign(char const*, unsigned long) + 86
frame #7: 0x91231ca7 libstdc++.6.dylib`std::string::operator=(char const*) + 37
frame #8: 0x00081caf hlsl2glsltest`TSamplerTraverser::traverseAggregate(bool, TIntermAggregate*, TIntermTraverser*) + 287 at typeSamplers.cpp:130
frame #9: 0x0006a9cf hlsl2glsltest`TIntermAggregate::traverse(TIntermTraverser*) + 95 at IntermTraverse.cpp:111
frame #10: 0x0006aa60 hlsl2glsltest`TIntermAggregate::traverse(TIntermTraverser*) + 240 at IntermTraverse.cpp:119
frame #11: 0x00082deb hlsl2glsltest`PropagateSamplerTypes(TIntermNode*, TInfoSink&) + 59 at typeSamplers.cpp:432
frame #12: 0x0003df63 hlsl2glsltest`HlslCrossCompiler::TransformAST(TIntermNode*) + 51 at hlslCrossCompiler.cpp:39
frame #13: 0x00028f6b hlsl2glsltest`Hlsl2Glsl_Parse + 651 at HLSL2GLSL.cpp:277
frame #14: 0x00002dd7 hlsl2glsltest`TestFile + 311 at hlsl2glsltest.cpp:386
frame #15: 0x00002801 hlsl2glsltest`TestFile + 417 at hlsl2glsltest.cpp:555
frame #16: 0x00001dc4 hlsl2glsltest`main + 1092 at hlsl2glsltest.cpp:617
frame #17: 0x93486725 libdyld.dylib`start + 1
System info:
Xcode 4.5.2
Mac OS 10.8.2 (Mountain Lion)
LLVM/Clang compiler
Aras Pranckevičius commented
Looks like the project files had some preprocessor macros defined that were causing havoc with the more recent STL in Xcode 4.5. I did some cleanups of the project files, and as of commit 6e7b8cd the crash seems to be gone with Xcode 4.5.