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 1vnZpL-0091sz-2e for pgsql-hackers@arkaria.postgresql.org; Wed, 04 Feb 2026 10:09:39 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1vnZpK-00Aatc-1j for pgsql-hackers@arkaria.postgresql.org; Wed, 04 Feb 2026 10:09:38 +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 1vnZpK-00AatR-0m for pgsql-hackers@lists.postgresql.org; Wed, 04 Feb 2026 10:09:38 +0000 Received: from mail-wm1-x343.google.com ([2a00:1450:4864:20::343]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1vnZpI-00000000VNW-1y1F for pgsql-hackers@postgresql.org; Wed, 04 Feb 2026 10:09:37 +0000 Received: by mail-wm1-x343.google.com with SMTP id 5b1f17b1804b1-4806f3fc50bso66105635e9.0 for ; Wed, 04 Feb 2026 02:09:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1770199775; x=1770804575; darn=postgresql.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=jUOXjWgxW/OcwINaW2XFT9eOs2Ic+ewEup1XfCDDBEM=; b=XDRcgUYrxhwaB+usJqQB05mVezBOdKVSBAkg3O830URkymLI5iFSo/0ovokiZAb2OV 3W0XgjoezzUplgD+cLvPZ8ByCN+6tgT2Fm9E1BezrKCNOgtK29Wx8jtYNDDuEcUkEMOd b+Rqzlzi/JEqFR13F1eFgVJ/csx/EnG47emd8c4KHuxs3u33H0VdiqHIriOVrkdU7zxy gryR8nSQ6vw0UD8Xwj4DlDCDXX9hkgUQOpgttJ+xuttsvhuVoy0LgkqnW4V69svrHxpX G1D7c2RkbCNGzXMdQEfY76eFnp6k77f78t1GxgiKfNdW1ErctJ1UWrSi32zn6EgY6jkA tZng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1770199775; x=1770804575; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=jUOXjWgxW/OcwINaW2XFT9eOs2Ic+ewEup1XfCDDBEM=; b=Y1tzbThkxVd/kYI5XXFyQJCjLehAmmHWuUP4b/64dHhw7ctM8IodaMGqgnvV+VZX2b dtlLALsITDtrrqYe00D1ZV649azi3n18dBOBr/arRm5npdQleiROjBwuUh+LKpvwg1Wd y/gX9TwXpRlL8kwQDyV9vTQoXkOaCe8stVuFbU1ClP+ZpbZ/aELIomZNdTLAkIM5XJaz H5SPb156MQQIszKdJPGi+wHIMlRqYBJDrgj+rwQ51Xdv7lsE6e2jYu6QPVFt3g4Sp78C hx3yEttE9nLSF1llrothlQh3M/XZbtQbYbL2sAOEUrwPB5RzhxzJTDJDsC5WMPAp3LzD twlg== X-Forwarded-Encrypted: i=1; AJvYcCXXP0fxJcs6bvxETBfmBBL4/23AcLx0ESzXfDH/sC/qXgPFewRh6S4TzoQecAFOgVlSbgu62aSya684YY5O@postgresql.org X-Gm-Message-State: AOJu0YxNfdc3p86nDyHuEVAYWvU4Rjzm/a0pLxwL0Z+fPXDZlYPzR7FW JuqxU5CflUY3obUHCCa/AVcPi2QqbsKOTYIhfXjf9+FfY+O3VAajvVDM X-Gm-Gg: AZuq6aKjFm3BdPi9jWJukmMtHdFQHyC9OrgY+Qv5ZhZb47f63dyA5B8gCgxDEhHEccw NIRKdrw/eAmSYm7iNTiBOwkWdvFDpVV/MSfXfqgcfiRiUT6z/gn3nekTZQqfdXKnL8wRtEVZ/M6 jpiIcT8oR/B9QEGYCkfk/vkJfv0Dbma6rJmljef94Ly5ftSxMAHsJI3TEHKPom2393JPZj9tALP RtEyYaq7syE2hVbEG8B/BZ3M2ci8N9lB6kSGcapH5hzCvWKZnPV12+4EEIYrArdtK9VhHy6Y5GM SpG1Eq8e2gnMQ76ItdiqIYQXWaDIvoeVxL4dBhnqG2Ypy6CVGnAqOE0YCRNFeo5qorEGQlU7odz k3v+n3HEbbU7XEsFMhgMiq91Fm7z0b2dfqsvGT2EJFsN8E1WSz6wsRQ9chXYUMFymfc2/Dsb5Zs 0mTtd/gQ== X-Received: by 2002:a05:600c:34c3:b0:480:1a3a:5ce6 with SMTP id 5b1f17b1804b1-4830e93ddd9mr32241995e9.14.1770199774779; Wed, 04 Feb 2026 02:09:34 -0800 (PST) Received: from [172.31.5.233] ([165.225.27.6]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4830ec53159sm17256055e9.4.2026.02.04.02.09.33 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 04 Feb 2026 02:09:34 -0800 (PST) Message-ID: <1e0462f0-8274-4d57-aa39-9b6ebeb954da@gmail.com> Date: Wed, 4 Feb 2026 11:09:32 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: Reduce timing overhead of EXPLAIN ANALYZE using rdtsc? To: Andres Freund , Jakub Wartak Cc: Lukas Fittl , Hannu Krosing , Robert Haas , Pavel Stehule , vignesh C , Michael Paquier , Ibrar Ahmed , Maciek Sakrejda , pgsql-hackers References: <7717ba64-9283-49ec-aa3f-34c6de848b93@gmail.com> <3bdce15d-25ec-4c49-9906-818803462897@gmail.com> Content-Language: en-US From: David Geier In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 03.02.2026 18:44, Andres Freund wrote: > Yea, I doubt this is the right path... Particularly because I really think we > ought to eventually use this not just on linux but other OSs as well. +1 >> BTW, -1 to fast_clock_source, +1 to clock_source or maybe >> explain_clock_source(?) > > Hm. I think it'd make sense to use eventually use this clock source for other > timing tasks too, not just explain. E.g. pg_stat_statements could benefit > quite a bit from reducing the timing overhead. > > Whereas it'll not make sense for anything that needs wall clock times - which > imo makes a "clock_source" GUC misnamed. Maybe "clock_source_timing" or such? Makes sense. clock_source_timing works for me, or maybe easier to read would be timing_clock_source. But doesn't matter much. -- David Geier