mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-08-30 21:29:28 +00:00
This has been implement using the MCTargetStreamer interface as is done in the ARM, Mips and PPC backends. Phabricator: http://reviews.llvm.org/D5891 PR20964 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@220422 91177308-0d34-0410-b5e6-96231b3b80d8
44 lines
1.5 KiB
C++
44 lines
1.5 KiB
C++
//===- AArch64TargetStreamer.cpp - AArch64TargetStreamer class --*- C++ -*---------===//
|
|
//
|
|
// The LLVM Compiler Infrastructure
|
|
//
|
|
// This file is distributed under the University of Illinois Open Source
|
|
// License. See LICENSE.TXT for details.
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
//
|
|
// This file implements the AArch64TargetStreamer class.
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
#include "llvm/ADT/MapVector.h"
|
|
#include "llvm/MC/ConstantPools.h"
|
|
#include "llvm/MC/MCContext.h"
|
|
#include "llvm/MC/MCExpr.h"
|
|
#include "llvm/MC/MCStreamer.h"
|
|
|
|
using namespace llvm;
|
|
|
|
//
|
|
// AArch64TargetStreamer Implemenation
|
|
//
|
|
AArch64TargetStreamer::AArch64TargetStreamer(MCStreamer &S)
|
|
: MCTargetStreamer(S), ConstantPools(new AssemblerConstantPools()) {}
|
|
|
|
AArch64TargetStreamer::~AArch64TargetStreamer() {}
|
|
|
|
// The constant pool handling is shared by all AArch64TargetStreamer
|
|
// implementations.
|
|
const MCExpr *AArch64TargetStreamer::addConstantPoolEntry(const MCExpr *Expr,
|
|
unsigned Size) {
|
|
return ConstantPools->addEntry(Streamer, Expr, Size);
|
|
}
|
|
|
|
void AArch64TargetStreamer::emitCurrentConstantPool() {
|
|
ConstantPools->emitForCurrentSection(Streamer);
|
|
}
|
|
|
|
// finish() - write out any non-empty assembler constant pools.
|
|
void AArch64TargetStreamer::finish() { ConstantPools->emitAll(Streamer); }
|
|
|
|
void AArch64TargetStreamer::emitInst(uint32_t Inst) {}
|