public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Andreas Schwab <schwab@linux-m68k.org>
To: "Paul E. Murphy via Libc-alpha" <libc-alpha@sourceware.org>
Subject: Re: [PATCH 4/4] powerpc64le: ifunc (almost) all *f128 routines in multiarch mode
Date: Tue, 05 May 2020 09:07:52 +0200	[thread overview]
Message-ID: <878si6kgfr.fsf@igel.home> (raw)
In-Reply-To: <85f946d6be11c064d5da352b245a9cbb28d0a639.1588628261.git.murphyp@linux.vnet.ibm.com> (Paul E. Murphy via Libc-alpha's message of "Mon, 4 May 2020 17:23:53 -0500")

On Mai 04 2020, Paul E. Murphy via Libc-alpha wrote:

> +$(objpfx)gen-float128-ifuncs.stmp: Makefile
> +	$(make-target-directory)
> +	for gcall in $(gen-libm-f128-ifunc-calls); do    \
> +	  ifile="$${gcall}";                             \
> +	  if [ $${gcall##m_} != $${gcall} ]; then        \
> +	    ifile="s_$${gcall##m_}";                     \
> +	  fi;                                            \
> +	  for cpu in $(f128-march-cpus); do              \
> +	    file=$(objpfx)$${gcall}-$${cpu}.c;           \
> +	    (                                            \
> +	      echo "#include <$${ifile}.c>";             \
> +	    ) > $${file};                                \

There is no need to spawn a subshell here.

> +	  done;                                          \
> +	                                                 \
> +	  name="$${gcall##?_}";                          \
> +	  pfx="$${gcall%%_*}";                           \
> +	  R="";                                          \
> +	  r="";                                          \
> +	  if [ $${gcall##m_} != $${gcall} ]; then        \
> +	    pfx="s";                                     \
> +	  fi;                                            \
> +	  if [ $${#pfx} != 1 ]; then                     \
> +	    pfx="";                                      \
> +	  else                                           \
> +	    pfx="_$${pfx}";                              \
> +	  fi;                                            \
> +	  if [ $${name%%_r} != $${name} ]; then          \
> +	    R="_R";                                      \
> +	    r="_r";                                      \
> +	    name="$${name%%_r}";                         \
> +	  fi;                                            \
> +	  name="$${name%%f128}";                         \
> +	  decl="DECL_ALIAS$${pfx}_$${name}$${r}";        \
> +	  declc="DECL_ALIAS$${R}$${pfx}";                \
> +	  (                                              \
> +	    echo "#include <float128-ifunc.h>";          \
> +	    echo "#ifndef $${decl}";                     \
> +	    echo "# define $${decl}(f) $${declc} (f)";   \
> +	    echo "#endif";                               \
> +	    echo "$${decl} ($${name});";                 \
> +	  ) > $(objpfx)$${gcall}-ifunc.c;                \

Likewise.

Andreas.

-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510  2552 DF73 E780 A9DA AEC1
"And now for something completely different."

      parent reply	other threads:[~2020-05-05  7:07 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-04 22:23 [PATCH 1/4] ldbl-128: refactor nexttoward alias using new macro Paul E. Murphy
2020-05-04 22:23 ` [PATCH 2/4] powerpc64le: refactor e_sqrtf128.c Paul E. Murphy
2020-05-04 22:23 ` [PATCH 3/4] powerpc64le: refactor fmaf128 Paul E. Murphy
2020-05-04 22:23 ` [PATCH 4/4] powerpc64le: ifunc (almost) all *f128 routines in multiarch mode Paul E. Murphy
2020-05-05  0:07   ` Joseph Myers
2020-05-05  7:07   ` Andreas Schwab [this message]

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=878si6kgfr.fsf@igel.home \
    --to=schwab@linux-m68k.org \
    --cc=libc-alpha@sourceware.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).