PVF: How to inspect arrays declared as pointer in watches?

Hi.

I recently migrated to PVF with Visual Studio 2005 from Intel Visual Fortran. I have some large data structures of arrays that are being reallocated dynamically and are declared as pointer. In the Intel debugger I could inspect all elements of these pointer variables as seen below with watches, but with the PVF debugger I only see the first elements in the arrays. How can I get inspect the full arrays?

Regards,

Casper Kirkegaard

real*8, pointer :: Datas(:)

Hi Casper,

It sounds like you are using array slices in the watch window (i.e., Datas(1:5)). If this is not the case, please let me know what you are using instead.

Array slice support is not well supported in the watch window. A TPR has been filed on this issue.

Until such support is available, try using the Immediate window to print the array slice. The Immediate window gives you a direct line to the PVF debug engine. So, for example, you could type “print Datas(1:5)” in this window and get a printout of those elements.

Let me know how that works for you in your debugging situation.

Annemarie

Hi Annemarie.

In the Intel debugger we could just put a watch on Datas and the debugger would know the size of the array and show all entries.

Using the immediate window would work although I find it a bit cumbersome. Inspecting arrays in this way requires more typing and also requires you to look up the array dimensions. Any chance you could make it work like in the Intel debugger?

Regards,

Casper

Hi Casper,

Would you clarify one thing for me? When you put Datas in the Watch window, do you add “Datas” or an array slice like “Datas(1:5)”?

Thanks.

Annemarie

What I would like to do is just add “Datas” to the watch list and have all of the elements listed like in the Intel debugger. When I do this in the PGI debugger I only see the very first element.

Casper,

Thanks for the clarification. I think it should work as you describe; I am going to investigate this further and let you know what I find.

Annemarie

Casper,

Would you please send me the source code for the test case you are working with? I have not been able to reproduce the error from the information you’ve provided.

Thanks.

Annemarie