~louis/ubuntu/trusty/clamav/lp799623_fix_logrotate

« back to all changes in this revision

Viewing changes to libclamav/c++/llvm/lib/Target/ARM/ARMCallingConv.td

  • Committer: Bazaar Package Importer
  • Author(s): Scott Kitterman
  • Date: 2010-03-12 11:30:04 UTC
  • mfrom: (0.41.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20100312113004-b0fop4bkycszdd0z
Tags: 0.96~rc1+dfsg-0ubuntu1
* New upstream RC - FFE (LP: #537636):
  - Add OfficialDatabaseOnly option to clamav-base.postinst.in
  - Add LocalSocketGroup option to clamav-base.postinst.in
  - Add LocalSocketMode option to clamav-base.postinst.in
  - Add CrossFilesystems option to clamav-base.postinst.in
  - Add ClamukoScannerCount option to clamav-base.postinst.in
  - Add BytecodeSecurity opiton to clamav-base.postinst.in
  - Add DetectionStatsHostID option to clamav-freshclam.postinst.in
  - Add Bytecode option to clamav-freshclam.postinst.in
  - Add MilterSocketGroup option to clamav-milter.postinst.in
  - Add MilterSocketMode option to clamav-milter.postinst.in
  - Add ReportHostname option to clamav-milter.postinst.in
  - Bump libclamav SO version to 6.1.0 in libclamav6.install
  - Drop clamdmon from clamav.examples (no longer shipped by upstream)
  - Drop libclamav.a from libclamav-dev.install (not built by upstream)
  - Update SO version for lintian override for libclamav6
  - Add new Bytecode Testing Tool, usr/bin/clambc, to clamav.install
  - Add build-depends on python and python-setuptools for new test suite
  - Update debian/copyright for the embedded copy of llvm (using the system
    llvm is not currently feasible)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
//===- ARMCallingConv.td - Calling Conventions for ARM ----------*- 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
// This describes the calling conventions for ARM architecture.
 
10
//===----------------------------------------------------------------------===//
 
11
 
 
12
/// CCIfSubtarget - Match if the current subtarget has a feature F.
 
13
class CCIfSubtarget<string F, CCAction A>:
 
14
  CCIf<!strconcat("State.getTarget().getSubtarget<ARMSubtarget>().", F), A>;
 
15
 
 
16
/// CCIfAlign - Match of the original alignment of the arg
 
17
class CCIfAlign<string Align, CCAction A>:
 
18
  CCIf<!strconcat("ArgFlags.getOrigAlign() == ", Align), A>;
 
19
 
 
20
//===----------------------------------------------------------------------===//
 
21
// ARM APCS Calling Convention
 
22
//===----------------------------------------------------------------------===//
 
23
def CC_ARM_APCS : CallingConv<[
 
24
 
 
25
  CCIfType<[i8, i16], CCPromoteToType<i32>>,
 
26
 
 
27
  // Handle all vector types as either f64 or v2f64.
 
28
  CCIfType<[v1i64, v2i32, v4i16, v8i8, v2f32], CCBitConvertToType<f64>>,
 
29
  CCIfType<[v2i64, v4i32, v8i16, v16i8, v4f32], CCBitConvertToType<v2f64>>,
 
30
 
 
31
  // f64 and v2f64 are passed in adjacent GPRs, possibly split onto the stack
 
32
  CCIfType<[f64, v2f64], CCCustom<"CC_ARM_APCS_Custom_f64">>,
 
33
 
 
34
  CCIfType<[f32], CCBitConvertToType<i32>>,
 
35
  CCIfType<[i32], CCAssignToReg<[R0, R1, R2, R3]>>,
 
36
 
 
37
  CCIfType<[i32], CCAssignToStack<4, 4>>,
 
38
  CCIfType<[f64], CCAssignToStack<8, 4>>,
 
39
  CCIfType<[v2f64], CCAssignToStack<16, 4>>
 
40
]>;
 
41
 
 
42
def RetCC_ARM_APCS : CallingConv<[
 
43
  CCIfType<[f32], CCBitConvertToType<i32>>,
 
44
 
 
45
  // Handle all vector types as either f64 or v2f64.
 
46
  CCIfType<[v1i64, v2i32, v4i16, v8i8, v2f32], CCBitConvertToType<f64>>,
 
47
  CCIfType<[v2i64, v4i32, v8i16, v16i8, v4f32], CCBitConvertToType<v2f64>>,
 
48
 
 
49
  CCIfType<[f64, v2f64], CCCustom<"RetCC_ARM_APCS_Custom_f64">>,
 
50
 
 
51
  CCIfType<[i32], CCAssignToReg<[R0, R1, R2, R3]>>,
 
52
  CCIfType<[i64], CCAssignToRegWithShadow<[R0, R2], [R1, R3]>>
 
53
]>;
 
54
 
 
55
//===----------------------------------------------------------------------===//
 
56
// ARM AAPCS (EABI) Calling Convention, common parts
 
57
//===----------------------------------------------------------------------===//
 
58
 
 
59
def CC_ARM_AAPCS_Common : CallingConv<[
 
60
 
 
61
  CCIfType<[i8, i16], CCPromoteToType<i32>>,
 
62
 
 
63
  // i64/f64 is passed in even pairs of GPRs
 
64
  // i64 is 8-aligned i32 here, so we may need to eat R1 as a pad register
 
65
  // (and the same is true for f64 if VFP is not enabled)
 
66
  CCIfType<[i32], CCIfAlign<"8", CCAssignToRegWithShadow<[R0, R2], [R0, R1]>>>,
 
67
  CCIfType<[i32], CCIf<"State.getNextStackOffset() == 0 &&"
 
68
                       "ArgFlags.getOrigAlign() != 8",
 
69
                       CCAssignToReg<[R0, R1, R2, R3]>>>,
 
70
 
 
71
  CCIfType<[i32], CCIfAlign<"8", CCAssignToStack<4, 8>>>,
 
72
  CCIfType<[i32, f32], CCAssignToStack<4, 4>>,
 
73
  CCIfType<[f64], CCAssignToStack<8, 8>>,
 
74
  CCIfType<[v2f64], CCAssignToStack<16, 8>>
 
75
]>;
 
76
 
 
77
def RetCC_ARM_AAPCS_Common : CallingConv<[
 
78
  CCIfType<[i32], CCAssignToReg<[R0, R1, R2, R3]>>,
 
79
  CCIfType<[i64], CCAssignToRegWithShadow<[R0, R2], [R1, R3]>>
 
80
]>;
 
81
 
 
82
//===----------------------------------------------------------------------===//
 
83
// ARM AAPCS (EABI) Calling Convention
 
84
//===----------------------------------------------------------------------===//
 
85
 
 
86
def CC_ARM_AAPCS : CallingConv<[
 
87
  // Handle all vector types as either f64 or v2f64.
 
88
  CCIfType<[v1i64, v2i32, v4i16, v8i8, v2f32], CCBitConvertToType<f64>>,
 
89
  CCIfType<[v2i64, v4i32, v8i16, v16i8, v4f32], CCBitConvertToType<v2f64>>,
 
90
 
 
91
  CCIfType<[f64, v2f64], CCCustom<"CC_ARM_AAPCS_Custom_f64">>,
 
92
  CCIfType<[f32], CCBitConvertToType<i32>>,
 
93
  CCDelegateTo<CC_ARM_AAPCS_Common>
 
94
]>;
 
95
 
 
96
def RetCC_ARM_AAPCS : CallingConv<[
 
97
  // Handle all vector types as either f64 or v2f64.
 
98
  CCIfType<[v1i64, v2i32, v4i16, v8i8, v2f32], CCBitConvertToType<f64>>,
 
99
  CCIfType<[v2i64, v4i32, v8i16, v16i8, v4f32], CCBitConvertToType<v2f64>>,
 
100
 
 
101
  CCIfType<[f64, v2f64], CCCustom<"RetCC_ARM_AAPCS_Custom_f64">>,
 
102
  CCIfType<[f32], CCBitConvertToType<i32>>,
 
103
  CCDelegateTo<RetCC_ARM_AAPCS_Common>
 
104
]>;
 
105
 
 
106
//===----------------------------------------------------------------------===//
 
107
// ARM AAPCS-VFP (EABI) Calling Convention
 
108
//===----------------------------------------------------------------------===//
 
109
 
 
110
def CC_ARM_AAPCS_VFP : CallingConv<[
 
111
  // Handle all vector types as either f64 or v2f64.
 
112
  CCIfType<[v1i64, v2i32, v4i16, v8i8, v2f32], CCBitConvertToType<f64>>,
 
113
  CCIfType<[v2i64, v4i32, v8i16, v16i8, v4f32], CCBitConvertToType<v2f64>>,
 
114
 
 
115
  CCIfType<[v2f64], CCAssignToReg<[Q0, Q1, Q2, Q3]>>,
 
116
  CCIfType<[f64], CCAssignToReg<[D0, D1, D2, D3, D4, D5, D6, D7]>>,
 
117
  CCIfType<[f32], CCAssignToReg<[S0, S1, S2, S3, S4, S5, S6, S7, S8,
 
118
                                 S9, S10, S11, S12, S13, S14, S15]>>,
 
119
  CCDelegateTo<CC_ARM_AAPCS_Common>
 
120
]>;
 
121
 
 
122
def RetCC_ARM_AAPCS_VFP : CallingConv<[
 
123
  // Handle all vector types as either f64 or v2f64.
 
124
  CCIfType<[v1i64, v2i32, v4i16, v8i8, v2f32], CCBitConvertToType<f64>>,
 
125
  CCIfType<[v2i64, v4i32, v8i16, v16i8, v4f32], CCBitConvertToType<v2f64>>,
 
126
 
 
127
  CCIfType<[v2f64], CCAssignToReg<[Q0, Q1, Q2, Q3]>>,
 
128
  CCIfType<[f64], CCAssignToReg<[D0, D1, D2, D3, D4, D5, D6, D7]>>,
 
129
  CCIfType<[f32], CCAssignToReg<[S0, S1, S2, S3, S4, S5, S6, S7, S8,
 
130
                                 S9, S10, S11, S12, S13, S14, S15]>>,
 
131
  CCDelegateTo<RetCC_ARM_AAPCS_Common>
 
132
]>;