summaryrefslogtreecommitdiffstats
path: root/contrib/libs/llvm12/lib/DebugInfo/CodeView/DebugCrossExSubsection.cpp
diff options
context:
space:
mode:
authorrobot-ydb-importer <[email protected]>2024-02-01 17:04:24 +0300
committerAlexander Smirnov <[email protected]>2024-02-09 19:16:57 +0300
commit92eec2d2cadb061e8d0736fc1e6006255d1db6aa (patch)
tree374efcbf55311667e4f87ee2790bf71ac6756ae4 /contrib/libs/llvm12/lib/DebugInfo/CodeView/DebugCrossExSubsection.cpp
parentb34656eaa432fe5258085ca4e4642774fe082456 (diff)
YDB Import 559
Diffstat (limited to 'contrib/libs/llvm12/lib/DebugInfo/CodeView/DebugCrossExSubsection.cpp')
-rw-r--r--contrib/libs/llvm12/lib/DebugInfo/CodeView/DebugCrossExSubsection.cpp52
1 files changed, 0 insertions, 52 deletions
diff --git a/contrib/libs/llvm12/lib/DebugInfo/CodeView/DebugCrossExSubsection.cpp b/contrib/libs/llvm12/lib/DebugInfo/CodeView/DebugCrossExSubsection.cpp
deleted file mode 100644
index b23410409f8..00000000000
--- a/contrib/libs/llvm12/lib/DebugInfo/CodeView/DebugCrossExSubsection.cpp
+++ /dev/null
@@ -1,52 +0,0 @@
-//===- DebugCrossExSubsection.cpp -----------------------------------------===//
-//
-// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
-// See https://llvm.org/LICENSE.txt for license information.
-// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
-//
-//===----------------------------------------------------------------------===//
-
-#include "llvm/DebugInfo/CodeView/DebugCrossExSubsection.h"
-#include "llvm/DebugInfo/CodeView/CodeViewError.h"
-#include "llvm/Support/BinaryStreamWriter.h"
-#include "llvm/Support/Error.h"
-#include <cstdint>
-
-using namespace llvm;
-using namespace llvm::codeview;
-
-Error DebugCrossModuleExportsSubsectionRef::initialize(
- BinaryStreamReader Reader) {
- if (Reader.bytesRemaining() % sizeof(CrossModuleExport) != 0)
- return make_error<CodeViewError>(
- cv_error_code::corrupt_record,
- "Cross Scope Exports section is an invalid size!");
-
- uint32_t Size = Reader.bytesRemaining() / sizeof(CrossModuleExport);
- return Reader.readArray(References, Size);
-}
-
-Error DebugCrossModuleExportsSubsectionRef::initialize(BinaryStreamRef Stream) {
- BinaryStreamReader Reader(Stream);
- return initialize(Reader);
-}
-
-void DebugCrossModuleExportsSubsection::addMapping(uint32_t Local,
- uint32_t Global) {
- Mappings[Local] = Global;
-}
-
-uint32_t DebugCrossModuleExportsSubsection::calculateSerializedSize() const {
- return Mappings.size() * sizeof(CrossModuleExport);
-}
-
-Error DebugCrossModuleExportsSubsection::commit(
- BinaryStreamWriter &Writer) const {
- for (const auto &M : Mappings) {
- if (auto EC = Writer.writeInteger(M.first))
- return EC;
- if (auto EC = Writer.writeInteger(M.second))
- return EC;
- }
- return Error::success();
-}