Re: Breakpoints are not triggered in analyze.c (debugging Postgresql in Visual studio)

From: "ygnhzeus" <ygnhzeus(at)gmail(dot)com>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "pgsql-general" <pgsql-general(at)postgresql(dot)org>
Subject: Re: Breakpoints are not triggered in analyze.c (debugging Postgresql in Visual studio)
Date: 2014-01-17 03:26:08
Message-ID: 52D8A2CC.2000200@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi Tom,
I'm debugging the /backend/commends/analyze.c.
I've set up a Function breakpoint in visual studio,but seems no luck, T_T

2014-01-17

ygnhzeus

发件人:Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
发送时间:2014-01-16 23:31
主题:Re: [GENERAL] Breakpoints are not triggered in analyze.c (debugging Postgresql in Visual studio)
收件人:"Felix.徐"<ygnhzeus(at)gmail(dot)com>
抄送:"pgsql-general"<pgsql-general(at)postgresql(dot)org>

=?GB2312?B?RmVsaXgu0Ow=?= <ygnhzeus(at)gmail(dot)com> writes:
> I've set up a developing environment on my windows using Visual Studio
> 2012, everything works fine, except that the breakpoints set in analyze.c
> are not triggered in debug mode (breakpoints in main.c and some
> initialization code worked well), and I'm sure that line has been executed
> since my own messages have been printed on the console. Does anyone have
> any experience debugging postgresql in Visual Studio?

There are two different source files named analyze.c; I wonder which one
the debugger thinks you are talking about ...

In gdb, the solution for this is to always start by setting a breakpoint
by function name. Once you're stopped in a particular source file, gdb
will assume that that file is meant by "b linenumber" references. Perhaps
the same kind of trick will work with VS.

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Merlin Moncure 2014-01-17 03:46:42 Re: Any freeware graphic display of DDL software available?
Previous Message John R Pierce 2014-01-17 00:24:52 Re: Any freeware graphic display of DDL software available?