[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
hdgeant crash
Hi All,
I finally managed to get the hdgeant running in debug mode again.
Unfortunately only on
my local machine not on the ifarms.
I run hdgeant with pythia generated events as input. and I have
NOSECONDARIES 0
because I want to have showers in the BCAL.
the code crashes unpredictably at an arbitrary event but always with the
same error message:
400 events simulated
**** GTCKOV: unable to reflect at NTMULT = 29347 step No. 37
photon abandoned!
**** GTCKOV: unable to reflect at NTMULT = 8492 step No. 50
photon abandoned!
hdgeant_d: bintree.c:33: getTwig: Assertion `node->mark >= 0' failed.
Program received signal SIGABRT, Aborted.
0x00b5b402 in __kernel_vsyscall ()
(gdb)
attached is the output from the debugger while I go through the
different levels.
the code crashes in hitFDC.c at line 544 when calling getTwig() because
as it turns out
the "chamber" number is determined to be -10! (see attached file)
I have not looked into detail why this can happen but at this point I
through
the ball out in the field maybe Simon or Richard will see immediately
where the
root of the problem is.
cheers,
Beni
--
***********************************************************
Benedikt Zihlmann
TJNAF
HallD 12C/ F350
Suite 8
12000 Jefferson Av.
Newport News VA, 23606
tel: 757 269 5310
fax: 757 269 6331 zihlmann@jlab.org
***********************************************************
400 events simulated
**** GTCKOV: unable to reflect at NTMULT = 29347 step No. 37 photon abandoned!
**** GTCKOV: unable to reflect at NTMULT = 8492 step No. 50 photon abandoned!
hdgeant_d: bintree.c:33: getTwig: Assertion `node->mark >= 0' failed.
Program received signal SIGABRT, Aborted.
0x00b5b402 in __kernel_vsyscall ()
(gdb)
(gdb) bt
#0 0x00b5b402 in __kernel_vsyscall ()
#1 0x0378fd80 in raise () from /lib/libc.so.6
#2 0x03791691 in abort () from /lib/libc.so.6
#3 0x037891fb in __assert_fail () from /lib/libc.so.6
#4 0x080ccdeb in getTwig (tree=0xdd1064c, mark=-10484619) at bintree.c:33
#5 0x080ccdb9 in getTwig (tree=0x8b4b298, mark=-10484619) at bintree.c:29
#6 0x082a1762 in hitForwardDC (xin=0x8b4b38c, xout=0x8b4b37c, pin=0x8b4b3b0, pout=0x8b4b39c, dEsum=5.50264958e-05, track=2, stack=27, history=1,
ipart=3) at hitFDC.c:544
#7 0x082a1a27 in hitforwarddc_ (xin=0x8b4b38c, xout=0x8b4b37c, pin=0x8b4b3b0, pout=0x8b4b39c, dEsum=0x8b4b3c8, track=0x8c4614c, stack=0x8c46150,
history=0x8c43e10, ipart=0x8c46158) at hitFDC.c:615
#8 0x082a5ed0 in savehits_ () at savehits.F:182
#9 0x080db920 in gustep_ () at gustep.F:404
#10 0x080daf12 in gtrack_ () at gtrack.F:282
#11 0x0855324b in gutrak_ ()
#12 0x088bb219 in jumpt0_ ()
#13 0x20000000 in ?? ()
#14 0xbf34848a in ?? ()
#15 0xbfa6cac8 in ?? ()
#16 0x0854b2b0 in gtreve_ ()
#17 0x0855325b in gutrev_ ()
#18 0x088bb219 in jumpt0_ ()
#19 0x0b2794d4 in Npoints ()
#20 0x0b2792a8 in gcbank_ ()
#21 0x0895d174 in ?? ()
#22 0x084b10c1 in gtrig_ ()
#23 0x084b0f78 in grun_ ()
#24 0x0829d52c in hdgeant_ () at hdgeant_f.F:29
#25 0x080cb36f in main () at hdgeant.cc:7
(gdb) up
#4 0x080ccdeb in getTwig (tree=0xdd1064c, mark=-10484619) at bintree.c:33
33 assert (node->mark >= 0);
Current language: auto; currently c
(gdb) list
28 {
29 return getTwig(&node->left, mark);
30 }
31 else
32 {
33 assert (node->mark >= 0);
34 return getTwig(&node->right, mark);
35 }
36 }
37
(gdb) print mark
$1 = -10484619
(gdb)
(gdb) up
#5 0x080ccdb9 in getTwig (tree=0x8b4b298, mark=-10484619) at bintree.c:29
29 return getTwig(&node->left, mark);
(gdb) list
24 {
25 return &node->this;
26 }
27 else if (mark < node->mark)
28 {
29 return getTwig(&node->left, mark);
30 }
31 else
32 {
33 assert (node->mark >= 0);
(gdb) print mark
$2 = -10484619
(gdb)
(gdb) up
#6 0x082a1762 in hitForwardDC (xin=0x8b4b38c, xout=0x8b4b37c, pin=0x8b4b3b0, pout=0x8b4b39c, dEsum=5.50264958e-05, track=2, stack=27, history=1,
ipart=3) at hitFDC.c:544
544 void** twig = getTwig(&forwardDCTree, mark);
(gdb) list
539
540 if ((strip > 0) && (check_radius>strip_dead_zone_radius[PackNo])
541 && (strip <= STRIPS_PER_PLANE))
542 {
543 int mark = (chamber<<20) + (plane<<10) + strip;
544 void** twig = getTwig(&forwardDCTree, mark);
545 if (*twig == 0)
546 {
547 s_ForwardDC_t* fdc = *twig = make_s_ForwardDC();
548 s_FdcChambers_t* chambers = make_s_FdcChambers(1);
(gdb) print wire1
$3 = 84
(gdb) print wire2
$4 = 112
(gdb)
(gdb) print dwire
$5 = 1
(gdb) print dr
$6 = 31.3848267
(gdb)
(gdb) print dEdx
$7 = 1.75328341e-06
(gdb) print dradius
$8 = 0.478390366
(gdb) print tdrift
$9 = 99.4354782
(gdb) print dE
$10 = 2.89517939e-08
(gdb)
(gdb) print node
$11 = -2
(gdb) print strip
$12 = 117
(gdb) print mark
$13 = -10484619
(gdb) print chamber
$14 = -10
(gdb) print plane
$15 = 1
(gdb) print PackNo
$16 = -1
(gdb) print module
$17 = -1
(gdb) print chamber
$18 = -10
(gdb)
(gdb) up
#8 0x082a5ed0 in savehits_ () at savehits.F:182
182 > IPART)
Current language: auto; currently fortran
(gdb) list
177 dEsum = 1e-5 ! 10 KeV in gas
178 endif
179 #endif
180 if (dEsum.gt.0) then
181 call hitForwardDC(xin,xout,pin,pout,dEsum,ITRA,ISTAK,ISTORY,
182 > IPART)
183 endif
184 elseif (cnames(NLEVEL).eq.'CERW') then ! Cerenkov truth
185 if (dEsum.gt.0) then
186 call hitCerenkov(xin,xout,pin,pout,dEsum,ITRA,ISTAK,ISTORY,
(gdb)
(gdb) print NLEVEL
$19 = 9
(gdb) whatis cnames
type = char (15,4)
(gdb) print cnames
$20 = (( 83 'S', 73 'I', 84 'T', 69 'E', 72 'H', 65 'A', 76 'L', 76 'L', 76 'L', 65 'A', 83 'S', 83 'S', 66 'B', 67 'C', 65 'A') ( 76 'L', 83 'S', 68 'D', 48 '0', 53 '5', 66 'B', 67 'C', 65 'A', 77 'M', 66 'B', 67 'C', 76 'L', 48 '0', 70 'F', 68 'D') ( 71 'G', 52 '4', 70 'F', 68 'D', 65 'A', 52 '4', 70 'F', 68 'D', 65 'A', 87 'W', 70 'F', 68 'D', 82 'R', 86 'V', 0 '\000') ( 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000', 0 '\000') )
(gdb) print xin
$21 = (16.5555115, -31.9943581, 352.840118, 1.32780249e-08)
(gdb) print xout
$22 = (43.6657715, -47.7630539, 351.661377, 1.16328049e-08)
(gdb)
(gdb) print pin
$23 = (-0.580459654, 0.450412065, 0.678377151, 0.000628362759, 0.000365677115)
(gdb) print pout
$24 = (0.0491450839, 0.459168077, -0.886988997, 0.00051099906, 0)
(gdb)