From: | Tatsuo Ishii <ishii(at)postgresql(dot)org> |
---|---|
To: | li(dot)evan(dot)chao(at)gmail(dot)com |
Cc: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Raw parse tree is not dumped to log |
Date: | 2025-08-18 09:13:15 |
Message-ID: | 20250818.181315.1108260969926873357.ishii@postgresql.org |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
>> --- a/src/backend/tcop/postgres.c
>> +++ b/src/backend/tcop/postgres.c
>> @@ -649,6 +649,10 @@ pg_parse_query(const char *query_string)
>> TRACE_POSTGRESQL_QUERY_PARSE_DONE(query_string);
>> + if (Debug_print_raw_parse)
>> + elog_node_display(LOG, "raw parse tree", raw_parsetree_list,
>> + Debug_pretty_print);
>> +
>>
>> I'm tempted to change "if (Debug_print_raw_parse)" to:
>>
>> if (unlikely(Debug_print_raw_parse))
>>
>> But as we have similar if-statements elsewhere
>> (e.g. Debug_print_parse), maybe we should keep it for a separate
>> commit.
>>
> I have added "unlikely" here. For other places, I can use a separate
> commit to add "unlikely".
--- a/src/backend/tcop/postgres.c
+++ b/src/backend/tcop/postgres.c
@@ -649,6 +649,10 @@ pg_parse_query(const char *query_string)
TRACE_POSTGRESQL_QUERY_PARSE_DONE(query_string);
+ if (unlikely(Debug_print_parse))
This should be:
+ if (unlikely(Debug_print_raw_parse))
Best regards,
--
Tatsuo Ishii
SRA OSS K.K.
English: http://www.sraoss.co.jp/index_en/
Japanese:http://www.sraoss.co.jp
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Paquier | 2025-08-18 09:15:22 | Re: test_ddl_deparse: Rename test create_sequence_1 |
Previous Message | vignesh C | 2025-08-18 09:13:13 | Re: Logical Replication of sequences |