lldb problems with Xcode 8.2.1

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

lldb problems with Xcode 8.2.1

Jeremy Thompson
Hello all,

I am experiencing some LLDB problems in macOS Sierra 10.12.3 with Xcode 8.2.1.  Its running the LLVM compiler with FPC 2.6.4.  I can no longer get breakpoints to function, they get skipped over.  Also when pausing or catching an exception no local or global variables show up.  My debug scheme for Xcode has the FPC compiler running these options:

-ghlttt -O-1 -CRiot -gw2 -gl

and the LLVM compiler debug scheme is running with no optimizations.  The debug format is set to DWARF and symbols are not being stripped.  When I tried running my program out of LLDB through terminal and try to set a breakpoint I get this:

(lldb) b s start.pas:12
Breakpoint 1: no locations (pending).
WARNING:  Unable to resolve breakpoint to any actual locations.

This setup was working fine on macOS 10.12.1.  There seems to be some talk about this on apple message boards and stack overflow but none of the leads have really gone anywhere.  Any help would be greatly appreciated. 

Thanks,
Jeremy




_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

signature.asc (859 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: lldb problems with Xcode 8.2.1

Jonas Maebe-3

> On 23 Feb 2017, at 19:10, Jeremy Thompson <[hidden email]> wrote:
>
> I am experiencing some LLDB problems in macOS Sierra 10.12.3 with Xcode 8.2.1.  Its running the LLVM compiler with FPC 2.6.4.  I can no longer get breakpoints to function, they get skipped over.

Short answer: update to FPC 3.0.2 and use its -godwarfcpp option.

The long answer will have to wait till tonight.


Jonas
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: lldb problems with Xcode 8.2.1

Jonas Maebe-3
On 24/02/17 08:40, Jonas Maebe wrote:
>
>> On 23 Feb 2017, at 19:10, Jeremy Thompson <[hidden email]> wrote:
>>
>> I am experiencing some LLDB problems in macOS Sierra 10.12.3 with Xcode 8.2.1.  Its running the LLVM compiler with FPC 2.6.4.  I can no longer get breakpoints to function, they get skipped over.
>
> Short answer: update to FPC 3.0.2 and use its -godwarfcpp option.
>
> The long answer will have to wait till tonight.

The long answer is that since some people have started working on (very
preliminary) Pascal support in lldb, at some point they disabled pretty
much all C/C++ functionality for non-C/C++ languages in lldb. With as a
result that almost nothing works anymore if the debug information
specifies that the source language is Pascal, and simply changing it to
claim that the program was compiled from C or C++ (which is more or less
what -godwarfcpp does) restores the debugger functionality.


Jonas

_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal
Reply | Threaded
Open this post in threaded view
|

Re: lldb problems with Xcode 8.2.1

Matthew Drayton
In reply to this post by Jeremy Thompson
> I can no longer get breakpoints to function, they get skipped over.

This is fixed in the latest Xcode 8.3 beta.

You’ll still need to use Jonas’ suggestion of upgrading to FPC 3.0.2 and use the -godwarfcpp option to get lldb/Xcode to do the right thing once a breakpoint is triggered.

–Matt
_______________________________________________
fpc-pascal maillist  -  [hidden email]
http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal