Analyzers
Talk to fellow users of Intel Analyzer tools (Intel VTune™ Profiler, Intel Advisor)
5133 Discussions

Vtune crash with simple python application

Mark_M_10
Beginner
1,345 Views

I get a crash (segfault with no error log dumped) whenever I run vtune over a python application.  Here's a simple script that triggers the behavior  on my machine:

import numpy as np
import numpy.random as ra
import numpy.linalg as la

if __name__ == "__main__":
  n = 10000
  A = ra.random((n,n))
  b = ra.random((n,))

  c = np.dot(A,b)
  print(la.norm(c))

For example:

amplxe-cl -collect hotspots -- python test.py

Results in:

amplxe: Collection started. To stop the collection, either press CTRL-C or enter from another console window: amplxe-cl -r /home/messner/projects/neml/debug/r000hs -command stop.
250170.317306
amplxe: Warning: Cannot stop posix timer: __NR_timer_settime() system call returned -1.
amplxe: Collection stopped.
amplxe: Using result path `/home/messner/projects/neml/debug/r000hs'
amplxe: Executing actions 19 % Resolving module symbols                        
amplxe: Warning: Cannot locate file `test.py'.
amplxe: Executing actions 21 % Resolving information for `libc-dynamic.so'     
amplxe: Warning: Cannot locate debugging symbols for file `/opt/intel/vtune_amplifier_xe_2017.0.2.478468/lib64/pinruntime/libc-dynamic.so'.
amplxe: Executing actions 22 % Resolving information for `libc-dynamic.so'     
amplxe: Warning: Cannot locate debugging symbols for file `/opt/intel/vtune_amplifier_xe_2017.0.2.478468/lib64/libtpsstool.so'.
amplxe: Executing actions 22 % Resolving information for `libtatlas.so.3'      Segmentation fault

So the script runs, but there's some problem collecting the profiling results.

If I run in the debugger I get the very unhelpful:

...

Detaching after fork from child process 38459.
amplxe: Executing actions 19 % Resolving module symbols                        
amplxe: Warning: Cannot locate file `test.py'.
amplxe: Executing actions 21 % Resolving information for `libdl.so.2'          
amplxe: Warning: Cannot locate debugging symbols for file `/opt/intel/vtune_amplifier_xe_2017.0.2.478468/bin64/pinbin'.
amplxe: Executing actions 21 % Resolving information for `libtpsstool.so'      
amplxe: Warning: Cannot locate debugging symbols for file `/opt/intel/vtune_amplifier_xe_2017.0.2.478468/lib64/pinruntime/libpin3dwarf.so'.
amplxe: Executing actions 21 % Resolving information for `type_check.py'       
amplxe: Warning: Cannot locate debugging symbols for file `/opt/intel/vtune_amplifier_xe_2017.0.2.478468/lib64/libtpsstool.so'.
amplxe: Executing actions 22 % Resolving information for `arraysetops.py'      
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fffd9e2a700 (LWP 38455)]
0x00007fffea84e963 in ?? ()
   from /opt/intel/vtune_amplifier_xe_2017.0.2.478468/bin64/../lib64/../lib64/../lib64/libamplxe_ism_core_3.34.s

Any suggestions?

0 Kudos
7 Replies
Mark_M_10
Beginner
1,345 Views

Forgot to mention:

amplxe-cl --version
Intel(R) VTune(TM) Amplifier XE 2017 (build 478468) Command Line Tool
Copyright (C) 2009-2016 Intel Corporation. All rights reserved.

python --version
Python 2.7.5

0 Kudos
Ekaterina_L_Intel
1,345 Views

Hello Mark,

Can you please create crash report as shown below and attach the report.zip for exploration?

amplxe-feedback -create-bug-report report.zip

Regards, Katya 

0 Kudos
Mark_M_10
Beginner
1,345 Views

Attached.

0 Kudos
Denis_M_Intel
Employee
1,345 Views

It crashes on reading debugging information for one of binary files.

To identify the binary file, try following commands:
 - export DICENG_DEBUG_FLAGS=SerialResolving
 - amplxe-cl -fin -r <result_directory>

It should be one of binary files referenced in VTune finalization output right before the crash. If you temporary rename this binary file or its symbol file (if debugging info. is in a separate symbol file) and run VTune finalization (amplxe-cl -fin -r <result_directory>) again, it should complete.

We would appreciate it if you sent us this binary file and its symbol file so we could reproduce the issue.

0 Kudos
Mark_M_10
Beginner
1,345 Views

It seems to be libtatlas.so.3, as it crashes immediately after

Executing actions 42 % Resolving information for `libtatlas.so.3'

I can confirm that forcing it to skip this library by renaming fixes the problem.  However it's just the binary version of ATLAS BLAS that comes with CENTOS 7, so that's not a convenient solution for me as most of my stuff links BLAS.

How can I get you the shared library and its symbols?  The forum system seems to reject attaching them to this post.

0 Kudos
Denis_M_Intel
Employee
1,345 Views

What version is it? I think I reproduced the crash on atlas-3.10.1-10.

It looks like there is atlas-debuginfo package installed on your system?  libtatlas.so.3.10.debug is the symbol file which causes this crash. Workaround is to temporary rename it but I would suggest updating VTune to VTune Amplifier XE 2017 Update 1 – new version has bug fixes.

0 Kudos
Mark_M_10
Beginner
1,345 Views

Sorry for the delayed response.

It's atlas 3.10.1.

Renaming the debug symbols fixes the problem.  I'll update as soon as I can and see if that fixes it as well.

 

0 Kudos
Reply