public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] rs6000 branch probability changes
@ 2017-06-30 13:36 David Edelsohn
  2017-06-30 21:36 ` Ramana Radhakrishnan
  0 siblings, 1 reply; 8+ messages in thread
From: David Edelsohn @ 2017-06-30 13:36 UTC (permalink / raw)
  To: Segher Boessenkool; +Cc: GCC Patches

Convert the rs6000 port to use the new API for branch probabilities.

Okay?

Thanks, David

* config/rs6000/rs6000.c (emit_unlikely_jump): Adjust to new branch
probability data type.

Index: rs6000.c
===================================================================
--- rs6000.c (revision 249839)
+++ rs6000.c (working copy)
@@ -23514,10 +23514,9 @@
 static void
 emit_unlikely_jump (rtx cond, rtx label)
 {
-  int very_unlikely = REG_BR_PROB_BASE / 100 - 1;
   rtx x = gen_rtx_IF_THEN_ELSE (VOIDmode, cond, label, pc_rtx);
   rtx_insn *insn = emit_jump_insn (gen_rtx_SET (pc_rtx, x));
-  add_int_reg_note (insn, REG_BR_PROB, very_unlikely);
+  add_int_reg_note (insn, REG_BR_PROB, profile_probability::very_unlikely ());
 }

 /* A subroutine of the atomic operation splitters.  Emit a load-locked

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

end of thread, other threads:[~2017-07-01 13:34 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-30 13:36 [PATCH] rs6000 branch probability changes David Edelsohn
2017-06-30 21:36 ` Ramana Radhakrishnan
2017-06-30 23:18   ` Segher Boessenkool
2017-07-01 12:59     ` David Edelsohn
2017-07-01 13:06       ` Jan Hubicka
2017-07-01 13:19         ` David Edelsohn
2017-07-01 13:23           ` Jan Hubicka
2017-07-01 13:34           ` Jan Hubicka

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