On Thu, Sep 20, 2018 at 07:38:04PM -0400, Julian Brown wrote:
> 2018-09-20  Cesar Philippidis  <ce...@codesourcery.com>
>             Julian Brown  <jul...@codesourcery.com>
> 
>       gcc/
>       * omp-low.c (maybe_lookup_field_in_outer_ctx): New function.
>       (convert_to_firstprivate_int): New function.
>       (convert_from_firstprivate_int): New function.
>       (lower_omp_target): Enable GOMP_MAP_FIRSTPRIVATE_INT in OpenACC.
> 
>       libgomp/
>       * oacc-parallel.c (GOACC_parallel_keyed): Handle
>       GOMP_MAP_FIRSTPRIVATE_INT host addresses.
>       * plugin/plugin-nvptx.c (nvptx_exec): Handle
>       GOMP_MAP_FIRSTPRIVATE_INT host addresses.
>       * testsuite/libgomp.oacc-c++/firstprivate-int.C: New test.
>       * testsuite/libgomp.oacc-c-c++-common/firstprivate-int.c: New
>       test.
>       * testsuite/libgomp.oacc-fortran/firstprivate-int.f90: New test.

> @@ -8039,7 +8182,7 @@ lower_omp_target (gimple_stmt_iterator *gsi_p, 
> omp_context *ctx)
>           if (omp_is_reference (ovar))
>             type = TREE_TYPE (type);
>           if ((INTEGRAL_TYPE_P (type)
> -              && TYPE_PRECISION (type) <= POINTER_SIZE)
> +              && tree_to_uhwi (TYPE_SIZE (type)) <= POINTER_SIZE)
>               || TREE_CODE (type) == POINTER_TYPE)
>             {
>               tkind = GOMP_MAP_FIRSTPRIVATE_INT;
> @@ -8194,7 +8337,7 @@ lower_omp_target (gimple_stmt_iterator *gsi_p, 
> omp_context *ctx)
>               if (omp_is_reference (var))
>                 type = TREE_TYPE (type);
>               if ((INTEGRAL_TYPE_P (type)
> -                  && TYPE_PRECISION (type) <= POINTER_SIZE)
> +                  && tree_to_uhwi (TYPE_SIZE (type)) <= POINTER_SIZE)
>                   || TREE_CODE (type) == POINTER_TYPE)
>                 {
>                   x = build_receiver_ref (var, false, ctx);

Why this?

        Jakub

Reply via email to