public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [RFC 0/6] Flags outputs for asms
@ 2015-05-07 21:39 Richard Henderson
  2015-05-07 21:39 ` [PATCH 5/6] i386: Add CCPmode Richard Henderson
                   ` (6 more replies)
  0 siblings, 7 replies; 33+ messages in thread
From: Richard Henderson @ 2015-05-07 21:39 UTC (permalink / raw)
  To: gcc-patches; +Cc: law, peterz, hpa, torvalds, jakub

Here's a prototype for i386 only, which stands up to light testing.
I'd rather post this tonight rather than wait until tomorrow when I
can write more proper dejagnu tests.

I've tested the intermedate patches via config-list.mk, so despite
mucking around with vec.h vs target.h, all targets still compile.

That said, quite a bit of cleanup in expand_asm_stmt was required
in order to make the target hook not be completely unintelligable,
so depsite full regression testing on x86_64 and ppc64, I could
well have broken something.


r~


void bar(void);

#define DO1(C) \
int s##C(void) { int r; asm("" : "=@cc"#C(r)); return r; } \
int j##C(void) { int r; asm("" : "=@cc"#C(r)); if (!r) bar(); }

#define DO2(C) DO1(C) DO1(n##C)

DO2(a)
DO2(b)
DO2(c)
DO2(e)
DO2(g)
DO2(l)
DO2(o)
DO2(p)
DO2(s)
DO2(z)

DO2(ae)
DO2(be)
DO2(ge)
DO2(le)

---
Richard Henderson (6):
  Only resolve_asm_operand_names once
  Merge expand_asm_operands into expand_asm_stmt
  Canonicalize asm volatility earlier
  Convert to md_asm_adjust
  i386: Add CCPmode
  i386: Implement asm flag outputs

 gcc/cfgexpand.c                | 674 ++++++++++++++++++-----------------------
 gcc/config/cris/cris.c         |  88 +++---
 gcc/config/i386/constraints.md |   5 +
 gcc/config/i386/i386-modes.def |   2 +
 gcc/config/i386/i386.c         | 163 ++++++++--
 gcc/config/mn10300/mn10300.c   |  20 +-
 gcc/config/rs6000/rs6000.c     |  17 +-
 gcc/config/visium/visium.c     |  21 +-
 gcc/config/vxworks.c           |   2 +-
 gcc/doc/tm.texi                |  18 +-
 gcc/doc/tm.texi.in             |   2 +-
 gcc/gimple.c                   |   2 +-
 gcc/gimplify.c                 |   2 +-
 gcc/hooks.c                    |   8 -
 gcc/hooks.h                    |   1 -
 gcc/incpath.c                  |   1 +
 gcc/mode-switching.c           |   2 +-
 gcc/stmt.c                     |   7 +-
 gcc/system.h                   |   1 +
 gcc/target.def                 |  30 +-
 20 files changed, 558 insertions(+), 508 deletions(-)

-- 
2.1.0

^ permalink raw reply	[flat|nested] 33+ messages in thread

end of thread, other threads:[~2015-05-20 17:27 UTC | newest]

Thread overview: 33+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-05-07 21:39 [RFC 0/6] Flags outputs for asms Richard Henderson
2015-05-07 21:39 ` [PATCH 5/6] i386: Add CCPmode Richard Henderson
2015-05-08 18:16   ` Jeff Law
2015-05-07 21:39 ` [PATCH 1/6] Only resolve_asm_operand_names once Richard Henderson
2015-05-08 18:11   ` Jeff Law
2015-05-07 21:39 ` [PATCH 2/6] Merge expand_asm_operands into expand_asm_stmt Richard Henderson
2015-05-08 18:54   ` Jeff Law
2015-05-07 21:39 ` [PATCH 3/6] Canonicalize asm volatility earlier Richard Henderson
2015-05-08 18:12   ` Jeff Law
2015-05-07 21:39 ` [PATCH 4/6] Convert to md_asm_adjust Richard Henderson
2015-05-08 19:41   ` Jeff Law
2015-05-08 19:56     ` Richard Henderson
2015-05-07 21:39 ` [PATCH 6/6] i386: Implement asm flag outputs Richard Henderson
2015-05-08 18:40   ` H. Peter Anvin
2015-05-08 18:45     ` Jeff Law
2015-05-15 15:46   ` [PATCH v2 " Richard Henderson
2015-05-20 16:26     ` Jeff Law
2015-05-20 16:36       ` H. Peter Anvin
2015-05-20 17:28       ` Richard Henderson
2015-05-08  1:15 ` [RFC 0/6] Flags outputs for asms H. Peter Anvin
2015-05-08  1:20   ` H. Peter Anvin
2015-05-08 15:24     ` Richard Henderson
2015-05-08 15:37       ` Jay Foad
2015-05-08 15:39       ` Jeff Law
2015-05-08 15:54   ` Richard Henderson
2015-05-08 17:46     ` H. Peter Anvin
2015-05-08 20:15     ` Richard Henderson
2015-05-08 21:14       ` Segher Boessenkool
2015-05-08 22:11         ` Richard Henderson
2015-05-08 21:33       ` Jeff Law
2015-05-08 21:55         ` Richard Henderson
2015-05-08 22:10         ` Segher Boessenkool
2015-05-11 13:19       ` Segher Boessenkool

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).