Scott Michel | 564427e | 2007-12-05 01:24:05 +0000 | [diff] [blame] | 1 | //===-- SPUTargetAsmInfo.cpp - Cell SPU asm properties ----------*- C++ -*-===// |
| 2 | // |
| 3 | // The LLVM Compiler Infrastructure |
| 4 | // |
Chris Lattner | 4ee451d | 2007-12-29 20:36:04 +0000 | [diff] [blame] | 5 | // This file is distributed under the University of Illinois Open Source |
| 6 | // License. See LICENSE.TXT for details. |
Scott Michel | 564427e | 2007-12-05 01:24:05 +0000 | [diff] [blame] | 7 | // |
| 8 | //===----------------------------------------------------------------------===// |
| 9 | // |
| 10 | // This file contains the declarations of the SPUTargetAsmInfo properties. |
| 11 | // |
| 12 | //===----------------------------------------------------------------------===// |
| 13 | |
| 14 | #include "SPUTargetAsmInfo.h" |
| 15 | #include "SPUTargetMachine.h" |
| 16 | #include "llvm/Function.h" |
Scott Michel | d03eeaf | 2008-11-07 04:36:25 +0000 | [diff] [blame^] | 17 | #include "llvm/Support/Compiler.h" |
| 18 | |
Scott Michel | 564427e | 2007-12-05 01:24:05 +0000 | [diff] [blame] | 19 | using namespace llvm; |
| 20 | |
Scott Michel | d03eeaf | 2008-11-07 04:36:25 +0000 | [diff] [blame^] | 21 | SPULinuxTargetAsmInfo::SPULinuxTargetAsmInfo(const SPUTargetMachine &TM) : |
| 22 | SPUTargetAsmInfo<ELFTargetAsmInfo>(TM) { |
Scott Michel | 053c1da | 2008-01-29 02:16:57 +0000 | [diff] [blame] | 23 | PCSymbol = "."; |
Scott Michel | 564427e | 2007-12-05 01:24:05 +0000 | [diff] [blame] | 24 | CommentString = "#"; |
| 25 | GlobalPrefix = ""; |
| 26 | PrivateGlobalPrefix = ".L"; |
Scott Michel | 564427e | 2007-12-05 01:24:05 +0000 | [diff] [blame] | 27 | } |
Scott Michel | d03eeaf | 2008-11-07 04:36:25 +0000 | [diff] [blame^] | 28 | |
| 29 | /// PreferredEHDataFormat - This hook allows the target to select data |
| 30 | /// format used for encoding pointers in exception handling data. Reason is |
| 31 | /// 0 for data, 1 for code labels, 2 for function pointers. Global is true |
| 32 | /// if the symbol can be relocated. |
| 33 | unsigned |
| 34 | SPULinuxTargetAsmInfo::PreferredEHDataFormat(DwarfEncoding::Target Reason, |
| 35 | bool Global) const { |
| 36 | // We really need to write something here. |
| 37 | return TargetAsmInfo::PreferredEHDataFormat(Reason, Global); |
| 38 | } |
| 39 | |
| 40 | // Instantiate default implementation. |
| 41 | TEMPLATE_INSTANTIATION(class SPUTargetAsmInfo<TargetAsmInfo>); |