Received: by 2002:a05:7412:31a9:b0:e2:908c:2ebd with SMTP id et41csp5500087rdb; Sat, 16 Sep 2023 22:30:10 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHAokt/TsAIpBUPSc717J/MGQrCdQfewuAYGkuvjj/rCak9kJIQL+L4bHseewC0wGZTAT7U X-Received: by 2002:a05:6a20:f384:b0:148:d5d9:aaa9 with SMTP id qr4-20020a056a20f38400b00148d5d9aaa9mr6271531pzb.33.1694928609764; Sat, 16 Sep 2023 22:30:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1694928609; cv=none; d=google.com; s=arc-20160816; b=Brar9B6DBTJW1dSxt7AddYM5IDYUmuHBINik/EnDpoti2pWeOCPXNjynCJqlQTX9RT 7soiqnGHdPaXEvCNjBQ+/1ySMLCHFYdIrtv7Ns+TjxdITNRdxHZcBGhYVk6T6y1MQu6A DBNlWpmniWMo29xzolb787Nw77B5I1Ha+UYoOga2rpeAOMYNLVgiaYBqcpYT8GMl7hv1 FwuAuJK9TAhR9q9aiBz0eLg5boXUnbv9g1brbfGhzVMCqzMSPD8/iGd3Y9EfdQPksrYu ibu/X3+cUGB/kkymF5a++mwS35w8WP6w7mGRGd2tqS0D5Xhf+6IlfESqEeuMXZYU3XgT kseg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version; bh=qG1rlIXy2hvVva1BDsxwRTamORp+1rpPLva1EjchNC8=; fh=B9AcMvhPauLRftT8v3xmZMUQ5AFRJI2xFfIvZI7DyAk=; b=t1Y21nLm3MIU62DNYKFWaw0W9aY2oWoPQf/1mQKgH2Xuy9/12Lh7vDkD8FWXV0qlUz OY/f7KfjCVmX6BWmCgWdj6O5hmEE5RjZxTdoHQVlEzm2xlNufo1RRESZul4hOYJmd/XC bwai7+tBJKJp/Wrs+xwU/eOB/QQQtPbP1NI9pK57zxcLUoFzFhdVfK81l/ksKLmrRluB X4J6MdESmsvKtGBZ2ynU2yAYpHVORplgiTX1wqoZ8hOxhfJAPT3ZxCRySoZOivOItlvv LbYW6JXhPZd0o3+PFYLyEuwRmJShuAB4MR9FOD8/qRK94/ucu0Phg2KwERZabvsLE9EF pfaQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from snail.vger.email (snail.vger.email. [2620:137:e000::3:7]) by mx.google.com with ESMTPS id ei44-20020a056a0080ec00b0067af445c0f0si5775702pfb.291.2023.09.16.22.30.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 16 Sep 2023 22:30:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) client-ip=2620:137:e000::3:7; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id B612B827DF87; Sat, 16 Sep 2023 22:30:08 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232576AbjIQF3d convert rfc822-to-8bit (ORCPT + 99 others); Sun, 17 Sep 2023 01:29:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48630 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235614AbjIQF3Y (ORCPT ); Sun, 17 Sep 2023 01:29:24 -0400 Received: from mail-io1-f45.google.com (mail-io1-f45.google.com [209.85.166.45]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 224F41A3; Sat, 16 Sep 2023 22:29:16 -0700 (PDT) Received: by mail-io1-f45.google.com with SMTP id ca18e2360f4ac-7955636f500so138437939f.1; Sat, 16 Sep 2023 22:29:16 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694928555; x=1695533355; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=UO3U4MkwPd1ZUK0WSQVObxv6NbOdmKj2lLfEiVm8580=; b=E9aXUrbaPpMP78ypzkuxyIU4n89xCuFpvvEXyXNB72ZWXcezxG34gl2IKLF5cEsvRN ntGrUMDs/KpWOGj78RhQvLKQXYUxkzcvqaClAakp7YbHwh6O3JMFvHny/eXN4AdQyqgb PM9LdeD3I+yHV3lJeF5PGhswIQGZixrRPOsPMIjx+3H4laQ2zxMCUBJldQHjNoaDV/9p ohLmfhf3SCv/Da7bLVUu4CjaxHf0Cf1dKVGZQNkA36NlYchv1Lc2V5DeEyYgehpWTTBo jW4m6DanYVWU6Efbkb2sUKCPUzEBcH9J2HId/5LnPoTyK85awxpLAoEvlNwYiJjL1mfb 3w2w== X-Gm-Message-State: AOJu0Yy7YTiO+4WaJlSzrDcNWnrrKenbOKZiiOncQzDlxQAR20HRl8YM GyxQVrnMl6coV+2dUwVnEuQhkZ3ikN9YikSRdSY= X-Received: by 2002:a6b:e805:0:b0:785:cfa1:fcac with SMTP id f5-20020a6be805000000b00785cfa1fcacmr6395338ioh.20.1694928555425; Sat, 16 Sep 2023 22:29:15 -0700 (PDT) MIME-Version: 1.0 References: <20230914044233.1550195-1-irogers@google.com> In-Reply-To: <20230914044233.1550195-1-irogers@google.com> From: Namhyung Kim Date: Sat, 16 Sep 2023 22:29:03 -0700 Message-ID: Subject: Re: [PATCH v1] perf symbol: Avoid an undefined behavior warning To: Ian Rogers Cc: Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Mark Rutland , Alexander Shishkin , Jiri Olsa , Adrian Hunter , James Clark , linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8BIT X-Spam-Status: No, score=-1.4 required=5.0 tests=BAYES_00, FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_BLOCKED,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Sat, 16 Sep 2023 22:30:08 -0700 (PDT) On Wed, Sep 13, 2023 at 9:42 PM Ian Rogers wrote: > > The node (nd) may be NULL and pointer arithmetic on NULL is undefined > behavior. Move the computation of next below the NULL check on the > node. > > Signed-off-by: Ian Rogers Applied to perf-tools-next, thanks! Namhyung