/art/compiler/linker/ |
D | linker_patch_test.cc | 24 TEST(LinkerPatch, LinkerPatchOperators) { in TEST() argument 27 LinkerPatch patches[] = { in TEST() 28 LinkerPatch::IntrinsicReferencePatch(16u, 3000u, 1000u), in TEST() 29 LinkerPatch::IntrinsicReferencePatch(16u, 3001u, 1000u), in TEST() 30 LinkerPatch::IntrinsicReferencePatch(16u, 3000u, 1001u), in TEST() 31 LinkerPatch::IntrinsicReferencePatch(16u, 3001u, 1001u), in TEST() 32 LinkerPatch::RelativeMethodPatch(16u, dex_file1, 3000u, 1000u), in TEST() 33 LinkerPatch::RelativeMethodPatch(16u, dex_file1, 3001u, 1000u), in TEST() 34 LinkerPatch::RelativeMethodPatch(16u, dex_file1, 3000u, 1001u), in TEST() 35 LinkerPatch::RelativeMethodPatch(16u, dex_file1, 3001u, 1001u), // Index 7. in TEST() [all …]
|
D | linker_patch.h | 34 class LinkerPatch { 59 static LinkerPatch IntrinsicReferencePatch(size_t literal_offset, in IntrinsicReferencePatch() 62 LinkerPatch patch(literal_offset, Type::kIntrinsicReference, /* target_dex_file= */ nullptr); in IntrinsicReferencePatch() 68 static LinkerPatch DataBimgRelRoPatch(size_t literal_offset, in DataBimgRelRoPatch() 71 LinkerPatch patch(literal_offset, Type::kDataBimgRelRo, /* target_dex_file= */ nullptr); in DataBimgRelRoPatch() 77 static LinkerPatch RelativeMethodPatch(size_t literal_offset, in RelativeMethodPatch() 81 LinkerPatch patch(literal_offset, Type::kMethodRelative, target_dex_file); in RelativeMethodPatch() 87 static LinkerPatch MethodBssEntryPatch(size_t literal_offset, in MethodBssEntryPatch() 91 LinkerPatch patch(literal_offset, Type::kMethodBssEntry, target_dex_file); in MethodBssEntryPatch() 97 static LinkerPatch RelativeCodePatch(size_t literal_offset, in RelativeCodePatch() [all …]
|
/art/dex2oat/linker/x86_64/ |
D | relative_patcher_x86_64_test.cc | 66 LinkerPatch patches[] = { in TEST_F() 67 LinkerPatch::RelativeCodePatch(kCallCode.size() - 4u, nullptr, 1u), in TEST_F() 69 AddCompiledMethod(MethodRef(1u), kCallCode, ArrayRef<const LinkerPatch>(patches)); in TEST_F() 79 LinkerPatch method1_patches[] = { in TEST_F() 80 LinkerPatch::RelativeCodePatch(kCallCode.size() - 4u, nullptr, 2u), in TEST_F() 82 AddCompiledMethod(MethodRef(1u), kCallCode, ArrayRef<const LinkerPatch>(method1_patches)); in TEST_F() 83 LinkerPatch method2_patches[] = { in TEST_F() 84 LinkerPatch::RelativeCodePatch(kCallCode.size() - 4u, nullptr, 1u), in TEST_F() 86 AddCompiledMethod(MethodRef(2u), kCallCode, ArrayRef<const LinkerPatch>(method2_patches)); in TEST_F() 112 LinkerPatch patches[] = { in TEST_F() [all …]
|
D | relative_patcher_x86_64.h | 30 const LinkerPatch& patch, 34 const LinkerPatch& patch, 37 const LinkerPatch& patch,
|
D | relative_patcher_x86_64.cc | 26 const LinkerPatch& patch, in PatchPcRelativeReference() 39 const LinkerPatch& patch ATTRIBUTE_UNUSED, in PatchEntrypointCall() 45 const LinkerPatch& patch ATTRIBUTE_UNUSED, in PatchBakerReadBarrierBranch()
|
/art/dex2oat/linker/x86/ |
D | relative_patcher_x86_test.cc | 46 LinkerPatch patches[] = { in TEST_F() 47 LinkerPatch::RelativeCodePatch(kCallCode.size() - 4u, nullptr, 1u), in TEST_F() 49 AddCompiledMethod(MethodRef(1u), kCallCode, ArrayRef<const LinkerPatch>(patches)); in TEST_F() 59 LinkerPatch method1_patches[] = { in TEST_F() 60 LinkerPatch::RelativeCodePatch(kCallCode.size() - 4u, nullptr, 2u), in TEST_F() 62 AddCompiledMethod(MethodRef(1u), kCallCode, ArrayRef<const LinkerPatch>(method1_patches)); in TEST_F() 63 LinkerPatch method2_patches[] = { in TEST_F() 64 LinkerPatch::RelativeCodePatch(kCallCode.size() - 4u, nullptr, 1u), in TEST_F() 66 AddCompiledMethod(MethodRef(2u), kCallCode, ArrayRef<const LinkerPatch>(method2_patches)); in TEST_F() 92 LinkerPatch patches[] = { in TEST_F() [all …]
|
D | relative_patcher_x86.h | 30 const LinkerPatch& patch, 34 const LinkerPatch& patch, 37 const LinkerPatch& patch,
|
D | relative_patcher_x86.cc | 26 const LinkerPatch& patch, in PatchPcRelativeReference() 61 const LinkerPatch& patch ATTRIBUTE_UNUSED, in PatchEntrypointCall() 67 const LinkerPatch& patch ATTRIBUTE_UNUSED, in PatchBakerReadBarrierBranch()
|
/art/dex2oat/linker/arm64/ |
D | relative_patcher_arm64.cc | 58 inline bool IsAdrpPatch(const LinkerPatch& patch) { in IsAdrpPatch() 60 case LinkerPatch::Type::kCallRelative: in IsAdrpPatch() 61 case LinkerPatch::Type::kCallEntrypoint: in IsAdrpPatch() 62 case LinkerPatch::Type::kBakerReadBarrierBranch: in IsAdrpPatch() 64 case LinkerPatch::Type::kIntrinsicReference: in IsAdrpPatch() 65 case LinkerPatch::Type::kDataBimgRelRo: in IsAdrpPatch() 66 case LinkerPatch::Type::kMethodRelative: in IsAdrpPatch() 67 case LinkerPatch::Type::kMethodBssEntry: in IsAdrpPatch() 68 case LinkerPatch::Type::kTypeRelative: in IsAdrpPatch() 69 case LinkerPatch::Type::kTypeBssEntry: in IsAdrpPatch() [all …]
|
D | relative_patcher_arm64_test.cc | 111 const ArrayRef<const LinkerPatch>& method1_patches, in Create2MethodsWithGap() 113 const ArrayRef<const LinkerPatch>& last_method_patches, in Create2MethodsWithGap() 175 std::vector<uint8_t> CompileThunk(const LinkerPatch& patch, in CompileThunk() 196 const ArrayRef<const LinkerPatch>& patches = ArrayRef<const LinkerPatch>()) { in AddCompiledMethod() 200 for (const LinkerPatch& patch : patches) { in AddCompiledMethod() 201 if (patch.GetType() == LinkerPatch::Type::kCallEntrypoint || in AddCompiledMethod() 202 patch.GetType() == LinkerPatch::Type::kBakerReadBarrierBranch || in AddCompiledMethod() 203 patch.GetType() == LinkerPatch::Type::kCallRelative) { in AddCompiledMethod() 212 LinkerPatch patch = LinkerPatch::RelativeCodePatch(/* literal_offset */ 0u, in CompileMethodCallThunk() 301 const LinkerPatch patches[] = { in TestNopsAdrpLdr() [all …]
|
D | relative_patcher_arm64.h | 47 const LinkerPatch& patch, 51 const LinkerPatch& patch, 54 const LinkerPatch& patch,
|
/art/dex2oat/linker/arm/ |
D | relative_patcher_thumb2_test.cc | 144 const ArrayRef<const LinkerPatch>& method1_patches, in Create2MethodsWithGap() 146 const ArrayRef<const LinkerPatch>& last_method_patches, in Create2MethodsWithGap() 209 std::vector<uint8_t> CompileThunk(const LinkerPatch& patch, in CompileThunk() 223 const ArrayRef<const LinkerPatch>& patches = ArrayRef<const LinkerPatch>()) { in AddCompiledMethod() 227 for (const LinkerPatch& patch : patches) { in AddCompiledMethod() 228 if (patch.GetType() == LinkerPatch::Type::kCallEntrypoint || in AddCompiledMethod() 229 patch.GetType() == LinkerPatch::Type::kBakerReadBarrierBranch || in AddCompiledMethod() 230 patch.GetType() == LinkerPatch::Type::kCallRelative) { in AddCompiledMethod() 239 LinkerPatch patch = LinkerPatch::RelativeCodePatch(/* literal_offset */ 0u, in CompileMethodCallThunk() 277 void CheckPcRelativePatch(const ArrayRef<const LinkerPatch>& patches, uint32_t target_offset); [all …]
|
D | relative_patcher_thumb2.h | 42 const LinkerPatch& patch, 46 const LinkerPatch& patch, 49 const LinkerPatch& patch,
|
D | relative_patcher_arm_base.h | 88 static ThunkKey GetEntrypointCallKey(const LinkerPatch& patch); 89 static ThunkKey GetBakerThunkKey(const LinkerPatch& patch); 112 ThunkData ThunkDataForPatch(const LinkerPatch& patch, uint32_t max_next_offset);
|
D | relative_patcher_arm_base.cc | 390 const LinkerPatch& patch) { in GetEntrypointCallKey() 391 DCHECK_EQ(patch.GetType(), LinkerPatch::Type::kCallEntrypoint); in GetEntrypointCallKey() 396 const LinkerPatch& patch) { in GetBakerThunkKey() 397 DCHECK_EQ(patch.GetType(), LinkerPatch::Type::kBakerReadBarrierBranch); in GetBakerThunkKey() 405 for (const LinkerPatch& patch : compiled_method->GetPatches()) { in ProcessPatches() 410 if (patch.GetType() == LinkerPatch::Type::kCallRelative) { in ProcessPatches() 421 } else if (patch.GetType() == LinkerPatch::Type::kCallEntrypoint) { in ProcessPatches() 424 } else if (patch.GetType() == LinkerPatch::Type::kBakerReadBarrierBranch) { in ProcessPatches() 542 const LinkerPatch& patch, uint32_t max_next_offset) { in ThunkDataForPatch()
|
/art/compiler/driver/ |
D | compiled_method_storage_test.cc | 48 const linker::LinkerPatch raw_patches1[] = { in TEST() 49 linker::LinkerPatch::IntrinsicReferencePatch(0u, 0u, 0u), in TEST() 50 linker::LinkerPatch::RelativeMethodPatch(4u, nullptr, 0u, 1u), in TEST() 52 const linker::LinkerPatch raw_patches2[] = { in TEST() 53 linker::LinkerPatch::IntrinsicReferencePatch(0u, 0u, 0u), in TEST() 54 linker::LinkerPatch::RelativeMethodPatch(4u, nullptr, 0u, 2u), in TEST() 56 ArrayRef<const linker::LinkerPatch> patches[] = { in TEST() 57 ArrayRef<const linker::LinkerPatch>(raw_patches1), in TEST() 58 ArrayRef<const linker::LinkerPatch>(raw_patches2), in TEST()
|
D | compiled_method_storage.h | 33 class LinkerPatch; variable 63 const LengthPrefixedArray<linker::LinkerPatch>* DeduplicateLinkerPatches( 64 const ArrayRef<const linker::LinkerPatch>& linker_patches); 65 void ReleaseLinkerPatches(const LengthPrefixedArray<linker::LinkerPatch>* linker_patches); 70 ArrayRef<const uint8_t> GetThunkCode(const linker::LinkerPatch& linker_patch, 74 void SetThunkCode(const linker::LinkerPatch& linker_patch, 88 static ThunkMapKey GetThunkMapKey(const linker::LinkerPatch& linker_patch); 121 ArrayDedupeSet<linker::LinkerPatch> dedupe_linker_patches_;
|
D | compiled_method_storage.cc | 109 ThunkMapKey(linker::LinkerPatch::Type type, uint32_t custom_value1, uint32_t custom_value2) in ThunkMapKey() 123 linker::LinkerPatch::Type type_; 155 LengthPrefixedArrayAlloc<linker::LinkerPatch>(swap_space_.get())), in CompiledMethodStorage() 204 const LengthPrefixedArray<linker::LinkerPatch>* CompiledMethodStorage::DeduplicateLinkerPatches( in DeduplicateLinkerPatches() 205 const ArrayRef<const linker::LinkerPatch>& linker_patches) { in DeduplicateLinkerPatches() 210 const LengthPrefixedArray<linker::LinkerPatch>* linker_patches) { in ReleaseLinkerPatches() 215 const linker::LinkerPatch& linker_patch) { in GetThunkMapKey() 219 case linker::LinkerPatch::Type::kCallEntrypoint: in GetThunkMapKey() 222 case linker::LinkerPatch::Type::kBakerReadBarrierBranch: in GetThunkMapKey() 226 case linker::LinkerPatch::Type::kCallRelative: in GetThunkMapKey() [all …]
|
/art/dex2oat/linker/ |
D | relative_patcher_test.h | 104 const ArrayRef<const LinkerPatch>& patches = ArrayRef<const LinkerPatch>()) { 171 for (const LinkerPatch& patch : compiled_method->GetPatches()) { in Link() 172 if (patch.GetType() == LinkerPatch::Type::kCallRelative) { in Link() 180 } else if (patch.GetType() == LinkerPatch::Type::kStringBssEntry) { in Link() 187 } else if (patch.GetType() == LinkerPatch::Type::kStringRelative) { in Link() 194 } else if (patch.GetType() == LinkerPatch::Type::kCallEntrypoint) { in Link() 198 } else if (patch.GetType() == LinkerPatch::Type::kBakerReadBarrierBranch) { in Link() 281 void SetThunkCode(const LinkerPatch& patch, in SetThunkCode() 287 void GetThunkCode(const LinkerPatch& patch, in GetThunkCode() 306 explicit ThunkKey(const LinkerPatch& patch) in ThunkKey() [all …]
|
D | relative_patcher.h | 39 class LinkerPatch; variable 54 virtual void GetThunkCode(const LinkerPatch& patch, 136 const LinkerPatch& patch, 142 const LinkerPatch& patch, 147 const LinkerPatch& patch,
|
D | multi_oat_relative_patcher.h | 109 const LinkerPatch& patch, in PatchPcRelativeReference() 118 const LinkerPatch& patch, in PatchEntrypointCall() 125 const LinkerPatch& patch, in PatchBakerReadBarrierBranch() 147 void GetThunkCode(const LinkerPatch& patch,
|
D | relative_patcher.cc | 68 const LinkerPatch& patch ATTRIBUTE_UNUSED, in Create() 75 const LinkerPatch& patch ATTRIBUTE_UNUSED, in Create() 81 const LinkerPatch& patch ATTRIBUTE_UNUSED, in Create()
|
D | multi_oat_relative_patcher_test.cc | 89 const LinkerPatch& patch, in PatchPcRelativeReference() 98 const LinkerPatch& patch ATTRIBUTE_UNUSED, in PatchEntrypointCall() 104 const LinkerPatch& patch ATTRIBUTE_UNUSED, in PatchBakerReadBarrierBranch() 295 LinkerPatch method2_patch = in TEST_F() 296 LinkerPatch::StringBssEntryPatch(method2_literal_offset, nullptr, 0u, 1u); in TEST_F()
|
/art/compiler/ |
D | compiled_method.h | 35 class LinkerPatch; variable 116 const ArrayRef<const linker::LinkerPatch>& patches); 126 const ArrayRef<const linker::LinkerPatch>& patches); 146 ArrayRef<const linker::LinkerPatch> GetPatches() const; 162 const LengthPrefixedArray<linker::LinkerPatch>* const patches_;
|
D | compiled_method-inl.h | 49 inline ArrayRef<const linker::LinkerPatch> CompiledMethod::GetPatches() const { in GetPatches()
|