GCC Middle and Back End API Reference
omp-offload.cc File Reference
#include "config.h"
#include "system.h"
#include "coretypes.h"
#include "backend.h"
#include "target.h"
#include "tree.h"
#include "gimple.h"
#include "tree-pass.h"
#include "ssa.h"
#include "cgraph.h"
#include "pretty-print.h"
#include "diagnostic-core.h"
#include "fold-const.h"
#include "internal-fn.h"
#include "langhooks.h"
#include "gimplify.h"
#include "gimple-iterator.h"
#include "gimplify-me.h"
#include "gimple-walk.h"
#include "tree-cfg.h"
#include "tree-into-ssa.h"
#include "tree-nested.h"
#include "stor-layout.h"
#include "common/common-target.h"
#include "omp-general.h"
#include "omp-offload.h"
#include "lto-section-names.h"
#include "gomp-constants.h"
#include "gimple-pretty-print.h"
#include "intl.h"
#include "stringpool.h"
#include "attribs.h"
#include "cfgloop.h"
#include "context.h"
#include "convert.h"
#include "opts.h"
#include "sync-builtins.def"
Include dependency graph for omp-offload.cc:

Data Structures

struct  oacc_loop
 
struct  var_decl_rewrite_info
 

Macros

#define DEF_SYNC_BUILTIN(ENUM, NAME, TYPE, ATTRS)
 

Functions

int oacc_fn_attrib_level (tree attr)
 
static void add_decls_addresses_to_decl_constructor (vec< tree, va_gc > *v_decls, vec< constructor_elt, va_gc > *v_ctor)
 
static bool omp_declare_target_fn_p (tree decl)
 
static bool omp_declare_target_var_p (tree decl)
 
static tree omp_discover_declare_target_tgt_fn_r (tree *tp, int *walk_subtrees, void *data)
 
static tree omp_discover_declare_target_fn_r (tree *tp, int *walk_subtrees, void *data)
 
static tree omp_discover_declare_target_var_r (tree *tp, int *walk_subtrees, void *data)
 
void omp_discover_implicit_declare_target (void)
 
void omp_finish_file (void)
 
static tree oacc_dim_call (bool pos, int dim, gimple_seq *seq)
 
static tree oacc_thread_numbers (bool pos, int mask, gimple_seq *seq)
 
static void oacc_xform_loop (gcall *call)
 
static void oacc_xform_tile (gcall *call)
 
int oacc_get_default_dim (int dim)
 
int oacc_get_min_dim (int dim)
 
static void oacc_parse_default_dims (const char *dims)
 
static void oacc_validate_dims (tree fn, tree attrs, int *dims, int level, unsigned used)
 
static oacc_loopnew_oacc_loop_raw (oacc_loop *parent, location_t loc)
 
static oacc_loopnew_oacc_loop_outer (tree decl)
 
static oacc_loopnew_oacc_loop (oacc_loop *parent, gcall *marker)
 
static void new_oacc_loop_routine (oacc_loop *parent, gcall *call, tree decl, tree attrs)
 
static oacc_loopfinish_oacc_loop (oacc_loop *loop)
 
static void free_oacc_loop (oacc_loop *loop)
 
static void dump_oacc_loop_part (FILE *file, gcall *from, int depth, const char *title, int level)
 
static void dump_oacc_loop (FILE *file, oacc_loop *loop, int depth)
 
void debug_oacc_loop (oacc_loop *)
 
static void inform_oacc_loop (const oacc_loop *loop)
 
static void oacc_loop_discover_walk (oacc_loop *loop, basic_block bb)
 
static oacc_loopoacc_loop_sibling_nreverse (oacc_loop *loop)
 
static oacc_loopoacc_loop_discovery ()
 
static void oacc_loop_xform_head_tail (gcall *from, int level)
 
static void oacc_loop_process (oacc_loop *loop, int fn_level)
 
static unsigned oacc_loop_fixed_partitions (oacc_loop *loop, unsigned outer_mask)
 
