LLVM  8.0.0svn
Static Public Member Functions | Public Attributes | List of all members
llvm::codeview::LocallyHashedType Struct Reference

A locally hashed type represents a straightforward hash code of a serialized record. More...

#include "llvm/DebugInfo/CodeView/TypeHashing.h"

Collaboration diagram for llvm::codeview::LocallyHashedType:
Collaboration graph
[legend]

Static Public Member Functions

static LocallyHashedType hashType (ArrayRef< uint8_t > RecordData)
 Given a type, compute its local hash. More...
 
template<typename Range >
static std::vector< LocallyHashedTypehashTypes (Range &&Records)
 Given a sequence of types, compute all of the local hashes. More...
 
static std::vector< LocallyHashedTypehashTypeCollection (TypeCollection &Types)
 

Public Attributes

hash_code Hash
 
ArrayRef< uint8_t > RecordData
 

Detailed Description

A locally hashed type represents a straightforward hash code of a serialized record.

The record is simply serialized, and then the bytes are hashed by a standard algorithm. This is sufficient for the case of de-duplicating records within a single sequence of types, because if two records both have a back-reference to the same type in the same stream, they will both have the same numeric value for the TypeIndex of the back reference.

Definition at line 33 of file TypeHashing.h.

Member Function Documentation

◆ hashType()

LocallyHashedType LocallyHashedType::hashType ( ArrayRef< uint8_t >  RecordData)
static

◆ hashTypeCollection()

static std::vector<LocallyHashedType> llvm::codeview::LocallyHashedType::hashTypeCollection ( TypeCollection Types)
inlinestatic

◆ hashTypes()

template<typename Range >
static std::vector<LocallyHashedType> llvm::codeview::LocallyHashedType::hashTypes ( Range &&  Records)
inlinestatic

Given a sequence of types, compute all of the local hashes.

Definition at line 42 of file TypeHashing.h.

References llvm::sys::path::begin(), llvm::sys::path::end(), and hashType().

Member Data Documentation

◆ Hash

hash_code llvm::codeview::LocallyHashedType::Hash

◆ RecordData

ArrayRef<uint8_t> llvm::codeview::LocallyHashedType::RecordData

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