fail logbook

Debugging fail.exe


Messages

# Type Time Processes Message
1 0:00.000 n/a
Launching srun -n 4 fail.exe
at Thu Jun 20 10:37:57 2019
2 0:04.829 0-3
Startup complete.
3 0:04.829 n/a
Select process group All
4 0:04.830 0-3
Add breakpoint for fail.c:14
5 0:04.832 n/a
Add Expression to Evaluate: k
6 0:04.832 n/a
Add Expression to Evaluate: n
7
Additional Information

 Stacks
Processes Function Source Variables
main (fail.c:62)
 
MPI_Comm_rank(MPI_COMM_WORLD, &rank);
  char clbuf[7 * CPU_SETSIZE], hnbuf[64];

  MPI_Init(&argc, &argv);
  MPI_Comm_rank(MPI_COMM_WORLD, &rank);
  MPI_Comm_size(MPI_COMM_WORLD, &numprocs);
  if (rank == 0) {
    m_routine(rank);
 Rank 0, thread 1
Name Value
<return value> Sparkline 0
argc Sparkline 1
argv Sparkline 0x7fffffff8cd8
clbuf ""
coremask <aggregate value>
hnbuf ""
numprocs Sparkline 0
rank Sparkline 0
dapli_thread_init
 Rank 0, thread 2
Name Value
<return value> Sparkline 0
  cm_thread
 Rank 0, thread 2
Name Value
<return value> Sparkline 0
    poll
 Rank 0, thread 2
Name Value
<return value> Sparkline 0

 Current Stack
#0 main (argc=1, argv=0x7fffffff8cd8) at /home/schoenherrm/tools/src/fail.c:62 (at 0x0000000000400a87)

 Locals
Name Value
<return value> Sparkline 0
argc Sparkline 1
argv Sparkline 0x7fffffff8cd8
clbuf Sparkline ""
coremask Sparkline
hnbuf Sparkline ""
numprocs Sparkline 0
rank Sparkline 0

 Evaluate
Name Value
k Sparkline <No symbol "k" in current context.>
n Sparkline <No symbol "n" in current context.>
8 0:05.397 n/a
Debugging : srun -n 4 fail.exe
MPI implementation : Auto-Detect (SLURM (MPMD))
* number of processes : 4
* number of nodes : 2
Memory debugging enabled : No
9 0:05.397 0-3
Play
10 0:05.617 0
Process stopped at breakpoint in sub_task (fail.c:14).
11
Additional Information

 Stacks
Processes Function Source Variables
main (fail.c:65)
 
m_routine(rank);
  MPI_Comm_rank(MPI_COMM_WORLD, &rank);
  MPI_Comm_size(MPI_COMM_WORLD, &numprocs);
  if (rank == 0) {
    m_routine(rank);
  } else {
    w_run(rank, numprocs);
  }
 Rank 0, thread 1
Name Value
argc Sparkline 1
argv Sparkline 0x7fffffff8cd8
clbuf ""
coremask <aggregate value>
hnbuf ""
numprocs Sparkline 4
rank Sparkline 0
  m_routine (fail.c:38)
 
calculation();
int m_routine(int rank){
  int array[100];
  int root=0;
  calculation();
  printf("Hello from rank %d\n", rank);
  MPI_Bcast( array, 100, MPI_INT, root, MPI_COMM_WORLD);
}
 Rank 0, thread 1
Name Value
array <aggregate value>
rank Sparkline 0
root Sparkline 0
    calculation (fail.c:31)
 
do_task();
}

int calculation(){
  do_task();
}

      do_task (fail.c:24)
 
res = sub_task(p,n);
  int p = 13;
  int n = 0;
  int res;
  res = sub_task(p,n);
  
  res = res / n;
  printf("This should be the result: %d \n", res);
 Rank 0, thread 1
Name Value
n Sparkline 0
p Sparkline 13
res Sparkline 0
        sub_task (fail.c:14)
 
res = k+n;
int sub_task(int k, int n){
  int res ;
  int *p = NULL;
  res = k+n;
  *p = 1;
  printf("This should fail %d\n", p);
  return res;
 Rank 0, thread 1
Name Value
k Sparkline 13
n Sparkline 0
p Sparkline 0x0
res Sparkline 32767
dapli_thread_init
  cm_thread
    poll

 Current Stack
#4 main (argc=1, argv=0x7fffffff8cd8) at /home/schoenherrm/tools/src/fail.c:65 (at 0x0000000000400aba)
#3 m_routine (rank=0) at /home/schoenherrm/tools/src/fail.c:38 (at 0x00000000004009b9)
#2 calculation () at /home/schoenherrm/tools/src/fail.c:31 (at 0x0000000000400994)
#1 do_task () at /home/schoenherrm/tools/src/fail.c:24 (at 0x0000000000400962)
#0 sub_task (k=13, n=0) at /home/schoenherrm/tools/src/fail.c:14 (at 0x000000000040090d)

 Evaluate
Name Value
k Sparkline 13
n Sparkline 0
12 0:08.118 0
Play
13 0:08.158 0
Memory error detected in sub_task (fail.c:15):
null pointer dereference or unaligned memory access.
14
Additional Information

 Stacks
Processes Function Source Variables
main (fail.c:65)
 
m_routine(rank);
  MPI_Comm_rank(MPI_COMM_WORLD, &rank);
  MPI_Comm_size(MPI_COMM_WORLD, &numprocs);
  if (rank == 0) {
    m_routine(rank);
  } else {
    w_run(rank, numprocs);
  }
 Rank 0, thread 1
Name Value
argc Sparkline 1
argv Sparkline 0x7fffffff8cd8
clbuf ""
coremask <aggregate value>
hnbuf ""
numprocs Sparkline 4
rank Sparkline 0
  m_routine (fail.c:38)
 
calculation();
int m_routine(int rank){
  int array[100];
  int root=0;
  calculation();
  printf("Hello from rank %d\n", rank);
  MPI_Bcast( array, 100, MPI_INT, root, MPI_COMM_WORLD);
}
 Rank 0, thread 1
Name Value
array <aggregate value>
rank Sparkline 0
root Sparkline 0
    calculation (fail.c:31)
 
do_task();
}

int calculation(){
  do_task();
}

      do_task (fail.c:24)
 
res = sub_task(p,n);
  int p = 13;
  int n = 0;
  int res;
  res = sub_task(p,n);
  
  res = res / n;
  printf("This should be the result: %d \n", res);
 Rank 0, thread 1
Name Value
n Sparkline 0
p Sparkline 13
res Sparkline 0
        sub_task (fail.c:15)
 
*p = 1;
  int res ;
  int *p = NULL;
  res = k+n;
  *p = 1;
  printf("This should fail %d\n", p);
  return res;
}
 Rank 0, thread 1
Name Value
k Sparkline 13
n Sparkline 0
p Sparkline 0x0
res Sparkline 13
dapli_thread_init
  cm_thread
    poll

 Current Stack
#4 main (argc=1, argv=0x7fffffff8cd8) at /home/schoenherrm/tools/src/fail.c:65 (at 0x0000000000400aba)
#3 m_routine (rank=0) at /home/schoenherrm/tools/src/fail.c:38 (at 0x00000000004009b9)
#2 calculation () at /home/schoenherrm/tools/src/fail.c:31 (at 0x0000000000400994)
#1 do_task () at /home/schoenherrm/tools/src/fail.c:24 (at 0x0000000000400962)
#0 sub_task (k=13, n=0) at /home/schoenherrm/tools/src/fail.c:15 (at 0x000000000040091c)

 Evaluate
Name Value
k Sparkline 13
n Sparkline 0


Tracepoints

No tracepoints set or hit.

Output

Hello from rank 2 of 4)
Hello from rank 3 of 4)
Hello from rank 1 of 4)