llvm-project/llvm/lib/Target/SystemZ/MCTargetDesc/SystemZGOFFObjectWriter.cpp
Kai Nacke 3adc2a0b84
[SystemZ/zOS/GOFF] Implement GOFF writer for empty files.
Set ups the infrastructure to create an empty GOFF file.
Also adds a GOFF writer which writes only HDR/END records.

Reviewed By: jhenderson, kpn

Differential Revision: https://reviews.llvm.org/D111437
2023-09-29 19:27:11 +00:00

27 lines
850 B
C++

//===- SystemZGOFFObjectWriter.cpp - SystemZ GOFF writer ------------------===//
//
// 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 "MCTargetDesc/SystemZMCTargetDesc.h"
#include "llvm/MC/MCGOFFObjectWriter.h"
using namespace llvm;
namespace {
class SystemZGOFFObjectWriter : public MCGOFFObjectTargetWriter {
public:
SystemZGOFFObjectWriter();
};
} // end anonymous namespace
SystemZGOFFObjectWriter::SystemZGOFFObjectWriter()
: MCGOFFObjectTargetWriter() {}
std::unique_ptr<MCObjectTargetWriter> llvm::createSystemZGOFFObjectWriter() {
return std::make_unique<SystemZGOFFObjectWriter>();
}