Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Community » U++ community news and announcements » TheIDE PDB debugger now understands some U++ types
TheIDE PDB debugger now understands some U++ types [message #52770] Fri, 22 November 2019 10:31 Go to next message
mirek is currently offline  mirek
Messages: 12124
Registered: November 2005
Ultimate Member
So, this is for PDB debugger (one for Visual C++ compiler only) and it is limited, hardcoded and otherwise ugly implementation, plus there is some work left to do (support more types, support structured browsing), but in general I think it is already useful feature:

index.php?t=getfile&id=5943&private=0

[Updated on: Fri, 22 November 2019 10:35]

Report message to a moderator

Re: TheIDE PDB debugger now understands some U++ types [message #52771 is a reply to message #52770] Fri, 22 November 2019 15:07 Go to previous messageGo to next message
unodgs is currently offline  unodgs
Messages: 1355
Registered: November 2005
Location: Poland
Senior Contributor

Very cool, I was missing that so many times Smile
Re: TheIDE PDB debugger now understands some U++ types [message #52772 is a reply to message #52770] Fri, 22 November 2019 17:41 Go to previous messageGo to next message
zsolt is currently offline  zsolt
Messages: 601
Registered: December 2005
Location: Budapest, Hungary
Contributor
Thanks a lot!
Re: TheIDE PDB debugger now understands some U++ types [message #52798 is a reply to message #52770] Thu, 28 November 2019 12:25 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 12124
Registered: November 2005
Ultimate Member
"recognized high-level types" are now supported in expressions:

index.php?t=getfile&id=5948&private=0
Re: TheIDE PDB debugger now understands some U++ types [message #52800 is a reply to message #52770] Fri, 29 November 2019 02:41 Go to previous messageGo to next message
zsolt is currently offline  zsolt
Messages: 601
Registered: December 2005
Location: Budapest, Hungary
Contributor
How can I activate it?
I have compiled current Git version with MSC 2017 64 bit, but it seems to be working in the old way.
Re: TheIDE PDB debugger now understands some U++ types [message #52801 is a reply to message #52800] Fri, 29 November 2019 09:13 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 12124
Registered: November 2005
Ultimate Member
zsolt wrote on Fri, 29 November 2019 02:41
How can I activate it?
I have compiled current Git version with MSC 2017 64 bit, but it seems to be working in the old way.


Should work out of box-> something is wrong.

Core should be trunk version for Value recogniction.

Project must be compiled with MSC.

Not all U++ types are supported. Check ide/debuggers/Pretty.cpp for the list of types currently supported:

		pretty.Add("Upp::Date", { 0, THISFN(PrettyDate) });
		pretty.Add("Upp::Time", { 0, THISFN(PrettyTime) });
		pretty.Add("Upp::ValueArray", { 0, THISFN(PrettyValueArray) });
		pretty.Add("Upp::ValueMap", { 0, THISFN(PrettyValueMap) });
		pretty.Add("Upp::Value", { 0, THISFN(PrettyValue) });
		pretty.Add("Upp::String", { 0, THISFN(PrettyString) });
		pretty.Add("Upp::WString", { 0, THISFN(PrettyWString) });
		pretty.Add("Upp::Vector", { 1, THISFN(PrettyVector) });
		pretty.Add("Upp::BiVector", { 1, THISFN(PrettyBiVector) });
		pretty.Add("Upp::Array", { 1, THISFN(PrettyArray) });
		pretty.Add("Upp::BiArray", { 1, THISFN(PrettyBiArray) });
		pretty.Add("Upp::Index", { 1, THISFN(PrettyIndex) });
		pretty.Add("Upp::VectorMap", { 2, THISFN(PrettyVectorMap) });
		pretty.Add("Upp::ArrayMap", { 2, THISFN(PrettyArrayMap) });

		pretty.Add("std::vector", { 1, THISFN(PrettyStdVector) });
		pretty.Add("std::basic_string", { 1, THISFN(PrettyStdString) });


If none of those helps, we will have to dig into it... E.g. for starters, testcase would help.

Is debugged code 32 or 64?
Re: TheIDE PDB debugger now understands some U++ types [message #52803 is a reply to message #52801] Fri, 29 November 2019 13:47 Go to previous messageGo to next message
zsolt is currently offline  zsolt
Messages: 601
Registered: December 2005
Location: Budapest, Hungary
Contributor
It was my fault. Works perfectly.
It's very easy to debug this way. Thank you!
Re: TheIDE PDB debugger now understands some U++ types [message #52804 is a reply to message #52803] Fri, 29 November 2019 15:00 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 12124
Registered: November 2005
Ultimate Member
Tree view now can be used to see any element:

index.php?t=getfile&id=5949&private=0
Re: TheIDE PDB debugger now understands some U++ types [message #52807 is a reply to message #52804] Sat, 30 November 2019 16:42 Go to previous messageGo to next message
koldo is currently offline  koldo
Messages: 3045
Registered: August 2008
Ultimate Member
Thank you Mirek. Debugger is very improved.
How do you access to tree view?


Best regards
Iñaki
Re: TheIDE PDB debugger now understands some U++ types [message #52810 is a reply to message #52807] Sun, 01 December 2019 16:07 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 12124
Registered: November 2005
Ultimate Member
koldo wrote on Sat, 30 November 2019 16:42
Thank you Mirek. Debugger is very improved.
How do you access to tree view?


Click the line with the value.
Re: TheIDE PDB debugger now understands some U++ types [message #52811 is a reply to message #52810] Sun, 01 December 2019 21:54 Go to previous messageGo to next message
koldo is currently offline  koldo
Messages: 3045
Registered: August 2008
Ultimate Member
Very smart! Laughing

Let me show to the Forum the full picture.
The trick was to insist some times on moving the right vertical bar to the left.

index.php?t=getfile&id=5950&private=0


Best regards
Iñaki

[Updated on: Sun, 01 December 2019 21:57]

Report message to a moderator

Re: TheIDE PDB debugger now understands some U++ types [message #52814 is a reply to message #52811] Tue, 03 December 2019 11:10 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 12124
Registered: November 2005
Ultimate Member
Could not resist:

index.php?t=getfile&id=5951&private=0
Re: TheIDE PDB debugger now understands some U++ types [message #52824 is a reply to message #52814] Fri, 06 December 2019 10:21 Go to previous messageGo to next message
koldo is currently offline  koldo
Messages: 3045
Registered: August 2008
Ultimate Member
Really useful.

Could you add a copy to clipboard option to get the variable text?


Best regards
Iñaki
Re: TheIDE PDB debugger now understands some U++ types [message #52826 is a reply to message #52824] Sat, 07 December 2019 23:12 Go to previous messageGo to next message
Klugier is currently offline  Klugier
Messages: 644
Registered: September 2012
Location: Poland, Kraków
Contributor
Hello koldo,

Some time ago I implemented feature for GDB that copy the text to the clipboard from the tree. Optimally, we should have the same functionality for PDB with the shared code to reduced code maintenance. I also planned to add window that will open when you want to examine full string value inside TheIDE. This functionallity should also be shared between debuggers. This is optimal implementation to not favor any of debugger. Especially that PDB is not available on Linux.

I think above improvements are great, but they are not present with the GDB back-end. Mirek, do you think we can port this functionality without much effort (by extracting common code?)?

Sincerely,
Klugier


Ultimate++ - one framework to rule them all.
Re: TheIDE PDB debugger now understands some U++ types [message #52830 is a reply to message #52826] Sun, 08 December 2019 08:40 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 12124
Registered: November 2005
Ultimate Member
Klugier wrote on Sat, 07 December 2019 23:12

I think above improvements are great, but they are not present with the GDB back-end. Mirek, do you think we can port this functionality without much effort (by extracting common code?)?


Unfortunately not. That is one of reasons I have resisted these features for so long.

GDB and PDB are completely different beasts. GDB is just issuing text commands to gdb binary via text pipe and interpreting results.

PDB code is really a full featured debugger. It is using Win32 debugging API directly and symbol server to really understand the layout of objects, directly reads debugee memory etc... That are actually requirements to make this kind of functionality possible.

This definitely possible to binaries produced by GCC toolchain too. But it is a LOT of work, probably would involve thorough study of GDB sources and about a year to complete.

Mirek
Re: TheIDE PDB debugger now understands some U++ types [message #52837 is a reply to message #52830] Sun, 08 December 2019 16:27 Go to previous message
Novo is currently offline  Novo
Messages: 893
Registered: December 2006
Experienced Contributor
mirek wrote on Sun, 08 December 2019 02:40

This definitely possible to binaries produced by GCC toolchain too. But it is a LOT of work, probably would involve thorough study of GDB sources and about a year to complete.

IMHO, it is easier to use LLDB, which is available as a lib.

"The LLDB debugger APIs are exposed as a C++ object oriented interface in a shared library. The lldb command line tool links to, and uses this public API."


Regards,
Novo
Previous Topic: Server failure - some services might be temporarily unavailable
Goto Forum:
  


Current Time: Fri Dec 13 07:12:11 CET 2019

Total time taken to generate the page: 0.01144 seconds