static unsigned oacc_loop_auto_partitions (oacc_loop *loop, unsigned outer_mask, bool outer_assign)
 
static unsigned oacc_loop_partition (oacc_loop *loop, unsigned outer_mask)
 
bool default_goacc_fork_join (gcall *ARG_UNUSED(call), const int *ARG_UNUSED(dims), bool is_fork)
 
void default_goacc_reduction (gcall *call)
 
static tree oacc_rewrite_var_decl (tree *tp, int *walk_subtrees, void *data)
 
static bool is_sync_builtin_call (gcall *call)
 
static unsigned int execute_oacc_loop_designation ()
 
static unsigned int execute_oacc_device_lower ()
 
bool default_goacc_validate_dims (tree ARG_UNUSED(decl), int *dims, int ARG_UNUSED(fn_level), unsigned ARG_UNUSED(used))
 
int default_goacc_dim_limit (int ARG_UNUSED(axis))
 
gimple_opt_passmake_pass_oacc_loop_designation (gcc::context *ctxt)
 
gimple_opt_passmake_pass_oacc_device_lower (gcc::context *ctxt)
 
static void ompdevlow_adjust_simt_enter (gimple_stmt_iterator *gsi, bool *regimplify)
 
static tree find_simtpriv_var_op (tree *tp, int *walk_subtrees, void *)
 
static unsigned int execute_omp_device_lower ()
 
gimple_opt_passmake_pass_omp_device_lower (gcc::context *ctxt)
 
gimple_opt_passmake_pass_omp_target_link (gcc::context *ctxt)
 

Variables

vec< tree, va_gc > * offload_funcs
 
vec< tree, va_gc > * offload_vars
 
vec< tree, va_gc > * offload_ind_funcs
 
static int oacc_default_dims [GOMP_DIM_MAX]
 
static int oacc_min_dims [GOMP_DIM_MAX]
 

Macro Definition Documentation

◆ DEF_SYNC_BUILTIN

#define DEF_SYNC_BUILTIN ( ENUM,
NAME,
TYPE,
ATTRS )
Value:
case ENUM:
@ ENUM
Definition gengtype.h:476

Function Documentation

◆ add_decls_addresses_to_decl_constructor()

static void add_decls_addresses_to_decl_constructor ( vec< tree, va_gc > * v_decls,
vec< constructor_elt, va_gc > * v_ctor )
static

◆ debug_oacc_loop()

DEBUG_FUNCTION void debug_oacc_loop ( oacc_loop * loop)
Dump loops to stderr.   

References dump_oacc_loop().

◆ default_goacc_dim_limit()

int default_goacc_dim_limit ( int ARG_UNUSEDaxis)
Default dimension bound is unknown on accelerator and 1 on host.   

◆ default_goacc_fork_join()

bool default_goacc_fork_join ( gcall * ARG_UNUSEDcall,
const int * ARG_UNUSEDdims,
bool is_fork )
Default fork/join early expander.  Delete the function calls if
there is no RTL expander.   

References targetm.

◆ default_goacc_reduction()

void default_goacc_reduction ( gcall * call)
Default goacc.reduction early expander.

LHS-opt = IFN_REDUCTION (KIND, RES_PTR, VAR, LEVEL, OP, OFFSET)
If RES_PTR is not integer-zerop:
    SETUP - emit 'LHS = *RES_PTR', LHS = NULL
    TEARDOWN - emit '*RES_PTR = VAR'
If LHS is not NULL
    emit 'LHS = VAR'    

References build_simple_mem_ref, gimple_build_assign(), gimple_call_arg(), gimple_call_lhs(), gimple_seq_add_stmt(), gsi_for_stmt(), gsi_replace_with_seq(), integer_zerop(), NULL, and TREE_INT_CST_LOW.

Referenced by execute_oacc_device_lower().

◆ default_goacc_validate_dims()

