From: Andrew Pinski Date: Wed, 26 Feb 2014 00:51:56 +0000 (+0000) Subject: builtins.c (expand_builtin_thread_pointer): Create a new target when the target is... X-Git-Tag: upstream/12.2.0~64476 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b8a542c64830635d1716130f41da4c7a165b5872;p=platform%2Fupstream%2Fgcc.git builtins.c (expand_builtin_thread_pointer): Create a new target when the target is NULL. 2014-02-25 Andrew Pinski * builtins.c (expand_builtin_thread_pointer): Create a new target when the target is NULL. From-SVN: r208163 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 616d8ec..713baf4 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2014-02-25 Andrew Pinski + + * builtins.c (expand_builtin_thread_pointer): Create a new target + when the target is NULL. + 2014-02-25 Vladimir Makarov PR rtl-optimization/60317 diff --git a/gcc/builtins.c b/gcc/builtins.c index 35969ad..7c6318e 100644 --- a/gcc/builtins.c +++ b/gcc/builtins.c @@ -5712,7 +5712,10 @@ expand_builtin_thread_pointer (tree exp, rtx target) if (icode != CODE_FOR_nothing) { struct expand_operand op; - if (!REG_P (target) || GET_MODE (target) != Pmode) + /* If the target is not sutitable then create a new target. */ + if (target == NULL_RTX + || !REG_P (target) + || GET_MODE (target) != Pmode) target = gen_reg_rtx (Pmode); create_output_operand (&op, target, Pmode); expand_insn (icode, 1, &op);