LLVM  mainline
Public Member Functions | Static Public Member Functions | Protected Member Functions | Friends
llvm::ConstantVector Class Reference

ConstantVector - Constant Vector Declarations. More...

#include <Constants.h>

Inheritance diagram for llvm::ConstantVector:
Inheritance graph
[legend]
Collaboration diagram for llvm::ConstantVector:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 DECLARE_TRANSPARENT_OPERAND_ACCESSORS (Constant)
 Transparently provide more efficient getOperand methods.
VectorTypegetType () const
 getType - Specialize the getType() method to always return a VectorType, which reduces the amount of casting needed in parts of the compiler.
ConstantgetSplatValue () const
 getSplatValue - If this is a splat constant, meaning that all of the elements have the same value, return that value.

Static Public Member Functions

static Constantget (ArrayRef< Constant * > V)
static ConstantgetSplat (unsigned NumElts, Constant *Elt)
 getSplat - Return a ConstantVector with the specified constant in each element.
static bool classof (const Value *V)
 Methods for support type inquiry through isa, cast, and dyn_cast:

Protected Member Functions

 ConstantVector (VectorType *T, ArrayRef< Constant * > Val)

Friends

struct ConstantAggrKeyType< ConstantVector >
class Constant

Detailed Description

ConstantVector - Constant Vector Declarations.

Definition at line 461 of file Constants.h.


Constructor & Destructor Documentation

ConstantVector::ConstantVector ( VectorType T,
ArrayRef< Constant * >  Val 
) [protected]

Member Function Documentation

static bool llvm::ConstantVector::classof ( const Value V) [inline, static]

Methods for support type inquiry through isa, cast, and dyn_cast:

Reimplemented from llvm::Constant.

Definition at line 498 of file Constants.h.

References llvm::Value::getValueID().

Transparently provide more efficient getOperand methods.

Constant * ConstantVector::getSplat ( unsigned  NumElts,
Constant Elt 
) [static]

getSplatValue - If this is a splat constant, meaning that all of the elements have the same value, return that value.

getSplatValue - If this is a splat constant, where all of the elements have the same value, return that value.

Otherwise return NULL.

Otherwise return null.

Reimplemented from llvm::Constant.

Definition at line 1366 of file Constants.cpp.

References E, llvm::User::getNumOperands(), llvm::User::getOperand(), and I.

getType - Specialize the getType() method to always return a VectorType, which reduces the amount of casting needed in parts of the compiler.

Reimplemented from llvm::Value.

Definition at line 489 of file Constants.h.

References llvm::Value::getType().

Referenced by ConstantVector(), and emitGlobalConstantVector().


Friends And Related Function Documentation

friend class Constant [friend]

Definition at line 465 of file Constants.h.

friend struct ConstantAggrKeyType< ConstantVector > [friend]

Definition at line 462 of file Constants.h.


The documentation for this class was generated from the following files: