- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am calling the lapack subroutine DLAPMT in the following snippet of my code:
c Permute matrix c_all according to IPERM1
do i=1, n_sources
do k=1,g_layers
do l=1,n_layers
call DLAPMT (.TRUE., nsim, ndim, c_all(:,:,i,k,l), nsim, IPERM1)
enddo
enddo
enddo
In this case n_sources is 2, g_layers is 1 and n_layers is 1. Therefore it should call DLAPMT twice. The first time it works fine. The second time it reaches DLAPMT, it kills the process due to a segmentation error. I've checked and all the inputs are exactly the same the second time around. What could be causing this problem?
Thanks
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Is the LAPACK library you're calling the one from Intel MKL or something else? You say "segmentation fault", which is a Linux term - are you using Windows (this forum) or Linux? What happens if you add /heap-arrays (-heap-arrays) to the compile options?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm using Linux, sorry about that. It is from the Intel MKL library. I'll try the heap-arrays option
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
That worked, thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Ok - looks as if you're getting a stack overflow and the compiler is creating a stack temp and not removing it, but I don't think it should need a temp here. Can you provide me with a small but complete source that shows the problem?
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page