bool default_goacc_validate_dims ( tree ARG_UNUSEDdecl,
int * dims,
int ARG_UNUSEDfn_level,
unsigned ARG_UNUSEDused )
Default launch dimension validator.  Force everything to 1.  A
backend that wants to provide larger dimensions must override this
hook.   

References changed.

◆ dump_oacc_loop()

static void dump_oacc_loop ( FILE * file,
oacc_loop * loop,
int depth )
static

◆ dump_oacc_loop_part()

static void dump_oacc_loop_part ( FILE * file,
gcall * from,
int depth,
const char * title,
int level )
static

◆ execute_oacc_device_lower()

◆ execute_oacc_loop_designation()

◆ execute_omp_device_lower()

static unsigned int execute_omp_device_lower ( )
static
Cleanup uses of SIMT placeholder internal functions: on non-SIMT targets,
VF is 1 and LANE is 0; on SIMT targets, VF is folded to a constant, and
LANE is kept to be expanded to RTL later on.  Also cleanup all other SIMT
internal functions on non-SIMT targets, and likewise some SIMD internal
functions on SIMT targets.   

References symtab_node::address_taken, build_int_cst(), build_one_cst(), build_zero_cst(), builtin_decl_explicit(), cgraph_node::calls_declare_variant_alt, cfun, create_tmp_reg(), dyn_cast(), find_simtpriv_var_op(), FOR_EACH_BB_FN, FOR_EACH_BB_REVERSE_FN, gcc_assert, cgraph_node::get(), gimple_build_assign(), gimple_build_call(), gimple_build_nop(), gimple_call_arg(), gimple_call_builtin_p(), gimple_call_fn(), gimple_call_fndecl(), gimple_call_internal_fn(), gimple_call_internal_p(), gimple_call_lhs(), gimple_call_set_arg(), gimple_call_set_fn(), gimple_call_set_fndecl(), gimple_call_set_lhs(), gimple_clobber_p(), gimple_location(), gimple_regimplify_operands(), gimple_set_location(), gsi_end_p(), gsi_insert_before(), gsi_last_bb(), gsi_next(), gsi_prev(), gsi_remove(), gsi_replace(), GSI_SAME_STMT, gsi_start_bb(), gsi_stmt(), i, integer_one_node, integer_type_node, integer_zero_node, is_gimple_call(), symtab_node::need_lto_streaming, NULL, null_pointer_node, NULL_TREE, offload_funcs, offload_ind_funcs, symtab_node::offloadable, omp_resolve_declare_variant(), ompdevlow_adjust_simt_enter(), targetm, TREE_CODE, TREE_OPERAND, TREE_TYPE, unlink_stmt_vdef(), update_stmt(), vec_safe_length(), and walk_gimple_stmt().

◆ find_simtpriv_var_op()

static tree find_simtpriv_var_op ( tree * tp,
int * walk_subtrees,
void *  )
static
Callback for walk_gimple_stmt used to scan for SIMT-privatized variables.   

References DECL_ATTRIBUTES, DECL_HAS_VALUE_EXPR_P, lookup_attribute(), NULL_TREE, and VAR_P.

Referenced by execute_omp_device_lower().

◆ finish_oacc_loop()

static oacc_loop * finish_oacc_loop ( oacc_loop * loop)
static
Finish off the current OpenACC loop ending at tail marker TAIL.
Return the parent loop.   

Referenced by oacc_loop_discover_walk().

◆ free_oacc_loop()

static void free_oacc_loop ( oacc_loop * loop)
static
Free all OpenACC loop structures within LOOP (inclusive).   

References free(), and free_oacc_loop().

Referenced by execute_oacc_loop_designation(), and free_oacc_loop().

◆ inform_oacc_loop()

static void inform_oacc_loop ( const oacc_loop * loop)
static
Provide diagnostics on OpenACC loop LOOP, its children, and its
siblings.   

References dump_printf_loc(), dump_user_location_t::from_location_t(), inform_oacc_loop(), and MSG_OPTIMIZED_LOCATIONS.

