Re: [Flightgear-devel] Failed assertion in ssg.h
Curtis L. Olson wrote: Geoff Reidy writes: I still have the fgfs: ssg.h:302: void ssgBase::deRef(): Assertion `refc 0' failed. error with the random-objects disabled, just tried with current cvs. Happens after about the same distance as with them enabled. Strange, after many long flights ( 3500 nm) I have yet to see a crash with --disable-random-objects Regards, Curt. Curt, don't know if you're still watching this thread :) Just wanted to let you know that fg runs forever now if I compile single threaded, even with random objects enabled. Can't remember if I tried this earlier. Still seg faults if compiled multi threaded but no matter. Happy now :) Projects going great, thanks for your efforts. Regards, Geoff ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
Re: [Flightgear-devel] Failed assertion in ssg.h
Geoff Reidy writes: I still have the fgfs: ssg.h:302: void ssgBase::deRef(): Assertion `refc 0' failed. error with the random-objects disabled, just tried with current cvs. Happens after about the same distance as with them enabled. Strange, after many long flights ( 3500 nm) I have yet to see a crash with --disable-random-objects Regards, Curt. -- Curtis Olson IVLab / HumanFIRST Program FlightGear Project Twin Cities[EMAIL PROTECTED] [EMAIL PROTECTED] Minnesota http://www.menet.umn.edu/~curt http://www.flightgear.org ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
Re: [Flightgear-devel] Failed assertion in ssg.h
Curtis L. Olson wrote: Geoff, I did some testing at home this weekend and I think there is something going on here related to the random ground cover objects. If I run with --disable-random-objects I have never seen a crash. If I run with the random objects I do see a similar crash after flying 3000 miles give or take a couple thousand. So I will say the following: For long haul flights, consider running without random objects. Random objects have a couple issues: - program crash after a few thousand miles. (To be fair, this may not directly be the random object code's fault. It could be an interaction issue with other portions of the program?) - issues with freeing tiles ... this can lead to substantially reduced frame rates while the system is struggling to free memory associated with a tile that has just been removed from the cache. For short hops, training, or any other sort of flight where you aren't venturing too far from home base, then it should be safe to leave random objects on. Regards, Curt. Curt, I still have the fgfs: ssg.h:302: void ssgBase::deRef(): Assertion `refc 0' failed. error with the random-objects disabled, just tried with current cvs. Happens after about the same distance as with them enabled. Regards, Geoff ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
Re: [Flightgear-devel] Failed assertion in ssg.h
Geoff Reidy writes: Curtis L. Olson wrote: Geoff, this would appear to be a potential problem in the tile freeing code. Can you give me a route (i.e. a series of waypoints) that will show the problem (and the approximate place where things die.) Also, leave the visibility at the default for the test (or tell me what visibility you are using) because the visibility value determines the size of the tile cache which affects when tiles need to be removed. Regards, Curt. OK to test this I have been flying the a4, taking off from Sydney (YSSY) and immediately going into autopilot with waypoint set to Katmandu (VNKT). Using visibility=64000 and cruising at about 12000ft. Also I'm running in 16bpp if that makes any difference. The assert error occurs shortly after crossing 125°E and about halfway between the Australian coast and Timor. Oh, and this is before I started mucking about with the code :) Geoff, I did some testing at home this weekend and I think there is something going on here related to the random ground cover objects. If I run with --disable-random-objects I have never seen a crash. If I run with the random objects I do see a similar crash after flying 3000 miles give or take a couple thousand. So I will say the following: For long haul flights, consider running without random objects. Random objects have a couple issues: - program crash after a few thousand miles. (To be fair, this may not directly be the random object code's fault. It could be an interaction issue with other portions of the program?) - issues with freeing tiles ... this can lead to substantially reduced frame rates while the system is struggling to free memory associated with a tile that has just been removed from the cache. For short hops, training, or any other sort of flight where you aren't venturing too far from home base, then it should be safe to leave random objects on. Regards, Curt. -- Curtis Olson IVLab / HumanFIRST Program FlightGear Project Twin Cities[EMAIL PROTECTED] [EMAIL PROTECTED] Minnesota http://www.menet.umn.edu/~curt http://www.flightgear.org ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
Re: [Flightgear-devel] Failed assertion in ssg.h
Hi again, This could be time consuming :) I bypassed the asserts in plib to try and see what's really happening and whether it's fatal or not. I think it was removing the deadBeefCheck that made a difference. cvsdiff is included below. Before when flying from Sydney to Katmandu the program always aborted just off the north coast of Australia. I can hit a a few times to get there quicker and it will still abort at the same place, which saves some time anyway... Just now with the changes I got all the way to Katmandu and then down the length of India before it seg faulted. Backtrace from gdb included below. I have more time than expertise in these matters so any hints would be appreciated :) Regards, Geoff Index: src/ssg/ssg.h === RCS file: /cvsroot/plib/plib/src/ssg/ssg.h,v retrieving revision 1.157 diff -r1.157 ssg.h 302c302,309 void deRef () { assert ( refc 0 ) ; refc-- ; } --- // void deRef () { assert ( refc 0 ) ; refc-- ; } void deRef () { if ( refc 0 ) refc-- ; else { printf(refc was %d\n, refc); refc = 0; } } Index: src/ssg/ssgBase.cxx === RCS file: /cvsroot/plib/plib/src/ssg/ssgBase.cxx,v retrieving revision 1.21 diff -r1.21 ssgBase.cxx 77c77 deadBeefCheck () ; --- // deadBeefCheck () ; $GPRMC,014714,A,1014.239,N,08035.811,E,628.6,-166.9,2311102,0.000,E*66 $GPGGA,014714,1014.239,N,08035.811,E,1,,,13051,F*21 Program received signal SIGSEGV, Segmentation fault. 0x4046e42d in malloc () from /lib/i686/libc.so.6 (gdb) bt #0 0x4046e42d in malloc () from /lib/i686/libc.so.6 #1 0x4046e262 in malloc () from /lib/i686/libc.so.6 #2 0x4012771e in operator new(unsigned) () from /usr/X11R6/lib/libGLU.so.1 #3 0x403a1900 in std::__default_alloc_templatetrue, 0::allocate(unsigned) () from /usr/lib/libstdc++.so.5 #4 0x081eda30 in FGNavList::query(double, double, double, double, FGNav*) (this=0x9144388, lon=1.4066544783701858, lat=0.17856467335732401, elev=3978.113809261698, freq=379, n=0xb1b0) at /usr/include/c++/3.2/bits/stl_vector.h:123 #5 0x080b6d73 in FGKR_87::search() (this=0x98ae504) at kr_87.cxx:487 #6 0x080b2026 in FGRadioStack::search() (this=0x98ae448) at radiostack.cxx:129 #7 0x080b21bb in fgMethodCallbackFGRadioStack*, void (FGRadioStack::*)()::operator()() ( this=0xc26e7a6) at ../../src/Include/fg_callback.hxx:117 #8 0x0824319f in FGEventMgr::FGEvent::run() (this=0x8fe6228) at FGEventMgr.cxx:86 #9 0x08243530 in FGEventMgr::update(double) (this=0x83bce58, dt=0.0066742) at /usr/include/c++/3.2/bits/stl_iterator.h:596 #10 0x0805170a in fgRenderFrame() () at main.cxx:440 #11 0x08053388 in fgMainLoop () at main.cxx:1263 #12 0x40084df2 in glutMainLoop () from /usr/X11R6/lib/libglut.so.3 #13 0x4008406d in glutMainLoop () from /usr/X11R6/lib/libglut.so.3 #14 0x08054708 in fgMainInit (argc=1, argv=0xb774) at main.cxx:1729 #15 0x08054cff in main (argc=1, argv=0xb774) at main.cxx:1821 #16 0x40419082 in __libc_start_main () from /lib/i686/libc.so.6 (gdb) ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
Re: [Flightgear-devel] Failed assertion in ssg.h
What version of FlightGear are you running with? You really don't want to comment out the deadbeef checks in plib. That a patch they certainly would not accept ... it indicates the program is trying to use memory it previously freed. Curt. Geoff Reidy writes: Hi again, This could be time consuming :) I bypassed the asserts in plib to try and see what's really happening and whether it's fatal or not. I think it was removing the deadBeefCheck that made a difference. cvsdiff is included below. Before when flying from Sydney to Katmandu the program always aborted just off the north coast of Australia. I can hit a a few times to get there quicker and it will still abort at the same place, which saves some time anyway... Just now with the changes I got all the way to Katmandu and then down the length of India before it seg faulted. Backtrace from gdb included below. I have more time than expertise in these matters so any hints would be appreciated :) Regards, Geoff Index: src/ssg/ssg.h === RCS file: /cvsroot/plib/plib/src/ssg/ssg.h,v retrieving revision 1.157 diff -r1.157 ssg.h 302c302,309 void deRef () { assert ( refc 0 ) ; refc-- ; } --- // void deRef () { assert ( refc 0 ) ; refc-- ; } void deRef () { if ( refc 0 ) refc-- ; else { printf(refc was %d\n, refc); refc = 0; } } Index: src/ssg/ssgBase.cxx === RCS file: /cvsroot/plib/plib/src/ssg/ssgBase.cxx,v retrieving revision 1.21 diff -r1.21 ssgBase.cxx 77c77 deadBeefCheck () ; --- // deadBeefCheck () ; $GPRMC,014714,A,1014.239,N,08035.811,E,628.6,-166.9,2311102,0.000,E*66 $GPGGA,014714,1014.239,N,08035.811,E,1,,,13051,F*21 Program received signal SIGSEGV, Segmentation fault. 0x4046e42d in malloc () from /lib/i686/libc.so.6 (gdb) bt #0 0x4046e42d in malloc () from /lib/i686/libc.so.6 #1 0x4046e262 in malloc () from /lib/i686/libc.so.6 #2 0x4012771e in operator new(unsigned) () from /usr/X11R6/lib/libGLU.so.1 #3 0x403a1900 in std::__default_alloc_templatetrue, 0::allocate(unsigned) () from /usr/lib/libstdc++.so.5 #4 0x081eda30 in FGNavList::query(double, double, double, double, FGNav*) (this=0x9144388, lon=1.4066544783701858, lat=0.17856467335732401, elev=3978.113809261698, freq=379, n=0xb1b0) at /usr/include/c++/3.2/bits/stl_vector.h:123 #5 0x080b6d73 in FGKR_87::search() (this=0x98ae504) at kr_87.cxx:487 #6 0x080b2026 in FGRadioStack::search() (this=0x98ae448) at radiostack.cxx:129 #7 0x080b21bb in fgMethodCallbackFGRadioStack*, void (FGRadioStack::*)()::operator()() ( this=0xc26e7a6) at ../../src/Include/fg_callback.hxx:117 #8 0x0824319f in FGEventMgr::FGEvent::run() (this=0x8fe6228) at FGEventMgr.cxx:86 #9 0x08243530 in FGEventMgr::update(double) (this=0x83bce58, dt=0.0066742) at /usr/include/c++/3.2/bits/stl_iterator.h:596 #10 0x0805170a in fgRenderFrame() () at main.cxx:440 #11 0x08053388 in fgMainLoop () at main.cxx:1263 #12 0x40084df2 in glutMainLoop () from /usr/X11R6/lib/libglut.so.3 #13 0x4008406d in glutMainLoop () from /usr/X11R6/lib/libglut.so.3 #14 0x08054708 in fgMainInit (argc=1, argv=0xb774) at main.cxx:1729 #15 0x08054cff in main (argc=1, argv=0xb774) at main.cxx:1821 #16 0x40419082 in __libc_start_main () from /lib/i686/libc.so.6 (gdb) ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel -- Curtis Olson IVLab / HumanFIRST Program FlightGear Project Twin Cities[EMAIL PROTECTED] [EMAIL PROTECTED] Minnesota http://www.menet.umn.edu/~curt http://www.flightgear.org ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
Re: [Flightgear-devel] Failed assertion in ssg.h
Curtis L. Olson wrote: What version of FlightGear are you running with? You really don't want to comment out the deadbeef checks in plib. That a patch they certainly would not accept ... it indicates the program is trying to use memory it previously freed. Curt. Running cvs plib simgear flightgear as of yesterday, though this problem has existed for some time, for me at least. I realise the deadbeef check is there for a reason and am not suggesting it be removed. I'm just fumbling around trying to figure why I can't travel more than about 3500 kms before fgfs dies. I guess the question is why is flightgear trying to reuse the memory and is it easier or harder to find the problem with the asserts in place? Basically I'm hoping someone will hit me over the head with a clue, or that I can provide information that will help someone who knows how the program works to find the problem. I have the time to do testing but it may take me a looong time to figure out what's going wrong. Possibly you have missed my first post in this thread where I did a backtrace from when this error appears: fgfs: ssg.h:302: void ssgBase::deRef(): Assertion `refc 0' failed. Aborted Geoff ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
Re: [Flightgear-devel] Failed assertion in ssg.h
Geoff, this would appear to be a potential problem in the tile freeing code. Can you give me a route (i.e. a series of waypoints) that will show the problem (and the approximate place where things die.) Also, leave the visibility at the default for the test (or tell me what visibility you are using) because the visibility value determines the size of the tile cache which affects when tiles need to be removed. Regards, Curt. Geoff Reidy writes: Hi all, I'm running current cvs of plib, simgear and flightgear on linux. Compiled with threads and without logging. After running for 3 or 4 hours fgfs always seg faults on me, normally I strip the binary but this time I didn't and now I get this error: fgfs: ssg.h:302: void ssgBase::deRef(): Assertion `refc 0' failed. Aborted So I ran it through gdb and did a backtrace. (The nav-vor-ident errors occur the whole time the program is running at the rate of about one per second.) Let me know if there's anything else I can do. Regards, Geoff $GPRMC,091314,A,1153.264,S,12434.835,E,610.9,-43.4,1411102,0.000,E*4B $GPGGA,091314,1153.264,S,12434.835,E,1,,,15031,F*37 $GPRMC,091314,A,1153.264,S,12434.835,E,610.9,-43.4,1411102,0.000,E*4B $GPGGA,091314,1153.264,S,12434.835,E,1,,,15031,F*37 Failed to remove nav-vor-ident sound Failed to remove nav-vor-ident sound Failed to remove nav-vor-ident sound Failed to remove nav-vor-ident sound fgfs: ssg.h:302: void ssgBase::deRef(): Assertion `refc 0' failed. Program received signal SIGABRT, Aborted. 0x4042a3d1 in kill () from /lib/i686/libc.so.6 (gdb) bt #0 0x4042a3d1 in kill () from /lib/i686/libc.so.6 #1 0x40305dad in raise () from /lib/i686/libpthread.so.0 #2 0x4042b979 in abort () from /lib/i686/libc.so.6 #3 0x4042466f in __assert_fail () from /lib/i686/libc.so.6 #4 0x082b2c56 in ssgDeRefDelete(ssgBase*) () at ssg.cxx:89 #5 0x082b89c9 in ~ssgLeaf (this=0xccb62a0) at ssgLeaf.cxx:79 #6 0x082ce88b in ~ssgVtxTable (this=0xccb62a0) at ssgVtxTable.cxx:148 #7 0x082b2c38 in ssgDeRefDelete(ssgBase*) (s=0x1) at ssg.cxx:89 #8 0x082b59c4 in ssgBranch::removeKid(int) (this=0xcca3660, n=1076928544) at ssgBranch.cxx:97 #9 0x081f036e in fgPartialFreeSSGtree (b=0xcca3660, n=90) at tileentry.cxx:724 #10 0x081f0385 in fgPartialFreeSSGtree (b=0xcca3500, n=100) at tileentry.cxx:713 #11 0x081f0385 in fgPartialFreeSSGtree (b=0x52128070, n=100) at tileentry.cxx:713 #12 0x081f0385 in fgPartialFreeSSGtree (b=0x52932bb0, n=100) at tileentry.cxx:713 #13 0x081f0695 in FGTileEntry::free_tile() (this=0x52932ab8) at tileentry.cxx:777 #14 0x081f4562 in FGTileMgr::update(double, double, double, double*, SGBucket, SGBucket, Point3D) (this=0x8401b40, lon=1.2731974745791634e-313, lat=0.005715523559064053, visibility_meters=64000, abs_pos_vector=0x8bc0314, p_current=Cannot access memory at address 0x6 ) at tilemgr.cxx:398 #15 0x08053126 in fgMainLoop () at ../../src/Main/location.hxx:116 #16 0x40084df2 in glutMainLoop () from /usr/X11R6/lib/libglut.so.3 #17 0x4008406d in glutMainLoop () from /usr/X11R6/lib/libglut.so.3 #18 0x08054803 in mainLoop(int, char**) (argc=1, argv=0xb5d0) at main.cxx:1742 #19 0x08054ebf in main (argc=1, argv=0xb774) at main.cxx:1834 #20 0x40419082 in __libc_start_main () from /lib/i686/libc.so.6 (gdb) ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel -- Curtis Olson IVLab / HumanFIRST Program FlightGear Project Twin Cities[EMAIL PROTECTED] [EMAIL PROTECTED] Minnesota http://www.menet.umn.edu/~curt http://www.flightgear.org ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
Re: [Flightgear-devel] Failed assertion in ssg.h
Curtis L. Olson wrote: Geoff, this would appear to be a potential problem in the tile freeing code. Can you give me a route (i.e. a series of waypoints) that will show the problem (and the approximate place where things die.) Also, leave the visibility at the default for the test (or tell me what visibility you are using) because the visibility value determines the size of the tile cache which affects when tiles need to be removed. Regards, Curt. OK to test this I have been flying the a4, taking off from Sydney (YSSY) and immediately going into autopilot with waypoint set to Katmandu (VNKT). Using visibility=64000 and cruising at about 12000ft. Also I'm running in 16bpp if that makes any difference. The assert error occurs shortly after crossing 125°E and about halfway between the Australian coast and Timor. Oh, and this is before I started mucking about with the code :) Regards, Geoff ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
[Flightgear-devel] Failed assertion in ssg.h
Hi all, I'm running current cvs of plib, simgear and flightgear on linux. Compiled with threads and without logging. After running for 3 or 4 hours fgfs always seg faults on me, normally I strip the binary but this time I didn't and now I get this error: fgfs: ssg.h:302: void ssgBase::deRef(): Assertion `refc 0' failed. Aborted So I ran it through gdb and did a backtrace. (The nav-vor-ident errors occur the whole time the program is running at the rate of about one per second.) Let me know if there's anything else I can do. Regards, Geoff $GPRMC,091314,A,1153.264,S,12434.835,E,610.9,-43.4,1411102,0.000,E*4B $GPGGA,091314,1153.264,S,12434.835,E,1,,,15031,F*37 $GPRMC,091314,A,1153.264,S,12434.835,E,610.9,-43.4,1411102,0.000,E*4B $GPGGA,091314,1153.264,S,12434.835,E,1,,,15031,F*37 Failed to remove nav-vor-ident sound Failed to remove nav-vor-ident sound Failed to remove nav-vor-ident sound Failed to remove nav-vor-ident sound fgfs: ssg.h:302: void ssgBase::deRef(): Assertion `refc 0' failed. Program received signal SIGABRT, Aborted. 0x4042a3d1 in kill () from /lib/i686/libc.so.6 (gdb) bt #0 0x4042a3d1 in kill () from /lib/i686/libc.so.6 #1 0x40305dad in raise () from /lib/i686/libpthread.so.0 #2 0x4042b979 in abort () from /lib/i686/libc.so.6 #3 0x4042466f in __assert_fail () from /lib/i686/libc.so.6 #4 0x082b2c56 in ssgDeRefDelete(ssgBase*) () at ssg.cxx:89 #5 0x082b89c9 in ~ssgLeaf (this=0xccb62a0) at ssgLeaf.cxx:79 #6 0x082ce88b in ~ssgVtxTable (this=0xccb62a0) at ssgVtxTable.cxx:148 #7 0x082b2c38 in ssgDeRefDelete(ssgBase*) (s=0x1) at ssg.cxx:89 #8 0x082b59c4 in ssgBranch::removeKid(int) (this=0xcca3660, n=1076928544) at ssgBranch.cxx:97 #9 0x081f036e in fgPartialFreeSSGtree (b=0xcca3660, n=90) at tileentry.cxx:724 #10 0x081f0385 in fgPartialFreeSSGtree (b=0xcca3500, n=100) at tileentry.cxx:713 #11 0x081f0385 in fgPartialFreeSSGtree (b=0x52128070, n=100) at tileentry.cxx:713 #12 0x081f0385 in fgPartialFreeSSGtree (b=0x52932bb0, n=100) at tileentry.cxx:713 #13 0x081f0695 in FGTileEntry::free_tile() (this=0x52932ab8) at tileentry.cxx:777 #14 0x081f4562 in FGTileMgr::update(double, double, double, double*, SGBucket, SGBucket, Point3D) (this=0x8401b40, lon=1.2731974745791634e-313, lat=0.005715523559064053, visibility_meters=64000, abs_pos_vector=0x8bc0314, p_current=Cannot access memory at address 0x6 ) at tilemgr.cxx:398 #15 0x08053126 in fgMainLoop () at ../../src/Main/location.hxx:116 #16 0x40084df2 in glutMainLoop () from /usr/X11R6/lib/libglut.so.3 #17 0x4008406d in glutMainLoop () from /usr/X11R6/lib/libglut.so.3 #18 0x08054803 in mainLoop(int, char**) (argc=1, argv=0xb5d0) at main.cxx:1742 #19 0x08054ebf in main (argc=1, argv=0xb774) at main.cxx:1834 #20 0x40419082 in __libc_start_main () from /lib/i686/libc.so.6 (gdb) ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel