GCC Newspaper
NOVEMBER 30, 2026
Date
/
Architectures
Components
Topics
News & Policy
Other
vect

Vectorizer uses BITINT_TYPE_P for enumeral types

Vectorizer now correctly handles enumeral types based on _BitInt, improving type compatibility.

The GCC vectorizer has been updated to use BITINT_TYPE_P when checking for BITINT_TYPE in vectorizable_conversion, vectorizable_load, and vectorizable_comparison_1. This ensures that enumeral types with an underlying BITINT_TYPE are correctly processed, avoiding issues with type compatibility.

In Details

The vectorizer's vectorizable_conversion, vectorizable_load, and vectorizable_comparison_1 functions previously used direct TREE_CODE comparisons with BITINT_TYPE. This patch replaces these with BITINT_TYPE_P checks, which also correctly handles ENUMERAL_TYPEs whose underlying type is BITINT_TYPE. This ensures proper vectorization of such types.

For Context
vectorizer
A compiler optimization pass that transforms sequential scalar code into equivalent vector code. It identifies opportunities to perform the same operation on multiple data elements simultaneously using special SIMD (Single Instruction, Multiple Data) instructions.
BITINT_TYPE_P
A GCC internal macro that checks if a given tree node represents a bit-integer type. This is used to identify and handle custom-width integer types.
BITINT_TYPE
The GCC internal tree code representing a custom-width integer type, often used for implementing the C23 _BitInt feature.
ENUMERAL_TYPE
A GCC internal tree code representing an enumerated type, which consists of a set of named integer constants.
TREE_CODE
An enumeration in GCC that classifies nodes in the compiler's internal representation (the 'tree'). Each node represents an expression, statement, type, or other construct.
Filed Under: vectorizationtypescompiler