Referenced by execute_oacc_loop_designation(), and inform_oacc_loop().

◆ is_sync_builtin_call()

static bool is_sync_builtin_call ( gcall * call)
static
Return TRUE if CALL is a call to a builtin atomic/sync operation.   
This file contains the definitions and documentation for the
   synchronization builtins used in the GNU compiler.
   Copyright (C) 2005-2024 Free Software Foundation, Inc.

This file is part of GCC.

GCC is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free
Software Foundation; either version 3, or (at your option) any later
version.

GCC is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
for more details.

You should have received a copy of the GNU General Public License
along with GCC; see the file COPYING3.  If not see
<http://www.gnu.org/licenses/>.   
Before including this file, you should define a macro:

  DEF_SYNC_BUILTIN (ENUM, NAME, TYPE, ATTRS)

See builtins.def for details.   
Synchronization Primitives.  The "_N" version is the one that the user
is supposed to be using.  It's overloaded, and is resolved to one of the
"_1" through "_16" versions, plus some extra casts.   
__sync* builtins for the C++ memory model.   
This one is actually a function in libatomic and not expected to be
inlined, declared here for convenience of targets generating calls
to it.   

References BUILT_IN_NORMAL, DECL_FUNCTION_CODE(), gimple_call_builtin_p(), gimple_call_fndecl(), and NULL_TREE.

Referenced by execute_oacc_device_lower().

◆ make_pass_oacc_device_lower()

gimple_opt_pass * make_pass_oacc_device_lower ( gcc::context * ctxt)

◆ make_pass_oacc_loop_designation()

gimple_opt_pass * make_pass_oacc_loop_designation ( gcc::context * ctxt)

◆ make_pass_omp_device_lower()

gimple_opt_pass * make_pass_omp_device_lower ( gcc::context * ctxt)

◆ make_pass_omp_target_link()

gimple_opt_pass * make_pass_omp_target_link ( gcc::context * ctxt)

◆ new_oacc_loop()

static oacc_loop * new_oacc_loop ( oacc_loop * parent,
gcall * marker )
static
Start a new OpenACC loop  structure beginning at head marker HEAD.
Link into PARENT loop.  Return the new loop.   

References gimple_call_arg(), gimple_location(), integer_zero_node, new_oacc_loop_raw(), OLF_GANG_STATIC, and TREE_INT_CST_LOW.

Referenced by oacc_loop_discover_walk().

◆ new_oacc_loop_outer()

static oacc_loop * new_oacc_loop_outer ( tree decl)
static
Create an outermost, dummy OpenACC loop for offloaded function
DECL.   

References DECL_SOURCE_LOCATION, new_oacc_loop_raw(), and NULL.

Referenced by oacc_loop_discovery().

◆ new_oacc_loop_raw()

static oacc_loop * new_oacc_loop_raw ( oacc_loop * parent,
location_t loc )
static
Create an empty OpenACC loop structure at LOC.   

References oacc_loop::child.

Referenced by execute_oacc_loop_designation(), new_oacc_loop(), new_oacc_loop_outer(), and new_oacc_loop_routine().

◆ new_oacc_loop_routine()

static void new_oacc_loop_routine ( oacc_loop * parent,
gcall * call,
tree decl,
tree attrs )
static
Create a dummy loop encompassing a call to a openACC routine.
Extract the routine's partitioning requirements.   

References gcc_assert, gimple_location(), new_oacc_loop_raw(), and oacc_fn_attrib_level().

Referenced by oacc_loop_discover_walk().

◆ oacc_dim_call()

static tree oacc_dim_call ( bool pos,
int dim,
gimple_seq * seq )
static
Call dim_pos (POS == true) or dim_size (POS == false) builtins for
axis DIM.  Return a tmp var holding the result.   

References build_int_cst(), create_tmp_var, gimple_build_call_internal(), gimple_call_set_lhs(), gimple_seq_add_stmt(), integer_type_node, and unsigned_type_node.

