LLVM  6.0.0svn
DebugSymbolRVASubsection.cpp
Go to the documentation of this file.
1 //===- DebugSymbolRVASubsection.cpp ---------------------------------------===//
2 //
3 // The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 
11 #include "llvm/ADT/ArrayRef.h"
15 #include <cstdint>
16 
17 using namespace llvm;
18 using namespace llvm::codeview;
19 
22 
24  return Reader.readArray(RVAs, Reader.bytesRemaining() / sizeof(uint32_t));
25 }
26 
29 
31  return Writer.writeArray(makeArrayRef(RVAs));
32 }
33 
35  return RVAs.size() * sizeof(uint32_t);
36 }
Compute iterated dominance frontiers using a linear time algorithm.
Definition: AllocatorList.h:24
ArrayRef< T > makeArrayRef(const T &OneElt)
Construct an ArrayRef from a single element.
Definition: ArrayRef.h:451
Error writeArray(ArrayRef< T > Array)
Writes an array of objects of type T to the underlying stream, as if by using memcpy.
Provides write only access to a subclass of WritableBinaryStream.
uint32_t bytesRemaining() const
Lightweight error class with error context and mandatory checking.
Definition: Error.h:156
Error commit(BinaryStreamWriter &Writer) const override
Provides read only access to a subclass of BinaryStream.
Error readArray(ArrayRef< T > &Array, uint32_t NumElements)
Get a reference to a NumElements element array of objects of type T from the underlying stream as if ...