From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id etCZDsxxaWABBwAAWB0awg (envelope-from ) for ; Sun, 04 Apr 2021 03:59:08 -0400 Received: by simark.ca (Postfix, from userid 112) id 125851EF64; Sun, 4 Apr 2021 03:59:08 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=MAILING_LIST_MULTI autolearn=ham autolearn_force=no version=3.4.2 Received: from sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id CE7FE1E783 for ; Sun, 4 Apr 2021 03:59:06 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 413EF385702E; Sun, 4 Apr 2021 07:59:06 +0000 (GMT) Received: from nx232.node02.secure-mailgate.com (nx232.node02.secure-mailgate.com [192.162.87.232]) by sourceware.org (Postfix) with ESMTPS id 6BF0A385702E for ; Sun, 4 Apr 2021 07:59:04 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 6BF0A385702E Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=trande.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=zied.guermazi@trande.de Received: from host202.checkdomain.de ([185.137.168.148]) by node02.secure-mailgate.com with esmtps (TLSv1.2:AES128-GCM-SHA256:128) (Exim 4.92) (envelope-from ) id 1lSxew-009OAF-Bp for gdb@sourceware.org; Sun, 04 Apr 2021 09:59:03 +0200 X-SecureMailgate-Identity: zied.guermazi@trande.de;host202.checkdomain.de Received: from [192.168.178.48] (x4db377d7.dyn.telefonica.de [77.179.119.215]) (Authenticated sender: zied.guermazi@trande.de) by host202.checkdomain.de (Postfix) with ESMTPSA id 56E4236000E for ; Sun, 4 Apr 2021 09:59:01 +0200 (CEST) X-SecureMailgate-Identity: zied.guermazi@trande.de;host202.checkdomain.de Subject: A lean way for getting the size of the instruction at a given address From: Zied Guermazi To: "gdb@sourceware.org" References: <295a186e-0dd9-fb96-671a-3df0a5611dd9@trande.de> Message-ID: <442482d9-31bd-8101-38f0-fb7c7763e61c@trande.de> Date: Sun, 4 Apr 2021 09:59:01 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <295a186e-0dd9-fb96-671a-3df0a5611dd9@trande.de> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US X-PPP-Message-ID: <20210404075901.2161856.17641@host202.checkdomain.de> X-PPP-Vhost: trande.de X-Originating-IP: 185.137.168.148 X-SecureMailgate-Domain: host202.checkdomain.de X-SecureMailgate-Username: 185.137.168.148 Authentication-Results: secure-mailgate.com; auth=pass smtp.auth=185.137.168.148@host202.checkdomain.de X-SecureMailgate-Outgoing-Class: ham X-SecureMailgate-Outgoing-Evidence: Combined (0.15) X-Recommended-Action: accept X-Filter-ID: Pt3MvcO5N4iKaDQ5O6lkdGlMVN6RH8bjRMzItlySaT9WLQux0N3HQm8ltz8rnu+BPUtbdvnXkggZ 3YnVId/Y5jcf0yeVQAvfjHznO7+bT5yGzVoAbJxoMa0jfLRgi3DeCUOpRM5uOfkO3iUrgpK8CTsG ZkYZkmk8AYMjpuFFQWTilbHtbFYVmmyNP/jzd7CCzPgfBgZM0FjuQW6Y55dUiWNNzfvuNn3kF3iR nRNLgMZT5EwDVDJfkAA42DZhHevYFWY1BYHVa2+d6SAW77yJXQVYrBr/DMlSOZrN4LsiZxr7Gefc 6F/xdjlZn5/8qTdTFDpXnW7vq/flvXA178y90m5hfYCwF5hDWhEkEWhdWvQVHj6xJLYc/wJI0i92 GNa3PgMDF4vjkqkFbyXgLUHk/UOTHlsh2BXMObT/9IxOJJdlYMuuJO1TihPCxlUqmVFHhgZthdmU nPxqYT+Sh7liFchnAoMrVDLtifRyVwNVKOBivazV6zMKE1nI1h58Kf6cqQ3W1HlYYUUjZm7WYWaP +KcNQYvLbS04Teu5Z563qhWdSCGABwb9D8aK2Qif5uut31/E3ahF5MMcDI7KdpjQKcZpHElIdLrM gfFDJudLafs1hjIJWFmvsWc+J+wcmNiAIK/1NH5THMtlYvyHAYGOGiINloeONSMv6A+sGH/yfiSl jMAtJ8Ou1AejrJGC3KslYel/HUZo8bBDA9++hOuXil1NzcVmoGlbDnZTSW2KClz2VQEUFA7XzOp7 a0xOZq1s9GkDUaKWta5toHSUlxFNYClPWN9hPXxP1x+1xtjicbj7at1qaEeZUNC1PyGdjQpHmCf4 0DP7fUpdGPkDVnZ/0HPAm8tV30Xsy7xenUvgUg/z+MB5agRPeUe5aygoOxRp0waaTU22F9j5fWQy Ixz9y0nbINb4fwj1WJ1m56+05wnvW1h/Bmw1dWsFGuZ8MMIgPLkWvwvWWayCE6quqYJVVnz76pbG N2QH6L8B2924PVr1H/aAwarQpYDOYx/6JtUOW3xZrL7fvcWTYrqyXeGGqn2/9PCO0+Cb3kF88+l9 VBdT8YskvY3Kqyw5+xi7i0fw+KU6caGxbi/ntH8t+KA/3RZNkF0dKXJxNGsSNoyByMoFt/wFQVrx flgcgWsGh04lUEIUN3F7U6mYOs2L/vXn7PTasdgG22ADu97X701/0Hg= X-Report-Abuse-To: spam@node04.secure-mailgate.com X-BeenThere: gdb@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-bounces@sourceware.org Sender: "Gdb" hi I need to get the size of the instruction at a given address. I am currently using gdb_insn_length (struct gdbarch *gdbarch, CORE_ADDR addr) which calls gdb_print_insn (struct gdbarch *gdbarch, CORE_ADDR memaddr, struct ui_file *stream, int *branch_delay_insns). and this is consuming a huge time, considering that this is used in branch tracing and this gets repeated up to few millions times. Is there a lean way for getting the size of the instruction at a given address, I am using it for aarch64 and arm targets. Kind Regards Zied Guermazi