blob: cf713962eb7fa059fefe9a04d8bc40742a84d0d3 [file] [log] [blame]
Reid Kleckner72e2ba72016-01-13 19:32:35 +00001//===-- CodeView.h - On-disk record types for CodeView ----------*- C++ -*-===//
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///
10/// \file
11/// \brief This file provides data structures useful for consuming on-disk
12/// CodeView. It is based on information published by Microsoft at
13/// https://github.com/Microsoft/microsoft-pdb/.
14///
15//===----------------------------------------------------------------------===//
16
17// FIXME: Find a home for this in include/llvm/DebugInfo/CodeView/.
18
19#ifndef LLVM_READOBJ_CODEVIEW_H
20#define LLVM_READOBJ_CODEVIEW_H
21
22#include "llvm/DebugInfo/CodeView/CodeView.h"
23#include "llvm/DebugInfo/CodeView/TypeIndex.h"
24#include "llvm/Support/Endian.h"
25
26namespace llvm {
27namespace codeview {
28
Reid Kleckner6b3faef2016-01-13 23:44:57 +000029using llvm::support::ulittle16_t;
30using llvm::support::ulittle32_t;
Reid Kleckner72e2ba72016-01-13 19:32:35 +000031
32/// Data in the the SUBSEC_FRAMEDATA subection.
33struct FrameData {
34 ulittle32_t RvaStart;
35 ulittle32_t CodeSize;
36 ulittle32_t LocalSize;
37 ulittle32_t ParamsSize;
38 ulittle32_t MaxStackSize;
39 ulittle32_t FrameFunc;
40 ulittle16_t PrologSize;
41 ulittle16_t SavedRegsSize;
42 ulittle32_t Flags;
43 enum : uint32_t {
44 HasSEH = 1 << 0,
45 HasEH = 1 << 1,
46 IsFunctionStart = 1 << 2,
47 };
48};
49
Reid Kleckner72e2ba72016-01-13 19:32:35 +000050
51} // namespace codeview
52} // namespace llvm
53
54#endif // LLVM_READOBJ_CODEVIEW_H