Referenced by oacc_thread_numbers(), and oacc_xform_tile().

◆ oacc_fn_attrib_level()

int oacc_fn_attrib_level ( tree attr)
Return level at which oacc routine may spawn a partitioned loop, or
-1 if it is not a routine (i.e. is an offload fn).   

References integer_zerop(), TREE_CHAIN, TREE_PURPOSE, and TREE_VALUE.

Referenced by execute_oacc_loop_designation(), new_oacc_loop_routine(), and omp_sese_active_worker_call().

◆ oacc_get_default_dim()

int oacc_get_default_dim ( int dim)
Bits of OpenMP and OpenACC handling that is specific to device offloading
   and a lowering pass for OpenACC device directives.

   Copyright (C) 2005-2024 Free Software Foundation, Inc.

This file is part of GCC.

GCC is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free
Software Foundation; either version 3, or (at your option) any later
version.

GCC is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
for more details.

You should have received a copy of the GNU General Public License
along with GCC; see the file COPYING3.  If not see
<http://www.gnu.org/licenses/>.   

References gcc_assert, and oacc_default_dims.

◆ oacc_get_min_dim()

int oacc_get_min_dim ( int dim)

References gcc_assert, and oacc_min_dims.

◆ oacc_loop_auto_partitions()

static unsigned oacc_loop_auto_partitions ( oacc_loop * loop,
unsigned outer_mask,
bool outer_assign )
static
Walk the OpenACC loop heirarchy to assign auto-partitioned loops.
OUTER_MASK is the partitioning this loop is contained within.
OUTER_ASSIGN is true if an outer loop is being auto-partitioned.
Return the cumulative partitioning used by this loop, siblings and
children.   

References dump_file, G_, loop::inner, least_bit_hwi(), LOCATION_FILE, LOCATION_LINE, oacc_loop_auto_partitions(), OLF_AUTO, OLF_INDEPENDENT, OLF_TILE, and warning_at().

Referenced by oacc_loop_auto_partitions(), and oacc_loop_partition().

◆ oacc_loop_discover_walk()

◆ oacc_loop_discovery()

static oacc_loop * oacc_loop_discovery ( )
static
Discover the OpenACC loops marked up by HEAD and TAIL markers for
the current function.   

References cfun, clear_bb_flags(), current_function_decl, ENTRY_BLOCK_PTR_FOR_FN, new_oacc_loop_outer(), oacc_loop_discover_walk(), and oacc_loop_sibling_nreverse().

Referenced by execute_oacc_loop_designation().

◆ oacc_loop_fixed_partitions()

static unsigned oacc_loop_fixed_partitions ( oacc_loop * loop,
unsigned outer_mask )
static
Walk the OpenACC loop heirarchy checking and assigning the
programmer-specified partitionings.  OUTER_MASK is the partitioning
this loop is contained within.  Return mask of partitioning
encountered.  If any auto loops are discovered, set GOMP_DIM_MAX
bit.   

References DECL_SOURCE_LOCATION, dump_file, oacc_loop::e_mask, error_at(), oacc_loop::flags, G_, inform(), loop::inner, least_bit_hwi(), oacc_loop::loc, LOCATION_FILE, LOCATION_LINE, oacc_loop::mask, oacc_loop_fixed_partitions(), OLF_AUTO, OLF_DIM_BASE, OLF_INDEPENDENT, OLF_SEQ, OLF_TILE, and oacc_loop::parent.

Referenced by oacc_loop_fixed_partitions(), and oacc_loop_partition().

◆ oacc_loop_partition()

static unsigned oacc_loop_partition ( oacc_loop * loop,
unsigned outer_mask )
static
Walk the OpenACC loop heirarchy to check and assign partitioning
axes.  Return mask of partitioning.   

References oacc_loop_auto_partitions(), and oacc_loop_fixed_partitions().

Referenced by execute_oacc_loop_designation().

◆ oacc_loop_process()

