Jump to content
MathewV

Debugging Issues in D11 64Bit with Packages

Recommended Posts

Is anyone else having issues where you step into a DLL function and all you get is the CPU screen?

 

There are so many reasons why we want to move our 25 year Delphi project to D11, but this one is stopping us and there has been no traffic on the RSP that has been added (https://quality.embarcadero.com/browse/RSP-35879)

I recorded a video here https://www.screencast.com/t/qEOV7MO00Jq and you can download the OP's sample project from the RSP. 

 

If this is a user/setting error, please let me know! 

Share this post


Link to post

I know about problems when trying to debug application built with packages. There are multiple open tickets and now we just have to wait for a solution.

Share this post


Link to post
7 hours ago, MathewV said:

Is anyone else having issues where you step into a DLL function and all you get is the CPU screen?

 

There are so many reasons why we want to move our 25 year Delphi project to D11, but this one is stopping us and there has been no traffic on the RSP that has been added (https://quality.embarcadero.com/browse/RSP-35879)

I recorded a video here https://www.screencast.com/t/qEOV7MO00Jq and you can download the OP's sample project from the RSP. 

 

If this is a user/setting error, please let me know! 

I have not been working with DLL projects much in the past and never with 64 bit DLLs, but usually one had to debug the DLL project, set the host application to use in the Run -> Parameters dialog, set a breakpoint in the DLL funtion of interest, and then just run. Do the required actions in the host to end up in the DLL at the breakpoint.

If you end up in the CPU view this means that the debugger cannot find the debug information for the code you stepped into. Make sure you build the DLL with debug information. 64-bit apps are debugged in a kind of remote debugger session since the IDE is a 32 bit process. So make sure you have enabled "include remote debug symbols" in the linker options.

  • Like 1

Share this post


Link to post
1 hour ago, PeterBelow said:

make sure you have enabled "include remote debug symbols" in the linker options.

This applies even to 32-bit DLLs/packages in my experience.

Share this post


Link to post
9 hours ago, Lajos Juhász said:

I know about problems when trying to debug application built with packages. There are multiple open tickets and now we just have to wait for a solution.

Yes, I'm hoping that someone with some influence will be able to raise this with them. With the new focus on "Win32" dev by Microsoft, this is in Delphi's interest to work with us all on getting this right. We're all developers, we know what it is like to debug strange issues. It is that they ignore these issues while pushing new features that frustrates me.

 

7 hours ago, PeterBelow said:

I have not been working with DLL projects much in the past and never with 64 bit DLLs, but usually one had to debug the DLL project, set the host application to use in the Run -> Parameters dialog, set a breakpoint in the DLL funtion of interest, and then just run. Do the required actions in the host to end up in the DLL at the breakpoint.

If you end up in the CPU view this means that the debugger cannot find the debug information for the code you stepped into. Make sure you build the DLL with debug information. 64-bit apps are debugged in a kind of remote debugger session since the IDE is a 32 bit process. So make sure you have enabled "include remote debug symbols" in the linker options.

Thanks for the suggestions. It is set "correctly" to my understanding and has never been an issue in all Delphi versions before 10.2 (granted that we changed our 5 million line project to 64bit in 10.2 so before that it was 32bit). The sample program I used in the video is unchanged between 10.2 and 11. My hope would be that if I could debug in 10.2 then I should be able to in 11 without needing to change settings. 

 

4 hours ago, Lars Fosdal said:

The debuggers need a lot of care.  The current state is abysmal - particularly for 64-bit.

Personally, I think it's time that they made Delphi a 64-bit program, written in Delphi! I remember in Delphi 1 Borland marketed that they wrote Delphi in Delphi (chicken and the egg comes to mind). I wish they would do the same now and then they would see what we are dealing with. Still, the small sample app shows this issue so well, I just wish they would engage with us on this so that we can use D11 and Delphi keeps getting better.

Share this post


Link to post

Very happy to say that it all works in D11.1 - we can finally move from D10.2 and it's frustrating compiler errors.

 

I love Delphi but I still feel that their communication with us on issues like this is appalling. They should welcome engagement from their users. We all want Delphi to be the best development platform in the world so we can get on with our work and they have an even better product. I feel that as a user of Delphi for over 26 years counts for nothing with them and I write this in the hope that someone internal sees it and it sparks an internal discussion on how they engage with us.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×