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: Convert profile probabilities to new type


On Thu, Jun 29, 2017 at 11:19 PM, Jan Hubicka <hubicka@ucw.cz> wrote:
>> After this commit (r249800), GCC builds fail for arm and aarch64:
>>
>> /gccsrc/gcc/except.c: In function ???void
>> sjlj_emit_function_enter(rtx_code_label*)???:
>> /gcc-fsf/gccsrc/gcc/except.c:1183: error: conversion from ???int??? to
>> non-scalar type ???profile_probability??? requested
>> make[2]: *** [except.o] Error 1
>
> The following patch should help
> Index: except.c
> ===================================================================
> --- except.c    (revision 249800)
> +++ except.c    (working copy)
> @@ -1180,7 +1180,7 @@ sjlj_emit_function_enter (rtx_code_label
>
>        emit_cmp_and_jump_insns (x, const0_rtx, NE, 0,
>                                TYPE_MODE (integer_type_node), 0,
> -                              dispatch_label, REG_BR_PROB_BASE / 100);
> +                              dispatch_label, profile_probability::unlikely ());
>  #else
>        expand_builtin_setjmp_setup (addr, dispatch_label);
>  #endif
>
>
> I will verify that cross compiler builds and commit it.

I also see on arm-none-eabi:


In file included from
/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/src/gcc/gcc/config/arm/arm-builtins.c:30:0:
/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/src/gcc/gcc/optabs.h:251:10:
error: 'profile_probability' has not been declared
          profile_probability prob
          ^
/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/src/gcc/gcc/optabs.h:252:8:
error: 'profile_probability' has not been declared
      = profile_probability::uninitialized ());
        ^
In file included from
/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/src/gcc/gcc/config/arm/arm-builtins.c:37:0:
/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/src/gcc/gcc/expr.h:291:63:
error: 'profile_probability' has not been declared
 extern int try_casesi (tree, tree, tree, tree, rtx, rtx, rtx,
profile_probability);
                                                               ^
/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/src/gcc/gcc/expr.h:292:61:
error: 'profile_probability' has not been declared
 extern int try_tablejump (tree, tree, tree, tree, rtx, rtx,
profile_probability);
                                                             ^
g++ -fno-PIE -c   -O1 -g -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/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/src/gcc/gcc
-I/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/src/gcc/gcc/.
-I/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/src/gcc/gcc/../include
-I/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/src/gcc/gcc/../libcpp/include
-I/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/build-arm-none-eabi/host-tools/include
-I/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/build-arm-none-eabi/host-tools/include
-I/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/build-arm-none-eabi/host-tools/include
 -I/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/src/gcc/gcc/../libdecnumber
-I/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/src/gcc/gcc/../libdecnumber/dpd
-I../libdecnumber
-I/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/src/gcc/gcc/../libbacktrace
  -o hooks.o -MT hooks.o -MMD -MP -MF ./.deps/hooks.TPo
/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/src/gcc/gcc/hooks.c
make[1]: *** [arm-builtins.o] Error 1
make[1]: *** Waiting for unfinished jobs....
rm gcov-tool.pod gcov.pod gfdl.pod cpp.pod gpl.pod gcov-dump.pod
fsf-funding.pod gcc.pod
make[1]: Leaving directory
`/tmp/66508161.tmpdir/buildbot/rhe6x86_64--arm-none-eabi/build/build-arm-none-eabi/obj/gcc1/gcc'



Ramana



>
> Honza


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