blob: d5ba59998de4bf7a09dccb6ffc1d7110208b6b28 [file] [log] [blame]
David Srbecky766e74f2018-10-02 17:12:24 +01001/*
2 * Copyright (C) 2018 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#if ASM_DEFINE_INCLUDE_DEPENDENCIES
18#include "art_method.h"
Nicolas Geoffrayd5a86952021-01-19 10:35:54 +000019#include "imtable.h"
David Srbecky766e74f2018-10-02 17:12:24 +010020#endif
21
22ASM_DEFINE(ART_METHOD_ACCESS_FLAGS_OFFSET,
23 art::ArtMethod::AccessFlagsOffset().Int32Value())
Nicolas Geoffrayf9ae8e32022-02-15 22:54:11 +000024ASM_DEFINE(ART_METHOD_IS_MEMORY_SHARED_FLAG,
25 art::kAccMemorySharedMethod)
26ASM_DEFINE(ART_METHOD_IS_MEMORY_SHARED_FLAG_BIT,
27 art::MostSignificantBit(art::kAccMemorySharedMethod))
Nicolas Geoffraya00b54b2019-12-03 14:36:42 +000028ASM_DEFINE(ART_METHOD_IS_STATIC_FLAG,
29 art::kAccStatic)
Nicolas Geoffraye5859642021-01-08 18:09:36 +000030ASM_DEFINE(ART_METHOD_IS_STATIC_FLAG_BIT,
31 art::MostSignificantBit(art::kAccStatic))
Nicolas Geoffray43c9cd72021-03-10 15:09:19 +000032ASM_DEFINE(ART_METHOD_NTERP_INVOKE_FAST_PATH_FLAG,
33 art::kAccNterpInvokeFastPathFlag)
34ASM_DEFINE(ART_METHOD_NTERP_INVOKE_FAST_PATH_FLAG_BIT,
35 art::MostSignificantBit(art::kAccNterpInvokeFastPathFlag))
36ASM_DEFINE(ART_METHOD_NTERP_ENTRY_POINT_FAST_PATH_FLAG,
37 art::kAccNterpEntryPointFastPathFlag)
Nicolas Geoffray40cd07c2021-03-15 18:33:23 +000038ASM_DEFINE(ART_METHOD_NTERP_ENTRY_POINT_FAST_PATH_FLAG_BIT,
39 art::MostSignificantBit(art::kAccNterpEntryPointFastPathFlag))
Nicolas Geoffray43c9cd72021-03-10 15:09:19 +000040ASM_DEFINE(ART_METHOD_IMT_MASK,
41 art::ImTable::kSizeTruncToPowerOfTwo - 1)
David Srbecky766e74f2018-10-02 17:12:24 +010042ASM_DEFINE(ART_METHOD_DECLARING_CLASS_OFFSET,
43 art::ArtMethod::DeclaringClassOffset().Int32Value())
44ASM_DEFINE(ART_METHOD_JNI_OFFSET_32,
45 art::ArtMethod::EntryPointFromJniOffset(art::PointerSize::k32).Int32Value())
46ASM_DEFINE(ART_METHOD_JNI_OFFSET_64,
47 art::ArtMethod::EntryPointFromJniOffset(art::PointerSize::k64).Int32Value())
Nicolas Geoffray47171752020-08-31 15:03:20 +010048ASM_DEFINE(ART_METHOD_DATA_OFFSET_32,
49 art::ArtMethod::DataOffset(art::PointerSize::k32).Int32Value())
50ASM_DEFINE(ART_METHOD_DATA_OFFSET_64,
51 art::ArtMethod::DataOffset(art::PointerSize::k64).Int32Value())
David Srbecky766e74f2018-10-02 17:12:24 +010052ASM_DEFINE(ART_METHOD_QUICK_CODE_OFFSET_32,
53 art::ArtMethod::EntryPointFromQuickCompiledCodeOffset(art::PointerSize::k32).Int32Value())
54ASM_DEFINE(ART_METHOD_QUICK_CODE_OFFSET_64,
55 art::ArtMethod::EntryPointFromQuickCompiledCodeOffset(art::PointerSize::k64).Int32Value())
Nicolas Geoffraya00b54b2019-12-03 14:36:42 +000056ASM_DEFINE(ART_METHOD_METHOD_INDEX_OFFSET,
57 art::ArtMethod::MethodIndexOffset().Int32Value())
58ASM_DEFINE(ART_METHOD_IMT_INDEX_OFFSET,
59 art::ArtMethod::ImtIndexOffset().Int32Value())
60ASM_DEFINE(ART_METHOD_HOTNESS_COUNT_OFFSET,
61 art::ArtMethod::HotnessCountOffset().Int32Value())