blob: 7b80af64772b2c03846bf81f40fbdeed53b34dfb [file] [log] [blame]
Serban Constantinescuda8ffec2016-03-09 12:02:11 +00001/*
2 * Copyright (C) 2016 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17#include "quick_entrypoints_enum.h"
18
19namespace art {
20
21bool EntrypointRequiresStackMap(QuickEntrypointEnum trampoline) {
22 // Entrypoints that do not require a stackmap. In general leaf methods
23 // outside of the VM that are not safepoints.
24 switch (trampoline) {
25 // Listed in the same order as in quick_entrypoints_list.h.
26 case kQuickCmpgDouble:
27 case kQuickCmpgFloat:
28 case kQuickCmplDouble:
29 case kQuickCmplFloat:
30 case kQuickCos:
31 case kQuickSin:
32 case kQuickAcos:
33 case kQuickAsin:
34 case kQuickAtan:
35 case kQuickAtan2:
36 case kQuickCbrt:
37 case kQuickCosh:
38 case kQuickExp:
39 case kQuickExpm1:
40 case kQuickHypot:
41 case kQuickLog:
42 case kQuickLog10:
43 case kQuickNextAfter:
44 case kQuickSinh:
45 case kQuickTan:
46 case kQuickTanh:
47 case kQuickFmod:
48 case kQuickL2d:
49 case kQuickFmodf:
50 case kQuickL2f:
51 case kQuickD2iz:
52 case kQuickF2iz:
53 case kQuickIdivmod:
54 case kQuickD2l:
55 case kQuickF2l:
56 case kQuickLdiv:
57 case kQuickLmod:
58 case kQuickLmul:
59 case kQuickShlLong:
60 case kQuickShrLong:
61 case kQuickUshrLong:
62 return false;
63
Serban Constantinescufca16662016-07-14 09:21:59 +010064 /* Used by mips for 64bit volatile load/stores. */
65 case kQuickA64Load:
66 case kQuickA64Store:
67 return false;
68
Serban Constantinescuda8ffec2016-03-09 12:02:11 +000069 default:
70 return true;
71 }
72}
73
74} // namespace art