This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [BUILDROBOT] xtensa fallout (was: Turn DECL_SECTION_NAME into string)


On Tue, Jun 24, 2014 at 10:20 PM, Jan Hubicka <hubicka@ucw.cz> wrote:
>> Hi!
>>
>> This is the xtensa fallout, see http://toolchain.lug-owl.de/buildbot/show_build_details.php?id=272418
>>
>> g++ -c   -g -O2 -DIN_GCC  -DCROSS_DIRECTORY_STRUCTURE  -fno-exceptions -fno-rtti -fasynchronous-unwind-tables -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wmissing-format-attribute -Woverloaded-virtual -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -fno-common  -DHAVE_CONFIG_H -I. -I. -I/home/jbglaw/repos/gcc/gcc -I/home/jbglaw/repos/gcc/gcc/. -I/home/jbglaw/repos/gcc/gcc/../include -I/home/jbglaw/repos/gcc/gcc/../libcpp/include  -I/home/jbglaw/repos/gcc/gcc/../libdecnumber -I/home/jbglaw/repos/gcc/gcc/../libdecnumber/dpd -I../libdecnumber -I/home/jbglaw/repos/gcc/gcc/../libbacktrace    -o insn-preds.o -MT insn-preds.o -MMD -MP -MF ./.deps/insn-preds.TPo insn-preds.c
>> /home/jbglaw/repos/gcc/gcc/config/xtensa/predicates.md: In function âint call_insn_operand_1(rtx, machine_mode)â:
>> /home/jbglaw/repos/gcc/gcc/config/xtensa/predicates.md:113:57: error: cannot convert âconst char*â to âtreeâ in assignment
>> /home/jbglaw/repos/gcc/gcc/config/xtensa/predicates.md:119:46: error: cannot convert âconst char*â to âtreeâ in assignment
>> make[1]: *** [insn-preds.o] Error 1
> Should be fixed by this (and I see in my prevoius mail I wanted TREE_STRING_POINTER)

[resend due to gmail's stupid html-by-default]

This patch looks correct to me, but I haven't watched quite enough of
the underlying change to know that replacing the strcmp with pointer
equality is really the right thing.

If it is, approved for Xtensa.

>
> Index: gcc/config/xtensa/predicates.md
> ===================================================================
> --- gcc/config/xtensa/predicates.md     (revision 211693)
> +++ gcc/config/xtensa/predicates.md     (working copy)
> @@ -97,7 +97,8 @@
>        /* Direct calls only allowed to static functions with PIC.  */
>        if (flag_pic)
>         {
> -         tree callee, callee_sec, caller_sec;
> +         tree callee;
> +         const char * callee_sec, caller_sec;
>
>           if (GET_CODE (op) != SYMBOL_REF
>               || !SYMBOL_REF_LOCAL_P (op) || SYMBOL_REF_EXTERNAL_P (op))
> @@ -117,10 +118,9 @@
>               if (DECL_ONE_ONLY (callee))
>                 return false;
>               callee_sec = DECL_SECTION_NAME (callee);
> -             if (((caller_sec == NULL_TREE) ^ (callee_sec == NULL_TREE))
> -                 || (caller_sec != NULL_TREE
> -                     && strcmp (TREE_STRING_POINTER (caller_sec),
> -                                TREE_STRING_POINTER (callee_sec)) != 0))
> +             if (((caller_sec == NULL) ^ (callee_sec == NULL))
> +                 || (caller_sec != NULL
> +                     && caller_sec != callee_sec))
>                 return false;
>             }
>           else if (caller_sec != NULL_TREE)
>>
>> MfG, JBG
>>
>> --
>>       Jan-Benedict Glaw      jbglaw@lug-owl.de              +49-172-7608481
>> Signature of:           Ich hatte in letzter Zeit ein biÃchen viel Realitycheck.
>> the second  :               Langsam mÃchte ich mal wieder weitertrÃumen kÃnnen.
>>                              -- Maximilian Wilhelm (18. Mai 2005, #lug-owl.de)
>
>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]