Flexible I/O Tester development
 help / color / mirror / Atom feed
From: Daniel Gollub <daniel.gollub@t-online.de>
To: Jens Axboe <axboe@kernel.dk>
Cc: fio@vger.kernel.org, Daniel Gollub <d.gollub@telekom.de>
Subject: Re: [PATCH] Fix g++ warning about void* used in arithmetic
Date: Thu, 13 Feb 2014 07:13:57 +0100	[thread overview]
Message-ID: <20140213071357.36e92383@marvin> (raw)
In-Reply-To: <52FC45E9.3090101@kernel.dk>

Hi Jens,

On Wed, 12 Feb 2014 21:11:21 -0700, Jens Axboe wrote:
> On 2014-02-12 11:25, Daniel Gollub wrote:
> > ../parse.h: In function ‘void* td_var(thread_options*, fio_option*,
> > unsigned int)’: ../parse.h:110:10: warning: pointer of type ‘void
> > *’ used in arithmetic [-Wpointer-arith] ../parse.h:112:9: warning:
> > pointer of type ‘void *’ used in arithmetic [-Wpointer-arith]
> 
> I bet there are a lot of these, or other similar code that would
> prevent compiling with g++. I'm dubious of the value add here. Fio is
> written in C, after all.
> 

I should have mentioned this in the commit message: this is required to
compile an external ionengine written in C++. I do not try to compile
entire fio with g++. If I include fio.h in the external ioengine,
parse.h gets included by fio.h or so and causes this g++ warning.

This was the last warning (which just got introduced 2 days
ago) when fio.h gets included by an external engine build with g++.

So the value here is to build external ioengines against libraries/APIs
which are only available in C++. In my case against an internal library
of CEPH.


-- 
Daniel Gollub


  reply	other threads:[~2014-02-13  6:13 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-12 18:25 [PATCH] Fix g++ warning about void* used in arithmetic Daniel Gollub
2014-02-13  4:11 ` Jens Axboe
2014-02-13  6:13   ` Daniel Gollub [this message]
2014-02-13 10:32     ` Erwan Velu
2014-02-13 16:27       ` fio ioengines for CEPH (was: RE: [PATCH] Fix g++ warning about void* used in arithmetic) Gollub, Daniel
2014-02-13 15:05     ` [PATCH] Fix g++ warning about void* used in arithmetic 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=20140213071357.36e92383@marvin \
    --to=daniel.gollub@t-online.de \
    --cc=axboe@kernel.dk \
    --cc=d.gollub@telekom.de \
    --cc=fio@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox