From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-20.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 574C5C433F5 for ; Sun, 12 Sep 2021 18:47:54 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id BDA3F61026 for ; Sun, 12 Sep 2021 18:47:53 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org BDA3F61026 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=nongnu.org Received: from localhost ([::1]:34448 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mPUW9-0005WE-0G for qemu-devel@archiver.kernel.org; Sun, 12 Sep 2021 14:47:53 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:33152) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mPUUs-0004A1-II for qemu-devel@nongnu.org; Sun, 12 Sep 2021 14:46:34 -0400 Received: from mail-pf1-x42f.google.com ([2607:f8b0:4864:20::42f]:39862) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mPUUq-00062J-SR for qemu-devel@nongnu.org; Sun, 12 Sep 2021 14:46:34 -0400 Received: by mail-pf1-x42f.google.com with SMTP id e16so6795234pfc.6 for ; Sun, 12 Sep 2021 11:46:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=I8xFaMcbSOLpfI7f3468dXDJbgxhKvf+2cUAlaptaM4=; b=lL8KZ907Qe/UqX5MVYEP3Yj5BKKG/nA+PctFERdl/JYLA8YAyCNWTB6aSmeu1cTeVJ +REP/XyTl2Mt4qoETM/nopPNdlCUhKadSpq/Dt7Q7ErHZ8X18ogK8Ffsc3FWtxUrwgqt onmbUHdmd9qevwM1RgxdqvX/QiqGlQ/qIxuB31QnUYiKB9NFKU37GMf8QqjSooVJp9XX guaKEZSf++SmovpBtQ7RrbpIEpFyNqXicESe01EK7hly+NGCIaRFa8sm35L3kv77WLkK +0/ygydSSEw0XSNvIwOxYyrMJdbmToyXXg3dBfdneOigvBF4f3RKYBioYnXW7iuVvEGY Cm7Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=I8xFaMcbSOLpfI7f3468dXDJbgxhKvf+2cUAlaptaM4=; b=0IesuiVM18ieORMZYwymDnp4Clte7e5z+RIXpi0G03VY9BtwrCL1QQOx5uCNkZGuax PoByOHfIW6i67zouPACRak9MiPEcKTWXuyeQ+bnzpk6BlD12QtDlbHpRwfQpZQmOt/r+ DA7UgP/cP/Cgs3ppdTYQOvijxrdvypWXBwqFAnNyVMD5kBe0UpzJfa+VlW+9WNGwEXgc 7wnJmOlQi7TNu1qI3ik0yBWbPNh5tkRG55ZPdoth1Dnrf0lFl2XuI8qqK6HNfeGvbHNf xAgXmyY0cWfIFbIjwl9Wy5r0yTwOQJ39g24W+Jy5IfBkFr6Vxrtc5kjqyzoneySPcs/y 59EA== X-Gm-Message-State: AOAM533VryFn1/eEoPo5TENwl7YcuVt0v5DiMJxx/FClNYmGJDXWj1B5 B0pgagh31PCvnhQ44QYfYOCF7nJEykRRug== X-Google-Smtp-Source: ABdhPJyjbObJeAFU+37n8W5v9p7bPDC/KyWHBSwERyMOdst3BRGj1NRrueG69IjFe09pjyP6VTqO9A== X-Received: by 2002:a63:1351:: with SMTP id 17mr7690993pgt.173.1631472391053; Sun, 12 Sep 2021 11:46:31 -0700 (PDT) Received: from [192.168.1.11] ([71.212.134.125]) by smtp.gmail.com with ESMTPSA id p68sm1731602pfb.106.2021.09.12.11.46.30 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 12 Sep 2021 11:46:30 -0700 (PDT) Subject: Re: [PATCH v4 20/30] target/ppc: Introduce PowerPCCPUClass::has_work() To: =?UTF-8?Q?Philippe_Mathieu-Daud=c3=a9?= , qemu-devel@nongnu.org References: <20210912172731.789788-1-f4bug@amsat.org> <20210912172731.789788-21-f4bug@amsat.org> From: Richard Henderson Message-ID: <61ffee53-71e0-0c69-ed54-623e026cf4e9@linaro.org> Date: Sun, 12 Sep 2021 11:46:29 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0 MIME-Version: 1.0 In-Reply-To: <20210912172731.789788-21-f4bug@amsat.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=2607:f8b0:4864:20::42f; envelope-from=richard.henderson@linaro.org; helo=mail-pf1-x42f.google.com X-Spam_score_int: -56 X-Spam_score: -5.7 X-Spam_bar: ----- X-Spam_report: (-5.7 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, NICE_REPLY_A=-3.584, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: David Gibson Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" On 9/12/21 10:27 AM, Philippe Mathieu-Daudé wrote: > We're moving the hook from CPUState to TCGCPUOps. TCGCPUOps is > a const structure, so to avoid creating multiple versions of > the same structure, simply changing the has_work() handler, > introduce yet another indirection with a has_work() handler in > PowerPCCPUClass, and ppc_cpu_has_work() method which dispatch > to it. > > Signed-off-by: Philippe Mathieu-Daudé > --- > target/ppc/cpu-qom.h | 1 + > target/ppc/cpu_init.c | 23 ++++++++++++++--------- > 2 files changed, 15 insertions(+), 9 deletions(-) Reviewed-by: Richard Henderson r~