Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp3295652pxk; Tue, 15 Sep 2020 15:42:49 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx2A2aKiDxTuyYV8tO+25z0oV0sD1YuiHxM4C+PCh7bwGkFdEr/UAn3NFbUopb7EJzWnWuI X-Received: by 2002:a17:906:2659:: with SMTP id i25mr21801459ejc.16.1600209769404; Tue, 15 Sep 2020 15:42:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600209769; cv=none; d=google.com; s=arc-20160816; b=GzP91GbWT+s2SNeKTI+2zs+JxKooMKD1XtMQfIZlHSx1eN/PshZgZbAhC2qmKwX69g /9dVlAjEcoelBym+WODPMDhbH6rfB+sclwyE4ML6Bk3bHHKNfe6wRLW3CxZyQJGcPW5J vZ0xgTAtufLHTYj7a22JqXQ68d9RN2/Yd58e2VVzyuWXeM0uL+TgBHfVLtO/Ljapo3sp igSxt9ZTRWNqUOYsg2C/FyXEbAqI3NgPIMJBjgwDLUD2XEmSMTTU4psNLkRnIqg6kim6 m5DQYZvUP6v60yEx6kjwKx88IMz+ERHygL815YtdM8LzU8pYQmhgsKlEr4JjRKoQFP1L 5gcg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=+RefOWSaF/+yw4enLs3JNCZKSsuLRuxsPClHLLnrcCk=; b=bVjSdFTWe4hWSDT8vT8Ufkhnx0GUXV2mZE15SnJ1vJca1ejkrdluMuxL/ZvZow3cML F7TNzkVc016RWPwb5UN335aF3v2lFDMjUyiF5T19uOlABj2hCCHYSBvjkluTPm7ZyHbw 8Nfxo8UDYH1xF5HH67btuKdJLRburvEAISFCusC+zQTyQGb8HcQ5y5tP5AzYMtpxXfpL 4Q/MpfopoA3Orw4QPjR+sjRGg2tAeIU0PaUXbQFZspJDzg4h6xnSRNOA4nSOTMPC3OgX yBmhbpgpxNrc/5sz49yq5SCXNKVN7JosMmjpmwGN7AWZQL1ZbhiEIQa5xnt3v/rk4zZf cvYw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=bGjml3eD; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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. [23.128.96.18]) by mx.google.com with ESMTP id mh6si10398878ejb.243.2020.09.15.15.42.04; Tue, 15 Sep 2020 15:42:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=bGjml3eD; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 S1727563AbgIOWjr (ORCPT + 99 others); Tue, 15 Sep 2020 18:39:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53830 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727389AbgIOWex (ORCPT ); Tue, 15 Sep 2020 18:34:53 -0400 Received: from mail-pj1-x1041.google.com (mail-pj1-x1041.google.com [IPv6:2607:f8b0:4864:20::1041]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CE6EDC06174A for ; Tue, 15 Sep 2020 15:34:52 -0700 (PDT) Received: by mail-pj1-x1041.google.com with SMTP id b17so517824pji.1 for ; Tue, 15 Sep 2020 15:34:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=+RefOWSaF/+yw4enLs3JNCZKSsuLRuxsPClHLLnrcCk=; b=bGjml3eDUh9hqjjXmz7B1idkmyKG5l0ER88thJ2VNXsmqILy2Syr3sVxQ4oHhRAdlJ GGKbFRnGwh6A4PtC0IDELU7DjpzOp+WRWw6K/aTZlluGf/6hUXvE1haWq8aRnW3ekzsk bNSNUIPlTmmrNfHDZvlGfHMT1e81BfWmlvWqpfmCp9LfluYGoC5SGQGXM/WDtL3Ml119 gJgCWJrWxr06Aw5p9UYWHgrEv5v5ES3c2iTLcvct83AUXb5TFajLwN2tdny9hHsdh47b EoQgFxprLte03IcECGT9ft+v1W9htHRlmBkcbBZI7xAwAGip2uC6Oop+qI7GsrESPSOf TfaA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=+RefOWSaF/+yw4enLs3JNCZKSsuLRuxsPClHLLnrcCk=; b=XF6e1kCAcVHqE2qCKsz3rR+DLhoiEhjVZnq7PYcpw8J1UacLsOenccXkeqGuHHcnAY If+Nh9vUuvQhRZ9Vd1CNOek4prDkHHlkQjoyEoVw8wT0l56jJs78wQ2scEYHELKFHsd6 dVIGgvSGXLxw1OD9CaE1cJqRxyXvoBuF6EhvzXWluH5MjRHibS+484AuHYaVE/ek7f2E 7G5AUPENOPMDd8H64VkUQ+VnXbw+Ak+aoey/IcfXe7z6+cTnOdhfnpxknq7q14NYmb90 wabKeWEefxey2Bnm67V99Xi3YZR9u7tp3ErI/cPSQZbEq8+Yz7NvipoqKCpWOTXfrmjo FLZw== X-Gm-Message-State: AOAM530qd6AHKhcrWlBM4mjMZvlpcmY55TIitKMukU8rrI0BDWHjAHrR kOKNkQglkkMLl6OZFlaPVRLRmbMKnVcZiKBrHOBQgQ== X-Received: by 2002:a17:902:7295:b029:d1:e3bd:48cc with SMTP id d21-20020a1709027295b02900d1e3bd48ccmr5124412pll.10.1600209292167; Tue, 15 Sep 2020 15:34:52 -0700 (PDT) MIME-Version: 1.0 References: <5f60c4e0.Ru0MTgSE9A7mqhpG%lkp@intel.com> <20200915135519.GJ14436@zn.tnic> <20200915141816.GC28738@shao2-debian> <20200915160554.GN14436@zn.tnic> <20200915170248.gcv54pvyckteyhk3@treble> <20200915204912.GA14436@zn.tnic> <20200915210231.ysaibtkeibdm4zps@treble> In-Reply-To: <20200915210231.ysaibtkeibdm4zps@treble> From: Nick Desaulniers Date: Tue, 15 Sep 2020 15:34:39 -0700 Message-ID: Subject: Re: [tip:x86/seves] BUILD SUCCESS WITH WARNING e6eb15c9ba3165698488ae5c34920eea20eaa38e To: Josh Poimboeuf , Marco Elver Cc: Borislav Petkov , Rong Chen , kernel test robot , "Li, Philip" , x86-ml , LKML , clang-built-linux , kasan-dev Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Sep 15, 2020 at 2:02 PM Josh Poimboeuf wrote: > > panic() is noreturn, so the compiler is enforcing the fact that it > doesn't return, by trapping if it does return. > > I seem to remember that's caused by CONFIG_UBSAN_TRAP. Indeed, if I remove CONFIG_UBSAN_TRAP from the 0day report's randconfig, these unreachable instruction warnings all go away. So what's the right way to fix this? CONFIG_UBSAN_TRAP enables -fsanitize-undefined-trap-on-error (not sure why that's wrapped in cc-option; it shouldn't be selectable via Kconfig if unsupported by the toolchain). Should clang not be emitting `ud2` trapping instructions for this flag for no-return functions? or Should objtool be made aware of the config option and then not check traps after no-returns? I suspect the latter, but I'm not sure how feasible it is to implement. Josh, Marco, do you have thoughts on the above? -- Thanks, ~Nick Desaulniers