All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sitsofe Wheeler <sitsofe@gmail.com>
To: Bart Van Assche <Bart.VanAssche@wdc.com>
Cc: "fio@vger.kernel.org" <fio@vger.kernel.org>,
	"rebecca@bluestop.org" <rebecca@bluestop.org>,
	"elliott@hpe.com" <elliott@hpe.com>, Jens Axboe <axboe@kernel.dk>
Subject: Re: Windows fio build processor group support testing
Date: Wed, 28 Mar 2018 11:48:06 +0100	[thread overview]
Message-ID: <CALjAwxhnGDcqVsq43ZyeH_Scb+bepT5gBKd0X151WTwNj85v4A@mail.gmail.com> (raw)
In-Reply-To: <a1022d126a861770281f3003eed29b477666c496.camel@wdc.com>

Hi Bart,

On 27 March 2018 at 21:25, Bart Van Assche <Bart.VanAssche@wdc.com> wrote:
> My feedback about these patches is as follows:
> - Having to specify a target Windows version at build time seems wrong to me.
>   What I did myself when I wrote Windows code 15 years ago was to detect at
>   runtime which functionality is available and which functionality is not
>   available. An initialization function could e.g. call LoadLibrary() and
>   GetProcAddress(). The function pointer(s) returned by GetProcAddress() can
>   be stored in global variables. Any function that needs code that is not
>   available on every supported Windows version can then check these function
>   pointers, starting with the most recently introduced function, and call a
>   function that is available on the Windows platform fio has been started on.

I'll note that Jens suggested we could use build time configuration in
https://github.com/axboe/fio/issues/527#issuecomment-363804643 . With
runtime lookup it becomes tricky to test the legacy paths on new
systems because you can no longer force them to be taken (I don't have
access to a Windows before 2012 R2 myself). My hope is that support
for legacy Windows is eventually dropped because:
- Most mainstream versions of Windows before Windows 7/Windows Server
2008 are already EOL (both versions of Server 2008 go EOL in 2020)
- It's unclear who is running fio is running fio in those old Windows
environments

I also suspect we've quietly dropped support for old versions of other
OSes due to build requirements - it looks like it would be a struggle
to build a recent fio for a RHEL 4 era system due compiler
requirements (and who knows if there are other problems when using an
older glibc).

> - Explicit XP / 2000 / etc. version checks seem unfortunate to me because I
>   think these will lead to maintainability problems in the future.

The fact the code has a conditional (either a compile one or a runtime
one) is what's unfortunate and there's a maintenance burden either way
due to increased paths. The only way to save maintenance effort would
be to drop the old path...

> - Your patch series adds a lot of code in header files which will slow down
>   the build. I think such code should be added to .c files instead.

This argument applies to the other bigger os/os-*.h files (e.g.
os/os-linux.h) too but I think making such a change (and ensuring the
pieces that are performance sensitive stay inlinable) could be done in
a separate patch (which would be able to introduce an os.o) in the
future.

-- 
Sitsofe | http://sucs.org/~sits/


  reply	other threads:[~2018-03-28 10:48 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-27 20:13 Windows fio build processor group support testing Sitsofe Wheeler
2018-03-27 20:25 ` Bart Van Assche
2018-03-28 10:48   ` Sitsofe Wheeler [this message]
2018-03-28 14:20     ` Bart Van Assche
2018-03-28 15:08       ` Jens Axboe

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=CALjAwxhnGDcqVsq43ZyeH_Scb+bepT5gBKd0X151WTwNj85v4A@mail.gmail.com \
    --to=sitsofe@gmail.com \
    --cc=Bart.VanAssche@wdc.com \
    --cc=axboe@kernel.dk \
    --cc=elliott@hpe.com \
    --cc=fio@vger.kernel.org \
    --cc=rebecca@bluestop.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.