Received: by 2002:ac0:e350:0:0:0:0:0 with SMTP id g16csp2370761imn; Mon, 1 Aug 2022 23:31:05 -0700 (PDT) X-Google-Smtp-Source: AA6agR6c5tDdg4dovVk1Dgf4ix0qXkOcX4ZnV+lGz3SCVVYbRZ0CZFB9+0tcHZOmXLt7b0bZIC/g X-Received: by 2002:a17:902:820d:b0:16e:c853:ddd1 with SMTP id x13-20020a170902820d00b0016ec853ddd1mr15824481pln.31.1659421865423; Mon, 01 Aug 2022 23:31:05 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1659421865; cv=pass; d=google.com; s=arc-20160816; b=ut3uAw7uGz/25oW/UgdvFSx0T4uBsCuRplce3w7NEns/M0aROhP1NIRKfb/LrYAa9F zVP0EmJV4L8Pc9P9J27SdMViPhMuyG5B/G+ySZ5QO4R8+EJeO0MfRXCUGMFn8e/9Kxey o+IbFQhiFRnG31yf4IjqTbnpjYFrg4gg/FZnlSpj6M/lvaURPSBi+MPkSYLrhPDuDew6 3WQ5OjLofuzplnfPqIe+BRcppp1fc+//7SF2w9mF8R0SpRSU1Z0o4CetYpQOMy5NzIPH UGNnZG+73lRAdhKiIso7Fx0D9ryaS0Z+taS6pgc/NEKzimaxFEcOaKD4XLlEoR9Os4B7 MRWg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :in-reply-to:from:references:cc:to:content-language:subject :user-agent:date:message-id:dkim-signature; bh=TMiiLEAjEJisFBYRi8V9GbOCfd1T55CWOGC/f2PAKqQ=; b=szz3Dlnl510CEFaw6LlgUvJBEMboWhOfyQa37RwRUkaurh9oVkRjSsdgRGR7rgiqHQ DmumCYv+RmFtKMnLl7O4MTMSb8xwdsKKGfG4lqW3/QQjpn2DkZAmdNoMnbSwRkO4NKmO h1mTSoCzQS8p1mkXuUECMEEnlzTAZe6UorFcwI/ZbDJqA77HAEpixtDffqslhNXCKWJ0 ddkp83stf9yXR9AxYedlQktnPOQw6VWoeEB1foJgI+xkJz0D6F5XbYMq66Pwra3QpGel XCnTPZ84E9V5mHpVbEZrKwjXXNWotgjo2DzYW2w5W3aZeZbnh23aFCht/KGxf8R3ndvo CP0Q== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amd.com header.s=selector1 header.b=VccGMTKu; arc=pass (i=1 spf=pass spfdomain=amd.com dkim=pass dkdomain=amd.com dmarc=pass fromdomain=amd.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amd.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f10-20020a63dc4a000000b0040c8a3cab3esi14084422pgj.638.2022.08.01.23.30.50; Mon, 01 Aug 2022 23:31:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@amd.com header.s=selector1 header.b=VccGMTKu; arc=pass (i=1 spf=pass spfdomain=amd.com dkim=pass dkdomain=amd.com dmarc=pass fromdomain=amd.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amd.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234268AbiHBGHr (ORCPT + 99 others); Tue, 2 Aug 2022 02:07:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40724 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232576AbiHBGHp (ORCPT ); Tue, 2 Aug 2022 02:07:45 -0400 Received: from NAM02-DM3-obe.outbound.protection.outlook.com (mail-dm3nam02on2055.outbound.protection.outlook.com [40.107.95.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 027FED100 for ; Mon, 1 Aug 2022 23:07:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=KahNW4EtunVbK+WqRlO3+ZzOja1S56mjeeoYP9N7yrVIk7uamJGxPdnx791ehz8jyVEeCdP5PIWUFQfl/kMgTHPY5XBPe1H9GwbQFrktskj7Xkizc5yL/awk8WGPyMBMTCSyhnvxmZuyc8i8+YXCvTxzAb2m4GGT+JcIyX/Hw3OMwD97+aPK3dUTqNck6NoAlbtETXj/m0d8TUCg9rMVHDZm2FbzlW5VB3tJ75/QYYN26HnJxQBwvjVl2qchHe3TeBeGVwuXeubRliyfiQBNAdxYZGew5tLFn0qb3aTPfDBv0afgKcU9IEvgn7HYwftUGA3ohvtX3N3lSSmxsQjUog== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=TMiiLEAjEJisFBYRi8V9GbOCfd1T55CWOGC/f2PAKqQ=; b=OVllSOrLSuG6trwIs27llGBf78e+kLC6h+3DwTZHQONtAo4ZDC+Dm6HNCDx9gutSYdPEovMDyUcUcqrBPVrnhAXBwomWL83Nkm2hlHxv+bFeWnlW7mqf+m4jhZB1R+dsZCmnUP3zZHBpl0y6IjZEXrlCmICMARwBvvGeNsJsB0QMxYsa69S5s8ReXaRubkpszfrrFfNsxuMXJ+aenfNPV2lU96HMvuI85pwpVbjUZuCpdYEvctbb1l8qGoFEJKrufXONWwzYjYNqnTRBdo6gS2ywyGS0EnW5kfMBzhfJiFeaOM5/tZ5FQuSdg2Po9nB9XqfvNwj8tqD5CTeUYpy8tQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=TMiiLEAjEJisFBYRi8V9GbOCfd1T55CWOGC/f2PAKqQ=; b=VccGMTKuRxiXbkJ/67fqMeyJ5BhMDyWZgKfmyifCbeQ3i3Ed1+TkD+K+/BYyR0Ttb2+l1iaTSXMqh8evh4bAfLH+S6ztmAk/G/bsoP/FpRQW6lYy3P0/iIdYM7rJGssMX6IDDYdPDYDjJajlv3sOMd8mvKpXxPGyOJRjvLQlcmQ= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; Received: from PH7PR12MB6588.namprd12.prod.outlook.com (2603:10b6:510:210::10) by IA1PR12MB6353.namprd12.prod.outlook.com (2603:10b6:208:3e3::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5482.11; Tue, 2 Aug 2022 06:07:38 +0000 Received: from PH7PR12MB6588.namprd12.prod.outlook.com ([fe80::1c48:55fc:da99:87c9]) by PH7PR12MB6588.namprd12.prod.outlook.com ([fe80::1c48:55fc:da99:87c9%3]) with mapi id 15.20.5482.011; Tue, 2 Aug 2022 06:07:37 +0000 Message-ID: Date: Tue, 2 Aug 2022 11:36:07 +0530 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Subject: Re: [RFC v2] perf: Rewrite core context handling Content-Language: en-US To: Peter Zijlstra Cc: acme@kernel.org, alexander.shishkin@linux.intel.com, jolsa@redhat.com, namhyung@kernel.org, songliubraving@fb.com, eranian@google.com, alexey.budankov@linux.intel.com, ak@linux.intel.com, mark.rutland@arm.com, megha.dey@intel.com, frederic@kernel.org, maddy@linux.ibm.com, irogers@google.com, kim.phillips@amd.com, linux-kernel@vger.kernel.org, santosh.shukla@amd.com, ravi.bangoria@amd.com References: <20220113134743.1292-1-ravi.bangoria@amd.com> <3492774b-a462-d8e6-34bf-9f5ea10729d4@amd.com> From: Ravi Bangoria In-Reply-To: <3492774b-a462-d8e6-34bf-9f5ea10729d4@amd.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-ClientProxiedBy: PN3PR01CA0038.INDPRD01.PROD.OUTLOOK.COM (2603:1096:c01:98::6) To PH7PR12MB6588.namprd12.prod.outlook.com (2603:10b6:510:210::10) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: b3c838e8-7aef-4b52-2d28-08da744d4cab X-MS-TrafficTypeDiagnostic: IA1PR12MB6353:EE_ X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: X0bYSjlfRNw7pD2IwKEobMG2XiB39YGCCfZwQGG4qEQyaEWEWmzJMxxXB1RXrKPyzE+tsu6sLFdLeKl7pN83GuTflnBH67ZcoDzDdDb0DszuCyDgmd+jdohtqBhH7qyWbhDYx/asB9/IZ34VP7/OcxYYwGoxv7MRqA7nWifWmWxgFkF3qQfzKzjh5oC59AQJbOrIvpUQW6KdGSqBP+AYlr0aAb2+uvIgBq6DrDQTWvReq9BlRsN6lNG/KCcsqM+1xLpyDbCJTONCasqb4DAkvlMxYVetFCFfJsfQ4zDEQJDAcyNKKIU0n8iR4zTNKd5Ca8lqasLz5tPIDpFH8HZUbsyV4OWdQmy6SbzTZUVK8UyOHxnFNAYWNY2aneZFSsZp8sP7CeM82a9z/JAriys/+8Grm/uVNWf8+RE2JIN281Z1aVkpxklR6kFsTYpu1/m9C4dyVCEl8tz4JxRapjIIEMNaywozVhyCsvJhvxE8jfxdV7QJrDBhtEJHgZBWr5cTGS/miVzHwYXNkbH9HUKHbUhuRlzmYLw6JPlk7ANFoOCDefve+SGUR6KNGWl/6pLIgoDbdKw94lzM2pr9t+VC/Ee5YiCkN9nvAvOG4GiI0DT6ZkByRx9MqAwKyppno9ufK6O5WoydwcLunabkd4J9ZFWbkoTNWzn2aitOous9RhLiPFDgu6wQOpuGUObxN6w9zF4Jnm7GumJlPW8WpYA7R4iyc34nMgj3VxjfpHHKve/MtakgmjXlSXqOe+MaHUY0Nv0SQAvPE98u9Y5mFXBwdiFqjFetI3Qu8amknhvwnBtx5daKoQsRTBZAkKWbmHlRc+yR1h6LtjaJwRQge+mm5g== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PH7PR12MB6588.namprd12.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230016)(4636009)(346002)(366004)(376002)(39860400002)(136003)(396003)(31696002)(86362001)(26005)(6512007)(6486002)(5660300002)(66476007)(66556008)(66946007)(44832011)(2616005)(4326008)(7416002)(41300700001)(6666004)(8676002)(38100700002)(8936002)(53546011)(478600001)(6506007)(36756003)(6916009)(2906002)(31686004)(83380400001)(316002)(186003)(45980500001)(43740500002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?NCs0bGlrNFdqSFNOaWhhWVZRVUpYYmNXUzBrbUdMbkFkNDk4bElvME9TZTNS?= =?utf-8?B?dXI0RVV3RWVTVkxvc2VSaW1WM1M3VzJwSWpZbHRyOWIwUUtja2hVRHdPNmlw?= =?utf-8?B?TUN3ME1Yb09JbkVGNjkzVFVpcFYraThQUlNUT1FNVkM5NTdpeHEzSlVkMmJ1?= =?utf-8?B?L085MkpOU1QzQzBtMEplNFlBMHhrL3NEbG92bGd5SUJnaFY3Wk5oV1p2eEFR?= =?utf-8?B?WnJzSjZCZHF2RXo1NkdZbDY0WG4yRHB0YktSbmxad3k0bEhSY0owZmh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BUmE0WTBPeXpW?= =?utf-8?Q?3+drXTH5neFqkpzL7dfGNzVGq?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: b3c838e8-7aef-4b52-2d28-08da744d4cab X-MS-Exchange-CrossTenant-AuthSource: PH7PR12MB6588.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Aug 2022 06:07:37.7842 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: qr2ZPrWlHsrFph7XTmVVpdpX+Ieq9RNscsm+GvMuuuswmTu2jkT648VOv2HVrYDNSMGFFh7CD4p4ULxl5PQ7iw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: IA1PR12MB6353 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_PASS,SPF_PASS autolearn=ham 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 On 27-Jun-22 9:48 AM, Ravi Bangoria wrote: > > On 13-Jun-22 8:05 PM, Peter Zijlstra wrote: >> >> >> Right, so sorry for being incredibly tardy on this. Find below the >> patch fwd ported to something recent. >> >> I'll reply to this with fixes and comments. > > Thanks! I've resumed on this but my mind has lost all the context so > it might take a while for me to reply to your comments. Please bear > with me if I'm bit slow. Sorry, it took a while for me to get started on it. Anyways, thanks for providing fixes. I applied those and ran some tests on AMD Milan machine: - Built in perf tests ran fine without any issues - perf_event_tests reported one BUG_ON() and one WARN_ON(). I'll work on fixing those. - Ran perf fuzzer for almost a day. It reported one softlockup but system recovered from it and later it reported one hardlockup but unfortunately my config had HARDLOCKUP_PANIC set and thus couldn't confirm whether that hardlockup was recoverable or not. Anyway, system was running pretty much fine until then. - No lockdep warnings were observed in any of the tests. I'll work on verifying functionality changes. Thanks, Ravi