public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jakub Jelinek <jakub@redhat.com>
To: Tobias Burnus <burnus@net-b.de>
Cc: gcc patches <gcc-patches@gcc.gnu.org>
Subject: Re: [gomp 4.0] Handle OMP_DISPLAY_ENV
Date: Tue, 19 Mar 2013 17:24:00 -0000	[thread overview]
Message-ID: <20130319165008.GG12913@tucnak.redhat.com> (raw)
In-Reply-To: <51488314.6090308@net-b.de>

On Tue, Mar 19, 2013 at 04:24:04PM +0100, Tobias Burnus wrote:
> 2013-03-19  Tobias Burnus  <burnus@net-b.de>
> 
> 	* env.c (handle_omp_display_env): New function.
> 	(initialize_env): Use it.
> 
> diff --git a/libgomp/env.c b/libgomp/env.c
> index 65cbba8..e228bd9 100644
> --- a/libgomp/env.c
> +++ b/libgomp/env.c
> @@ -29,6 +29,8 @@
>  #include "libgomp_f.h"
>  #include <ctype.h>
>  #include <stdlib.h>
> +#include <stdio.h>
> +#include <inttypes.h>	/* For PRIu64.  */

stdio.h is fine, but inttypes.h needs to be
#ifdef HAVE_INTTYPES_H
# include <inttypes.h>
#endif
for portability (libgomp/configure already checks for that).

Guess this then needs to be guarded with
#ifdef HAVE_INTTYPES_H

> +      fprintf (stderr, "  GOMP_SPINCOUNT = '%"PRIu64"'\n",
> +	       (uint64_t) gomp_spin_count_var);

and if not defined, use %ld with (unsigned long) cast instead.

	Jakub

  reply	other threads:[~2013-03-19 17:24 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-19 15:24 Tobias Burnus
2013-03-19 17:24 ` Jakub Jelinek [this message]
2013-03-19 18:05   ` Tobias Burnus
2013-03-19 18:09     ` Jakub Jelinek

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=20130319165008.GG12913@tucnak.redhat.com \
    --to=jakub@redhat.com \
    --cc=burnus@net-b.de \
    --cc=gcc-patches@gcc.gnu.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).