public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: "Julio Guerra" <julio@farjump.io>
To: "Corinna Vinschen" <vinschen@redhat.com>,
	"Pedro Alves" <palves@redhat.com>
Cc: "gdb-patches@sourceware.org" <gdb-patches@sourceware.org>
Subject: Re: [PATCH] Do not clear the value of st_dev in File I/O's stat()
Date: Mon, 28 May 2018 12:49:00 -0000	[thread overview]
Message-ID: <01020163a6b434b4-79b66ed1-e2f7-4333-b7cc-94986e13b161-000000@eu-west-1.amazonses.com> (raw)
In-Reply-To: <20180528104153.GA3501@calimero.vinschen.de>


> The idea was that st_dev values on one system don't make sense on
> another system.  Also, st_dev values for files reflect the underlying
> partition on the inferior system, which doesn't mean anything to the GDB
> host system.
>
> I don't know how important backward compat is here, but there may
> be code out there which still relies on the simple file vs. console
> st_dev from stat().  Version check?
>
> Other than that, if you think that this is an outdated approach, just
> make sure to change the docs as well.

I think the approach is still valid, otherwise it would be like if the
target program should know the host. Which reminds me that with
remote_fileio_fstat(), I have the case where my host st_dev has 64 bits,
which doesn't fit into fileio's 32-bit fst_dev.

I think I should resubmit this patch along with my other patch allowing
to "open non regular files" so that I add common device ids (link, fifo,
etc.) to the list of returned fst_dev, and I modify
remote_fileio_fstat() so that it applies the same values to fst_dev.

-- 
Julio Guerra
Co-founder & CTO of Farjump
Mobile: +33 618 644 164
LinkedIn: https://linkedin.com/in/guerrajulio
Slack: farjump.slack.com

  parent reply	other threads:[~2018-05-28 12:23 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20180517082631.26855-1-julio@farjump.io>
2018-05-17 10:32 ` Julio Guerra
2018-05-17 15:31   ` Pedro Alves
     [not found]     ` <496efebf-0f96-4586-de39-0a1857994f04@farjump.io>
2018-05-18 18:29       ` Julio Guerra
2018-05-28 10:50     ` Corinna Vinschen
     [not found]       ` <6f5980ae-247c-1991-ba3c-884fe04a94c5@farjump.io>
2018-05-28 12:49         ` Julio Guerra [this message]
2018-05-28 13:18           ` Pedro Alves

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=01020163a6b434b4-79b66ed1-e2f7-4333-b7cc-94986e13b161-000000@eu-west-1.amazonses.com \
    --to=julio@farjump.io \
    --cc=gdb-patches@sourceware.org \
    --cc=palves@redhat.com \
    --cc=vinschen@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).