static void oacc_loop_process ( oacc_loop * loop,
int fn_level )
static

◆ oacc_loop_sibling_nreverse()

static oacc_loop * oacc_loop_sibling_nreverse ( oacc_loop * loop)
static
LOOP is the first sibling.  Reverse the order in place and return
the new first sibling.  Recurse to child loops.   

References last, loop::next, NULL, and oacc_loop_sibling_nreverse().

Referenced by oacc_loop_discovery(), and oacc_loop_sibling_nreverse().

◆ oacc_loop_xform_head_tail()

static void oacc_loop_xform_head_tail ( gcall * from,
int level )
static
Transform the abstract internal function markers starting at FROM
to be for partitioning level LEVEL.  Stop when we meet another HEAD
or TAIL  marker.   

References build_int_cst(), gimple_call_arg(), gimple_call_arg_ptr(), gimple_call_internal_p(), gsi_bb(), gsi_end_p(), gsi_for_stmt(), gsi_next(), gsi_start_bb(), gsi_stmt(), single_succ(), TREE_INT_CST_LOW, unsigned_type_node, and update_stmt().

Referenced by oacc_loop_process().

◆ oacc_parse_default_dims()

static void oacc_parse_default_dims ( const char * dims)
static
Parse the default dimension parameter.  This is a set of
:-separated optional compute dimensions.  Each specified dimension
is a positive integer.  When device type support is added, it is
planned to be a comma separated list of such compute dimensions,
with all but the first prefixed by the colon-terminated device
type.   

References CONST_CAST, errno, error_at(), NULL, NULL_TREE, oacc_default_dims, oacc_min_dims, targetm, and UNKNOWN_LOCATION.

Referenced by execute_oacc_loop_designation().

◆ oacc_rewrite_var_decl()

static tree oacc_rewrite_var_decl ( tree * tp,
int * walk_subtrees,
void * data )
static
Helper function for execute_oacc_device_lower.  Rewrite VAR_DECLs (by
themselves or wrapped in various other nodes) according to ADJUSTED_VARS in
the var_decl_rewrite_info pointed to via DATA.  Used as part of coercing
gang-private variables in OpenACC offload regions to reside in GPU shared
memory.   

References var_decl_rewrite_info::adjusted_vars, var_decl_rewrite_info::avoid_pointer_conversion, build_fold_addr_expr, build_qualified_type(), convert_to_pointer(), field_type(), hash_map< KeyId, Value, Traits >::get(), gimple_assign_lhs(), gimple_build_assign(), gsi_for_stmt(), gsi_insert_before(), GSI_SAME_STMT, make_ssa_name(), var_decl_rewrite_info::modified, NULL, NULL_TREE, var_decl_rewrite_info::stmt, TREE_CODE, TREE_OPERAND, TREE_TYPE, TYPE_QUALS, and VAR_P.

Referenced by execute_oacc_device_lower().

◆ oacc_thread_numbers()

static tree oacc_thread_numbers ( bool pos,
int mask,
gimple_seq * seq )
static
Find the number of threads (POS = false), or thread number (POS =
true) for an OpenACC region partitioned as MASK.  Setup code
required for the calculation is added to SEQ.   

References build_int_cst(), fold_build2, integer_type_node, integer_zero_node, NULL_TREE, oacc_dim_call(), and unsigned_type_node.

Referenced by oacc_xform_loop().

◆ oacc_validate_dims()

static void oacc_validate_dims ( tree fn,
tree attrs,
int * dims,
int level,
unsigned used )
static
Validate and update the dimensions for offloaded FN.  ATTRS is the
raw attribute.  DIMS is an array of dimensions, which is filled in.
LEVEL is the partitioning level of a routine, or -1 for an offload
region itself.  USED is the mask of partitioned execution in the
function.   

