From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp-out1.suse.de (smtp-out1.suse.de [IPv6:2001:67c:2178:6::1c]) by sourceware.org (Postfix) with ESMTPS id D04D53858C62 for ; Mon, 7 Nov 2022 16:44:35 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org D04D53858C62 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=suse.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.de Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 17D592244A; Mon, 7 Nov 2022 16:44:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1667839475; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=XcxkeNkJ82ID3s1lXBNmJlu9zkHMNUCRYBJuUSRKR+g=; b=kmmA95Qf58kul75gFL5pdsqe5DW1j2j1oEdOkh/TPwEwMsK4K5Aat3WKQW9EYISEUdc4OG OqCgjl2+DBKSKYxYkQ4NP0h5HXzKO7kpQj/UnH1nBonJl1PZ4fVWD2FXz//W+XVjevNFhV u076q0vAJFjuOi+tzvmp/yaaaKrvH/c= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1667839475; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=XcxkeNkJ82ID3s1lXBNmJlu9zkHMNUCRYBJuUSRKR+g=; b=L948ky4yC8WRzuweROqWxat4AMCgvr/L9J+q2EZ5JqlJ5tqs39dgKfhWkdTzIfPqgjzp0h 0pi8eF/gUT4ndiAw== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id DA5C413AC7; Mon, 7 Nov 2022 16:44:34 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id zbBnM/I1aWOvagAAMHmgww (envelope-from ); Mon, 07 Nov 2022 16:44:34 +0000 Message-ID: Date: Mon, 7 Nov 2022 17:44:34 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.2.2 Subject: Re: [PATCH 2/7] [gdb/testsuite] fix test gdb.base/print-file-var.exp for remote execution Content-Language: en-US To: Ivan Tetyushkin , Andrew Burgess , gdb-patches@sourceware.org, Andrew Burgess References: <20221025162946.727169-1-ivan.tetyushkin@syntacore.com> <20221025162946.727169-3-ivan.tetyushkin@syntacore.com> <87cz9yc2kz.fsf@redhat.com> <5111034b-a2ad-ef85-9498-dd2603122a38@syntacore.com> From: Tom de Vries In-Reply-To: <5111034b-a2ad-ef85-9498-dd2603122a38@syntacore.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-6.6 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 11/7/22 14:49, Ivan Tetyushkin wrote: > Hi > Yes, this patch fixes this test. However, it will not fix gdb.base/infcall-exec.exp from the patch 5/7 of this thread. Hi Ivan, thanks for reporting the problem and proposing fixes. I went ahead and proposed a series, borrowing from yours, submitted here ( https://sourceware.org/pipermail/gdb-patches/2022-November/193518.html ). That test-case is also addressed there. > As I can understand now, this test uses absolute paths for checking, but relative paths are used during compilation. We can change regexp itself and check only filename, but this could lead to false positive result. The gdb.base/infcall-exec.exp test-case checks that an inferior function call which execs a new program is handled ok. This is the main function of the test, and absolute vs relative paths is not an interesting aspect to check. > Also, I thought these tests are created to work with absolute paths to ignore solib-search-path. Maybe with local target, but for remote target we do use solib-search-path. The overall problem is that there's no reliable way to do construct an absolute path on a remote target (which could f.i. be using \ instead of / as path separator), or at least not an easy one. We could do something like using remote_exec for "echo \"puts [file normalize .$file]\" | tclsh " but that requires tcl on the target. So AFAIU, until dejagnu decided to support that natively, we just have to use the filenames as returned by remote_download. On a different topic, do you have a copyright assignment? Assuming you don't, with this submission you've probably used up your legally non-significant contribution amount, and for a new submission you'd need a copyright assignment (and unfortunately, it can take some time to get it done). Thanks, - Tom