- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Adrian
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am running in the the debugger. I'm not sure about /dbglibs, I'll check into that.
Another problem: I decided to swicth on /check:all as well. The debugger brought up a window informing me that I was accessing element 0 of an array. I click OK, but nothing happens. So then I click the break button (||). It breaks, but not in my source, but in some nodebug runtime library where all I see is assembler. In CVF, clicking OK after encountering the error brought me directly to the line in the source code where the error lay. What is the problem?
BTW: I haven'tupgraded my version from that on theCD yet, maybe I need to do that?
Adrian
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, please do update to the current version, 9.0.025, but this won't make much difference for uninitialized variable checking, I think. (Actually, it may make it worse in that the name of the reported variable will be wrong.) But the newer version fixes many other issues.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I managed to upgrade to the latest version, but yes as you say, there is still the problem.
So here's my question: I am responsiblefor signaling the time for, and making the change in our organization to switch from DVF6.1 to Intel. I think both of these issues are essential for debugging (especially the ability to take the user to the problem line in the source). Maybe v9.x is not yet mature enough? Should we beswitching tov8.0 instead?
Adrian
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, I'm sure there are undiscovered bugs in our code, I'm trying to find them!
You say you have seen this behavior already so I guess there's no need for me to send a specific case. How long for the fix?
Adrian
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
00475455 8B E5 mov esp,ebp ! <- Set Next Statement here 00475457 5D pop ebp 00475458 8B E3 mov esp,ebx 0047545A 5B pop ebx 0047545B C3 ret
0047533F C9 leave ! <- Set Next Statemen here 00475340 C3 ret
Or you may simply see a "ret" alone. i.e. if you see
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks, Jim. While not pretending to follow everything you wrote, I did follow some of it, but as my call stack is probably 50 deep, and these are mostly system dll's, it is very difficult to set the correct return positions. I miss one, and it goes back right to the top again.
In the meantime, I have sent a "Show-Stopper" bug report into premier.intel.com, with an example - hopefully they'll sort it out soon. I believe it is pretty much a requirement of any debugger that it stops at the line of offending code when it encounters an exception, I'm amazed that v9.0 was released at all with this problem.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes it stops, but not in the correct place!
Adrian
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Although your call stack is of little use you do have an indication the the error involves a subscript error with subscript 2on ACID_CONCENTRATION. If there are only a few places where ACID_CONCENTRATION is referenced then you can place some diagnostic code that conditionaly compiles infront of the references. This can do a quick range check and bugcheck when appropriate.
Jim Dempsey
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, this is what I've being doing for 3 days now...
Unfortunately in most cases there are many references to the variable listed inthe exception window. I've being putting write statements before every occurrence, to find out which one is causing the problem. Also I can only find one at a time - I fix this one, then move onto the next. I've found 6 bits of bad code in 3 days, not a very efficient way to debug.
In my opinion, this is exactly the type of problem the Intel debugger is supposed to identify and stop (which it does), *and* point to the actual line where the problem occurs. CVF had no problem with this - it also used to give line numbers in the exception window.
Steve, please tell me this is being fixed as a matter of urgency...
Adrian
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, that's exactly what I did yesterday! Seems like we old Fortran diehards have learnt all the same tricks...
The only problem with this approach is that it only works when the array isread (eg. if(subchk1(i)) then...). When it s written to, you have to change all these to the new variable name. But that wasn't such a problem, and it enabled me to catch a number of array over/underuns in one routine.
I await the fix with aniticipation...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The replacement macro works on the left side the the = too.
Code:
module aModule
real(8) :: array(100)
contains
function TheArray(index)
real(8) :: TheArray
integer :: index
TheArray = array(index)
end function TheArray
function iIndex(i)
integer :: iIndex, i
iIndex = i+1
end function iIndex
end module aModule
program FuncTest
use aModule
implicit none
! Variables
integer :: i
! Body of FuncTest
do i=1,10
array(iIndex(i)) = real(i)
end do
do i=1,10
write(*,*) TheArray(i)
end do
end program FuncTest
You should see 0., 1., 2., ...
Recode the indexing functions to suit your array. You could make it generic whereby the test function also test shape, rank, etc.. as well as allocation.
The macro method is quite useful becase you can enable and disable it with one compiler variable.
Jim Dempsey
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Here is a better example
Code:
module aModule
real(8) :: was_array(10)
contains
function iChk(i)
integer :: iChk, i
iChk = i
if((i .lt. lbound(was_array,dim=1)) .or. (i .gt. ubound(was_array,dim=1))) then
write(*,*) "gotcha - i=", i
#ifdef _DEBUG
iChk = lbound(was_array,dim=1)
#else
stop
#endif
endif
end function iChk
end module aModule
! in common header file
#define array(i) was_array(iChk(i))
program FuncTest
use aModule
implicit none
! Variables
integer :: i
! Body of FuncTest
do i=1,10
array(i) = real(i)
end do
do i=1,10
write(*,*) array(i)
end do
array(0) = 0.
array(11) = 11.
array(-1) = -1.
end program FuncTest
Jim Dempsey
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page