1 //===-- ARMWinCOFFStreamer.cpp - ARM Target WinCOFF Streamer ----*- 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 #include "ARMMCTargetDesc.h" 11 #include "llvm/MC/MCWinCOFFStreamer.h" 12 13 using namespace llvm; 14 15 namespace { 16 class ARMWinCOFFStreamer : public MCWinCOFFStreamer { 17 public: 18 ARMWinCOFFStreamer(MCContext &C, MCAsmBackend &AB, MCCodeEmitter &CE, 19 raw_ostream &OS) 20 : MCWinCOFFStreamer(C, AB, CE, OS) { } 21 22 void EmitAssemblerFlag(MCAssemblerFlag Flag) override; 23 void EmitThumbFunc(MCSymbol *Symbol) override; 24 }; 25 26 void ARMWinCOFFStreamer::EmitAssemblerFlag(MCAssemblerFlag Flag) { 27 switch (Flag) { 28 default: llvm_unreachable("not implemented"); 29 case MCAF_SyntaxUnified: 30 case MCAF_Code16: 31 break; 32 } 33 } 34 35 void ARMWinCOFFStreamer::EmitThumbFunc(MCSymbol *Symbol) { 36 getAssembler().setIsThumbFunc(Symbol); 37 } 38 } 39 40 namespace llvm { 41 MCStreamer *createARMWinCOFFStreamer(MCContext &Context, MCAsmBackend &MAB, 42 MCCodeEmitter &Emitter, raw_ostream &OS) { 43 return new ARMWinCOFFStreamer(Context, MAB, Emitter, OS); 44 } 45 } 46 47