References build_int_cst(), changed, DECL_ATTRIBUTES, DECL_SOURCE_LOCATION, gcc_assert, integer_type_node, lookup_attribute(), NULL_TREE, oacc_default_dims, oacc_min_dims, oacc_replace_fn_attrib(), targetm, TREE_CHAIN, tree_cons(), TREE_INT_CST_LOW, TREE_PURPOSE, TREE_VALUE, and warning_at().

Referenced by execute_oacc_loop_designation().

◆ oacc_xform_loop()

static void oacc_xform_loop ( gcall * call)
static
Transform IFN_GOACC_LOOP calls to actual code.  See
expand_oacc_for for where these are generated.  At the vector
level, we stride loops, such that each member of a warp will
operate on adjacent iterations.  At the worker and gang level,
each gang/warp executes a set of contiguous iterations.  Chunking
can override this such that each iteration engine executes a
contiguous chunk, and then moves on to stride to the next chunk.   

References build2(), build_int_cst(), cfun, fold_build2, fold_convert, loop::force_vectorize, gcc_unreachable, gimple_call_arg(), gimple_call_lhs(), gimplify_assign(), gsi_bb(), gsi_for_stmt(), gsi_replace_with_seq(), loop::inner, INT_MAX, integer_minus_onep(), integer_onep(), integer_zerop(), basic_block_def::loop_father, NULL, NULL_TREE, oacc_thread_numbers(), offset, OPTION_SET_P, pop_gimplify_context(), push_gimplify_context(), r, loop::safelen, targetm, TREE_INT_CST_LOW, and TREE_TYPE.

Referenced by execute_oacc_device_lower().

◆ oacc_xform_tile()

static void oacc_xform_tile ( gcall * call)
static
Transform a GOACC_TILE call.  Determines the element loop span for
the specified loop of the nest.  This is 1 if we're not tiling.

GOACC_TILE (collapse_count, loop_no, tile_arg, gwv_tile, gwv_element);   

References build_int_cst(), fold_build2, fold_convert, gcc_assert, gimple_call_arg(), gimple_call_lhs(), gimplify_assign(), gsi_for_stmt(), gsi_replace_with_seq(), integer_one_node, integer_zerop(), NULL, NULL_TREE, oacc_dim_call(), pop_gimplify_context(), push_gimplify_context(), seen_error(), tree_to_uhwi(), and TREE_TYPE.

Referenced by execute_oacc_device_lower().

◆ omp_declare_target_fn_p()

static bool omp_declare_target_fn_p ( tree decl)
static
Return true if DECL is a function for which its references should be
analyzed.   

References DECL_ATTRIBUTES, lookup_attribute(), NULL_TREE, oacc_get_fn_attrib(), and TREE_CODE.

Referenced by omp_discover_declare_target_tgt_fn_r(), and omp_discover_implicit_declare_target().

◆ omp_declare_target_var_p()

static bool omp_declare_target_var_p ( tree decl)
static
Return true if DECL Is a variable for which its initializer references
should be analyzed.   

References DECL_ATTRIBUTES, lookup_attribute(), and VAR_P.

Referenced by omp_discover_declare_target_var_r(), and omp_discover_implicit_declare_target().

◆ omp_discover_declare_target_fn_r()

static tree omp_discover_declare_target_fn_r ( tree * tp,
int * walk_subtrees,
void * data )
static

◆ omp_discover_declare_target_tgt_fn_r()

◆ omp_discover_declare_target_var_r()

static tree omp_discover_declare_target_var_r ( tree * tp,
int * walk_subtrees,
void * data )
static

◆ omp_discover_implicit_declare_target()

◆ omp_finish_file()

◆ ompdevlow_adjust_simt_enter()

Variable Documentation

◆ oacc_default_dims

int oacc_default_dims[GOMP_DIM_MAX]
static
Default partitioned and minimum partitioned dimensions.   

Referenced by oacc_get_default_dim(), oacc_parse_default_dims(), and oacc_validate_dims().

◆ oacc_min_dims

int oacc_min_dims[GOMP_DIM_MAX]
static

◆ offload_funcs

◆ offload_ind_funcs

◆ offload_vars