archimedes-discuss
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[archimedes-discuss] Seg fault on EMC


From: Frankie Y. Liu
Subject: [archimedes-discuss] Seg fault on EMC
Date: Tue, 26 Oct 2010 12:43:22 -0700

Jean-Michel,

I am getting a seg fault, there are a couple of possibilities:
In ensemblemontecarlo.h, after calculating drift(tau)

I get large X and Y, such that i and j overflow, giving me
negative numbers of i=(int)(X/dx + 1.5)

either drift(tau) is giving the incorrect results,
(drift: hmt 3.617739e-19 kx -1.596902e+08 dkx -7.120803e+27 ky 3.209277e+08 dky 9.345414e+29 thesquareroot 1.015214e+00)

or I should catch that there is an overflow in X/dx

Can you check if the (drift:) numbers above make sense?

X and Y are shown below.

-frankie


(gdb) run ../tests/MOSFET/mosfet.input

Program received signal SIGSEGV, Segmentation fault.
0x000000000040fb0f in EMC () at ensemblemontecarlo.h:95
95          if(i<=1 && (EDGE[3][j][0]==1 || EDGE[3][j][0]==2)){


Looking at i and j:

(gdb) p i
$3 = -2147483648
(gdb) p j
$4 = -2147483648
(gdb) p X
$5 = 1268757899.4394436
(gdb) p Y
$6 = 166513070806.71521
(gdb) p dx
$7 = 5.0000000000000001e-09
(gdb) p dy
$8 = 5.0000000000000001e-09

(gdb) p P[1][5]
$9 = 1.5444207191467285e-09
(gdb) p P[1][6]
$10 = 3.4819921016693114e-07


reply via email to

[Prev in Thread] Current Thread [Next in Thread]