GCC Middle and Back End API Reference
vec-perm-indices.h File Reference
Include dependency graph for vec-perm-indices.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

class  vec_perm_indices

Typedefs

typedef int_vector_builder< poly_int64vec_perm_builder

Functions

bool tree_to_vec_perm_builder (vec_perm_builder *, tree)
tree vec_perm_indices_to_tree (tree, const vec_perm_indices &)
rtx vec_perm_indices_to_rtx (machine_mode, const vec_perm_indices &)

Typedef Documentation

◆ vec_perm_builder

A representation of vector permutation indices. Copyright (C) 2017-2025 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/>.
A vector_builder for building constant permutation vectors. The elements do not need to be clamped to a particular range of input elements.

Function Documentation

◆ tree_to_vec_perm_builder()

bool tree_to_vec_perm_builder ( vec_perm_builder * builder,
tree cst )
Try to read the contents of VECTOR_CST CST as a constant permutation vector. Return true and add the elements to BUILDER on success, otherwise return false without modifying BUILDER.

References i, int_vector_builder< T >::new_vector(), tree_fits_poly_int64_p(), tree_to_poly_int64(), TREE_TYPE, TYPE_VECTOR_SUBPARTS(), VECTOR_CST_ENCODED_ELT, vector_cst_encoded_nelts(), VECTOR_CST_NELTS_PER_PATTERN, and VECTOR_CST_NPATTERNS.

Referenced by expand_expr_real_2(), fold_ternary_loc(), is_combined_permutation_identity(), lower_vec_perm(), and simplify_permutation().

◆ vec_perm_indices_to_rtx()

rtx vec_perm_indices_to_rtx ( machine_mode mode,
const vec_perm_indices & indices )
Return a CONST_VECTOR of mode MODE that contains the elements of INDICES.

References rtx_vector_builder::build(), vector_builder< T, Shape, Derived >::encoded_nelts(), gcc_assert, gen_int_mode(), GET_MODE_CLASS, GET_MODE_INNER, GET_MODE_NUNITS(), i, and known_eq.

Referenced by expand_vec_perm_const().

◆ vec_perm_indices_to_tree()

tree vec_perm_indices_to_tree ( tree type,
const vec_perm_indices & indices )