Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp4874134ybi; Sat, 6 Jul 2019 15:45:45 -0700 (PDT) X-Google-Smtp-Source: APXvYqwI2pU1pyAvNPhG2JR1UQGKd+AkBdzrM4hBLg7bgy+TgA7t2kjRmDRWSV3pwBk9Uk3267of X-Received: by 2002:a17:90a:26e4:: with SMTP id m91mr13999392pje.93.1562453145863; Sat, 06 Jul 2019 15:45:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562453145; cv=none; d=google.com; s=arc-20160816; b=N4fvDpXKje4diOE0Agu1YPGN6COt0/pKlJ35J9090Zqdx2TREWkhKWUW/sxH7YrwN0 hBHXiLmXV4NpSmNUzxpmsRxAHUiIc25cz22vn9+loPSa7zP1t6fNSG1hjR9iheNsDw+u 81Vz20d442ZB1GsL6pvd9yhgnQhmJKYFBdKf7K085NYeOJ53v5KTYEIUouu8rsI7oStp 538Rr7+i+6eTEXeC2Ihj+NsYj/qeGp+jTTtmM64r52S3g3BCI7/UpQW6/jd44XGGWMcv owCALcm1U3xcANVOx0JHDBWbhteVgmkVP/fo/1NJiiRbXh5p41qVQI/pzw0cJIJXYPVZ 6jxA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :message-id:in-reply-to:subject:cc:to:from:date:dkim-signature; bh=KZuwwpEDFFidTZvCB013aANFUOOg31tF9n5M77JSn6w=; b=ATZSZP89Vw7L7XdsWr6Twmm3gvR1uzOdvCThgf42mqdNMJDhPgnl/3Wj2yd3e62mFz qXddkw9Z1CqjNiT1yPiBAp3fO0w04f/cYoy+IkQ01eXOvWnh5LqYmB3PDdVsrXobqQX2 6x8fzLAH5LEYfu5Cf5eNgu9yMJM3mdUlWdsunwf92PRCDPP7CvX9lOWSWSTmrdVQdpNg uv0wCXieOJhWc9MP9AbZX50aMIaBzLVDNqTwoMG8eII0RuTVVoZG+rhHUaCvpP2GCztf W3J2fK5aAx40Ts60CBkHVXXSqOPsYaobqwWlO1hFWXdMRv6nza7eFIBqSQ3Y9K52xMgY uYkA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=L2olCuuA; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m42si12084032pje.31.2019.07.06.15.45.31; Sat, 06 Jul 2019 15:45:45 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=L2olCuuA; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726865AbfGFWpN (ORCPT + 99 others); Sat, 6 Jul 2019 18:45:13 -0400 Received: from mail-pf1-f196.google.com ([209.85.210.196]:43148 "EHLO mail-pf1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726586AbfGFWpM (ORCPT ); Sat, 6 Jul 2019 18:45:12 -0400 Received: by mail-pf1-f196.google.com with SMTP id i189so5773258pfg.10 for ; Sat, 06 Jul 2019 15:45:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:from:to:cc:subject:in-reply-to:message-id:references :user-agent:mime-version; bh=KZuwwpEDFFidTZvCB013aANFUOOg31tF9n5M77JSn6w=; b=L2olCuuAvGq0806TGK59wMZhuTO9EVAfk3ga/cDt+R/5EhMP0+heHReCNlnPQDSkGp zGOPzi9ERGBvpgjYMxEVfHRrpbbXjbg9Tumnson9Aj9d9S6tOlEMiXFMwzktp7ZoFa3j 3V4SxfHzDv2eIU000+5AZUoa1Vtg/lRF68Rlt5ugGh4CRwA4IKmmpjhUDLoci2ZaePqX HSR3SKOK5gu0GgWUlM9Rx0PxavwGWVtiwv6Ta5AOjENY0n47KgVxkOLu73lQUOx9c9sL IpfijZ2PChnxS65QjOoFAk9wJ0S9i/zj+e2Oc8PK+C/M1rSSj52DmRST89qhWX1QIG1e nXpw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:in-reply-to:message-id :references:user-agent:mime-version; bh=KZuwwpEDFFidTZvCB013aANFUOOg31tF9n5M77JSn6w=; b=Gzl2GEAI44ISchPYPsCeNqnHriindSd9b0Rvj1VYzjH+c/D4cyt1KrTzxC1Jwiab/1 EgRx0Ks89bx4grUbYVffhQ3UI886B6+AFtobJGfi2fvpfzWpjFpHbYuI7Zv0Nb+O2cIA JOO24JQwyZF2lD+bamCzr0p3OAua9WkkpBekuci57JPunEfwFP5nqfEB7mX3G8l5eLtq CiGx77ESxE0wLza/qJhUdny3Fd4gaLYLorVOZCm3Ro0PHZQ0LGMVwBHTN/6pztRDBQ42 uPRUPu/8iO8VFdwxyoz02REutS6d6amlHPjptChMh5GdyH4jlLUBQtYVKPoKpWINJb+P 81JQ== X-Gm-Message-State: APjAAAWlKNDpSNOWrAmTNCG0Ui8oE1fY7k3IgFR5R/vWSRnudGkAzTiG TQcQkUuSTdYnP5UF0nGEQOXG0g== X-Received: by 2002:a17:90a:d3d4:: with SMTP id d20mr14263697pjw.28.1562453111723; Sat, 06 Jul 2019 15:45:11 -0700 (PDT) Received: from [2620:15c:17:3:3a5:23a7:5e32:4598] ([2620:15c:17:3:3a5:23a7:5e32:4598]) by smtp.gmail.com with ESMTPSA id n17sm13000168pfq.182.2019.07.06.15.45.10 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Sat, 06 Jul 2019 15:45:10 -0700 (PDT) Date: Sat, 6 Jul 2019 15:45:10 -0700 (PDT) From: David Rientjes X-X-Sender: rientjes@chino.kir.corp.google.com To: Christopher Lameter cc: Markus Elfring , linux-mm@kvack.org, Andrew Morton , Joonsoo Kim , Pekka Enberg , LKML , kernel-janitors@vger.kernel.org Subject: Re: [PATCH] mm/slab: One function call less in verify_redzone_free() In-Reply-To: <0100016bc3579800-ee6cd00b-6f59-4d86-be0c-f63e2b137d18-000000@email.amazonses.com> Message-ID: References: <0100016bc3579800-ee6cd00b-6f59-4d86-be0c-f63e2b137d18-000000@email.amazonses.com> User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 5 Jul 2019, Christopher Lameter wrote: > On Fri, 5 Jul 2019, Markus Elfring wrote: > > > Avoid an extra function call by using a ternary operator instead of > > a conditional statement for a string literal selection. > > Well. I thought the compiler does that on its own? And the tenary operator > makes the code difficult to read. > Right, and I don't understand the changelog: yes, there's one less function call in the source but functionally there's still a conditional; this isn't even optimizing DEBUG builds.