Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1w7p9U-005jHy-2O for pgsql-hackers@arkaria.postgresql.org; Wed, 01 Apr 2026 06:34:08 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1w7p9T-00FCU1-0f for pgsql-hackers@arkaria.postgresql.org; Wed, 01 Apr 2026 06:34:07 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1w7p9S-00FCTm-30 for pgsql-hackers@lists.postgresql.org; Wed, 01 Apr 2026 06:34:07 +0000 Received: from mail-pj1-x102d.google.com ([2607:f8b0:4864:20::102d]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1w7p9Q-000000025vO-2gbh for pgsql-hackers@lists.postgresql.org; Wed, 01 Apr 2026 06:34:06 +0000 Received: by mail-pj1-x102d.google.com with SMTP id 98e67ed59e1d1-35d971fb6f1so3289823a91.0 for ; Tue, 31 Mar 2026 23:34:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1775025244; x=1775630044; darn=lists.postgresql.org; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=FocCGezc5nobQ8TMlbBCYXspwj7ofKyHT0mfotUz1Qg=; b=fL93BL8JtuWnNUBeDzGXD0rSTHS7mhCrIUSccIsXVmpVlFb+Sgwqs2OA4uGYkmf1PH S9d1Adv/0n12TCnKdm1O5vfW2bzR9Zk7QSnUc9Rqn9TpJTBNFznBqSZR5M++NN/WupbG FymOe0h+Yews2t4VZoo/zDAy+bUM3H0xHb4bu7aaCy5AmmfLd00E8k0rZbl1xnlf+GoE YsdALxraS52zjG2efuJNzvAl3Uq3fVlHV5Coy0X1UJHPQmkEb9PUBlLITEoD7Y2DKhJq PvG55omp2eAgHfUanerfefi7yHbv2Gky2tNF3WeDh1cB/rhR1+x0YbFYwMa2EvnlZP3O F2FQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1775025244; x=1775630044; h=to:references:message-id:content-transfer-encoding:cc:date :in-reply-to:from:subject:mime-version:x-gm-gg:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=FocCGezc5nobQ8TMlbBCYXspwj7ofKyHT0mfotUz1Qg=; b=XArv6Jk5JP7T5lhi9dQXvX5UnubozwJEowi4iHel13IYxJNrHJ3yu3GMcAWMUuvEPl ncL7rWKb7iZWCKzKt42po95ot3fmqZID/0uMZ1Bep7aAmQ+omCx+oGSyMC/EE+cb4tCL S+fioxeG/g8FEgsaQYmemETQ3Ih3CyPWB4qZalbiXYTk9uYw5V1qfweT7eVIlNmfbunx 2/CzbelbatG9kewZkVZpNbbsiovK1Fjd93MuhnPs0yBIZZozLWRBGMdIBnNECfWOpc3d 4DJiS1JmP64k7P4anFDxiUd2EMTNl0XxyaUWXU1BYknwYtLez7+6c/RMa3nHLtuGGX1F quuQ== X-Forwarded-Encrypted: i=1; AJvYcCXrl1KXwlAVTbAENZay4VyWs2W2L20LNcZRB/mAsrupC7/qHffY1Yz7xbSNYiK4oVWpor1PU2IDCdl07AAm@lists.postgresql.org X-Gm-Message-State: AOJu0Yz/VmkUH5h2RVhkgpCxOuXqpg41FcgwRYdWOdSKg0uKL7H4dh4t 3ZuEk89GhcHbVntHPdUaQ7jBaN1marNC4qaP9r7y4M1FrCsjiG2W36Bj X-Gm-Gg: ATEYQzzpcH3JJCIDZFq9aqsmXZjlKpLTzjMV62nGrTvzMNl1Dn3YiB/9ELXc6OUwaIN 8fdFm4FzzNfP5Go/SXs04IEvwfF/ALuY8EtM32MRUeV0Xg1ReoNq1w7er1TifTY9iykiAqOgVkX dlcVJb3MECbMOClh6zzehibAPZm3x6BCRQcyZUxZFxqoqRf+Z7Y9+/fv1HOLvfL1tmemiiLxPj2 iWb2nZF7s4fZkwr/rRXo4OPH7cmpLuZ4IxRpdzQz5l2bx/p0EsZeg6BTjTn7vmpV9MSEWe97iCx xorYsKsqdcJv18AD98YJ9ASRDBIq/NVWisOEw4hT3+lL7nVSfWvAHIRlaYcOMYgTS22b2HMfD/k IYbEXbXK4lIfe/FenbcbEQg8NKPlibjz/IEhPqev1fGqjyiX6h4n8FXEoH6dSV9BD91F5D81ETg t+XYaqwRx/Zzn0x1Ws6HVxDfkEKu0orAUh X-Received: by 2002:a17:90b:4c8e:b0:34c:2db6:578f with SMTP id 98e67ed59e1d1-35dc6f6a323mr2208220a91.19.1775025243656; Tue, 31 Mar 2026 23:34:03 -0700 (PDT) Received: from smtpclient.apple ([185.135.79.125]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-35dbe5e5127sm4872435a91.1.2026.03.31.23.34.01 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Tue, 31 Mar 2026 23:34:02 -0700 (PDT) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3864.400.21\)) Subject: Re: table AM option passing From: Chao Li In-Reply-To: <202603311555.w42t5agupy3z@alvherre.pgsql> Date: Wed, 1 Apr 2026 14:33:28 +0800 Cc: Andres Freund , Pg Hackers , Zsolt Parragi , Nathan Bossart Content-Transfer-Encoding: quoted-printable Message-Id: <40E570EE-5A60-49D8-B8F7-2F8F2B7C8DFA@gmail.com> References: <202603311555.w42t5agupy3z@alvherre.pgsql> To: =?utf-8?Q?=C3=81lvaro_Herrera?= X-Mailer: Apple Mail (2.3864.400.21) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk > On Apr 1, 2026, at 00:10, =C3=81lvaro Herrera = wrote: >=20 > Hi, >=20 > On 2026-Mar-30, =C3=81lvaro Herrera wrote: >=20 >> I just pushed the part of 0001 that modifies the API of table_insert = and >> its sibling functions. So here 0001 adds the options bitmask to >> table_update and table_delete, which is important for REPACK; and = 0002 >> is identical as before and makes the interface (IMO) a bit more >> future-proof. >=20 > FWIW I just posted 0001 as part of the repack series here [1]; 0002 is > inessential, so I didn't; but here's both of them. I have drafted > commit messages also. >=20 > [1] https://postgr.es/m/202603311523.iqhng5ljkzpq@alvherre.pgsql >=20 > --=20 > =C3=81lvaro Herrera 48=C2=B001'N 7=C2=B057'E =E2=80=94 = https://www.EnterpriseDB.com/ > "Pensar que el espectro que vemos es ilusorio no lo despoja de = espanto, > s=C3=B3lo le suma el nuevo terror de la locura" (Perelandra, C.S. = Lewis) > = Looks like v4-0001/0002 are pure refactoring. A few small comments: 1 - 0001 For table_tuple_delete(), options is added and changingPart is removed, = but the header comment should be updated to reflect the change. 2 - 0002 For table_tuple_update(), options is added, the header comment should be = updated as well. 3 - 0002 Now TABLE_INSERT_SKIP_FSM, TABLE_INSERT_FROZEN, TABLE_INSERT_NO_LOGICAL = belong to the same options word as HEAP_INSERT_SPECULATIVE, but they are = still defined as: ``` #define TABLE_INSERT_SKIP_FSM 0x0002 #define TABLE_INSERT_FROZEN 0x0004 #define TABLE_INSERT_NO_LOGICAL 0x0008 ``` Could it make sense to change them to the left-shift form? 4 - 0002=20 In heap_multi_insert(), heap_prepare_insert(), and heap_insert(), = options is defined as uint32, but in RelationGetBufferForTuple() and = raw_heap_insert() it is still defined as int. Would it make sense to = take this opportunity to change all =E2=80=9Coptions" to uint32 for = consistency? Otherwise, if this is left for later, a trivial follow-up = patch just to change int to uint32 may be harder to get processed. Best regards, -- Chao Li (Evan) HighGo Software Co., Ltd. https://www.highgo.com/