Re: [PATCH] Improve function toast_delete_external (src/backend/access/table/toast_helper.c)

From: Dong Wook Lee <sh95119(at)gmail(dot)com>
To: Ranier Vilela <ranier(dot)vf(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: [PATCH] Improve function toast_delete_external (src/backend/access/table/toast_helper.c)
Date: 2022-02-09 14:33:47
Message-ID: CAAcByaJK_ivH2555T2kwDa4h67eh+U8eXTRctp_OjodmFyctXw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

I've applied your patch. I think it's reasonable.
but IMHO It looks more complicated to read because of many conditions
in if statement.
so what about just moving up if-statement?

Thanks.
Dong Wook Lee

2022년 2월 9일 (수) 오후 7:56, Ranier Vilela <ranier(dot)vf(at)gmail(dot)com>님이 작성:
>
> Hi,
>
> I think this change can improve this particular function by avoiding touching value if not needed.
> Test if not isnull is cheaper than test TupleDescAttr is -1.
>
> best regards,
>
> Ranier Vilela

Attachment Content-Type Size
v2_tiny_improvemnt_toast_helper.patch application/octet-stream 591 bytes

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Dagfinn Ilmari Mannsåker 2022-02-09 14:34:08 Re: Replacing TAP test planning with done_testing()
Previous Message Julien Rouhaud 2022-02-09 14:29:01 Re: Add tag/category to the commitfest app