Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nXmI3-0003H0-Sg for pgsql-hackers@arkaria.postgresql.org; Fri, 25 Mar 2022 15:55:51 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1nXmI2-0005vD-GW for pgsql-hackers@arkaria.postgresql.org; Fri, 25 Mar 2022 15:55:50 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nXmI2-0005v3-6h for pgsql-hackers@lists.postgresql.org; Fri, 25 Mar 2022 15:55:50 +0000 Received: from mail.thelabyrinth.net ([45.56.70.56]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nXmHz-0002Fx-Vf for pgsql-hackers@postgresql.org; Fri, 25 Mar 2022 15:55:49 +0000 Received: from [10.5.0.2] (unknown [209.58.146.182]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: dsteele) by mail.thelabyrinth.net (Postfix) with ESMTPSA id D76F554669; Fri, 25 Mar 2022 15:55:46 +0000 (UTC) Message-ID: <0befb6fb-d125-95f2-9815-7dbda8086f25@pgmasters.net> Date: Fri, 25 Mar 2022 09:55:45 -0600 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.7.0 Subject: Re: ubsan Content-Language: en-US To: Andres Freund , Tom Lane Cc: pgsql-hackers@postgresql.org References: <20220323173537.ll7klrglnp4gn2um@alap3.anarazel.de> <2771659.1648058090@sss.pgh.pa.us> <20220323182137.hgq4qz57yldtbhwl@alap3.anarazel.de> <20220323192241.tzeo6cu6mvepok53@alap3.anarazel.de> <2784183.1648065489@sss.pgh.pa.us> <20220323201234.nyh2uzot3t6becr5@alap3.anarazel.de> <20220323225528.hqt66d6mpx66hoal@alap3.anarazel.de> From: David Steele In-Reply-To: <20220323225528.hqt66d6mpx66hoal@alap3.anarazel.de> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 3/23/22 16:55, Andres Freund wrote: > > It's particularly impressive that the cost of running with ASAN is *so* much > lower than valgrind. On my workstation a check-world with > -fsanitize=alignment,undefined,address takes 3min17s, vs 1min10s or so without > -fsanitize. Not something to always use, but certainly better than valgrind. It also catches things that valgrind does not so that's a bonus. One thing to note, though. I have noticed that when enabling -fsanitize=undefined and/or -fsanitize=address in combination with -fprofile-arcs -ftest-coverage there is a loss in reported coverage, at least on gcc 9.3. This may not be very obvious unless coverage is normally at 100%. Regards, -David