Received: by 2002:ab2:69cc:0:b0:1fd:c486:4f03 with SMTP id n12csp195061lqp; Tue, 11 Jun 2024 01:16:32 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCX5RBatHuuKkbWPMJkdjQ6Fch42KQCHk9qWt+y+KQaaLkRnWkeDgwNqSFiEIfSJCilNyImY7spOJn3s2QfvgvMHDyN56jDWRw7ZdpIMtg== X-Google-Smtp-Source: AGHT+IGhPhVpqoIA5VOlVulsoKwKFsmod84t/bXSZpSfsH1cRvGWfJPjEmh1zrTwuAjAOmaZ/n+K X-Received: by 2002:a17:902:eccc:b0:1f7:12f5:d7d6 with SMTP id d9443c01a7336-1f728927333mr27939805ad.33.1718093791880; Tue, 11 Jun 2024 01:16:31 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1718093791; cv=pass; d=google.com; s=arc-20160816; b=wSuNAVzy81JfxSF/7UNDoJ+bIm8fnmF6J+iHjZH/E2hD6aVL2dPH5I947sYmV3I9eh o5iqqg9jyhLdHySPO2weyL1F5w6VuBS462It8R9WaNxOjDc55kOVly0LP0qzqZz+/wj6 v54JaQRN2UkK4WLdwAiHvn5KxbJOWheVkFvjS6VEztE4ZWZKH799Bs2+7l7RcvRMmHhc HfCEEtPwkvioJHwEWsNYdWGGs1licRaFebamHSiAA+SEHBl05kRIh+aNXJJX/zOMDTW+ VDzNs3hlpcMTi1uQPw0bH5H9SDqMeF80d1t1d+Cm+JAQQ5UFqReHSRkyNB7W0KLYRoTl atSg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:from:subject:message-id:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:dkim-signature; bh=sOJq0SNxfCF/3ET8RSl5nDiW02JEujt8+S8ncUXlnV4=; fh=Eq8lo/UxbLMtk9YPTujoXRMBxIr6oAnawmlbqnf3lHM=; b=qdIG7ndKgHn4a9yVMJf0yLKCYGLbRsJBVPccUsGGninF4Jjo06q7ikBKR/YIdOxNAH VMWvc1+jfH+nVQhgcFHRnVogSD6SUI2x0SW5hq5V1lS1SOqb0cdgYcsfcLRI4BnLET0L PzqKODTerwvo9oTLZtdSJSe+dVXFCFAVe26HyxcUhUFAcxWxtKXedzo0AWDhk2YIQE0I /sUkfBUEYr2Au4hus9bDjq0/mjL2bhgIfSAhteVdJ1ce7y6Nsdy/+CwTW5v+MjhXqk66 JTmY57lw3vkr03B1mJFJOxoSrw0rQzumT6Nz/XosOWsDEg02dWIdXnUdKwGq1TfWWO28 wTOg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@google.com header.s=20230601 header.b=ydZZW2oR; arc=pass (i=1 spf=pass spfdomain=flex--dvyukov.bounces.google.com dkim=pass dkdomain=google.com dmarc=pass fromdomain=google.com); spf=pass (google.com: domain of linux-kernel+bounces-209417-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-209417-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id d9443c01a7336-1f709a7d086si38178085ad.623.2024.06.11.01.16.31 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Jun 2024 01:16:31 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-209417-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20230601 header.b=ydZZW2oR; arc=pass (i=1 spf=pass spfdomain=flex--dvyukov.bounces.google.com dkim=pass dkdomain=google.com dmarc=pass fromdomain=google.com); spf=pass (google.com: domain of linux-kernel+bounces-209417-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-209417-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 5689AB22BA5 for ; Tue, 11 Jun 2024 07:50:54 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 851C5172BC4; Tue, 11 Jun 2024 07:50:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="ydZZW2oR" Received: from mail-ed1-f73.google.com (mail-ed1-f73.google.com [209.85.208.73]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 27425130ADA for ; Tue, 11 Jun 2024 07:50:41 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.73 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718092243; cv=none; b=CYNErD/7cTrOrZ9JKEJQ0jF0sxDdc4bCvuJ7UNF3PWke49hD+WSvpxZ7EXCDmPLuKYRs4We5aW6ERlH3SuoI6635hK8lG+Ope3w1HSGNcfxhEw5V1XFQ/vCJUkHIUtkTj39YxDeZirSRsMybNphyyHO+ko9Bsbt/sLfM7oM0vto= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718092243; c=relaxed/simple; bh=9kS5Uofgz9pE3ajhh7ZndiNreDJxiZdrDGSyL6Ts7Ns=; h=Date:Mime-Version:Message-ID:Subject:From:To:Cc:Content-Type; b=d+lqGwKU5RhIXvVu/yXuGpr4QrSeqY6db/sfnMU/pQSHUf2hHDILJUkmpJBDvGTti8HsC9bI8cM0H/8BBL2qOalH2eeBoTPkJKBmeoKY11gfQ3sHszeQUv+JXSlj5wbfL+Lf4a+y54yrOLFLXCUqc3O2b5XUOy8PoVLIjF2Tdgs= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=flex--dvyukov.bounces.google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=ydZZW2oR; arc=none smtp.client-ip=209.85.208.73 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=flex--dvyukov.bounces.google.com Received: by mail-ed1-f73.google.com with SMTP id 4fb4d7f45d1cf-57c6979daf7so415911a12.1 for ; Tue, 11 Jun 2024 00:50:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1718092240; x=1718697040; darn=vger.kernel.org; h=cc:to:from:subject:message-id:mime-version:date:from:to:cc:subject :date:message-id:reply-to; bh=sOJq0SNxfCF/3ET8RSl5nDiW02JEujt8+S8ncUXlnV4=; b=ydZZW2oRuNtgK4DDQtBX78Rw0Tbs5ZP+Lf9AM0//BahFo7Id76VUEjs8MIgwykTozD esjDAfSiAoHzBTsZsabVAG3PhWz+PQ2DIqtUJrTUwEmcOHoR3VFaARrrmaTI0s41Dsah Uhuy91L4GfxDynUK+I1GE2jtDTOvUDry1W6CFRgsRo9PWiVphcaZRG/HYCpPqVZ2SgX+ ZxyTJb1DpL8Qy9FDItZ9pu9H8pRH+kNEtck1WlOj43BP/KG6xADhnqtVjXh3v46JpEHB sYKGn/Qk2QepnSdDgxVnXw0a+wOIC1iP50ZMJcPRNszh599mEzqZ+drok7mAC+98gerT R4YA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718092240; x=1718697040; h=cc:to:from:subject:message-id:mime-version:date:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=sOJq0SNxfCF/3ET8RSl5nDiW02JEujt8+S8ncUXlnV4=; b=i0KgaFekwjsVvjYLmqvko13jbpxvo+O9O73fbn4xKLlc/F/qsjTCUWGaAigFjzfwnD 5C56PutLJfyrQXSWUkd32HgyxSy+N3TZcEDEIsmAdQGcxHUHhVkWUnaXQD3o24JTX+UT kwUlPYD7MqC/ReusXuZK5EUrA4uzE3nhKh9vC9rRSgAt8Tn/fCa/AEhyVgbOjPq4/9Tv k1wysZwvAi5X9pOkRPRlcTSwbi4BEbTI9EB0a/YE/H8471a5xyNkCbexmbPyMSW5ZSwR aroVcH6rTbmY4RbNkjv4JrAuDI7TIfRMIV56DrsoGHFUW8TuUTXkWcHp3b8lNJO1FQfU I+lA== X-Gm-Message-State: AOJu0Yx1zCYkrtG7D1/WMhw8deehk4SAZhynOU6PzEMIh8aXDRFahtnY hlJLZMdRfpo0xdkRoi4tVGHwStIP4AaUTIf6rej4Jb838PGKL968Sg4k8dwF5hY+ezhsF8ltuZp v6Tgyhg== X-Received: from dvyukov-desk.muc.corp.google.com ([2a00:79e0:9c:201:ecf:76a8:5d44:6e8b]) (user=dvyukov job=sendgmr) by 2002:a05:6402:548c:b0:57a:8b21:a587 with SMTP id 4fb4d7f45d1cf-57c506bfe91mr13190a12.0.1718092240035; Tue, 11 Jun 2024 00:50:40 -0700 (PDT) Date: Tue, 11 Jun 2024 09:50:29 +0200 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 X-Mailer: git-send-email 2.45.2.505.gda0bf45e8d-goog Message-ID: Subject: [PATCH v2 0/4] KCOV fixes From: Dmitry Vyukov To: tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, dave.hansen@linux.intel.com, x86@kernel.org Cc: linux-kernel@vger.kernel.org, syzkaller@googlegroups.com, elver@google.com, glider@google.com, nogikh@google.com, tarasmadan@google.com, Dmitry Vyukov Content-Type: text/plain; charset="UTF-8" Fix spurious KCOV coverage from interrupts and add a test. Ignore some additional files that lead to large amounts of uninteresting coverage. As a reference point, tracing a simple open system call produces ~10K PCs with these changes instead of ~45K PCs. Dmitry Vyukov (4): x86/entry: Remove unwanted instrumentation in common_interrupt() kcov: add interrupt handling self test module: Fix KCOV-ignored file name x86: Ignore stack unwinding in KCOV arch/x86/include/asm/hardirq.h | 8 ++++++-- arch/x86/include/asm/idtentry.h | 6 +++--- arch/x86/kernel/Makefile | 8 ++++++++ kernel/kcov.c | 31 +++++++++++++++++++++++++++++++ kernel/module/Makefile | 2 +- lib/Kconfig.debug | 8 ++++++++ 6 files changed, 57 insertions(+), 6 deletions(-) base-commit: 83a7eefedc9b56fe7bfeff13b6c7356688ffa670 -- 2.45.2.505.gda0bf45e8d-goog