Lines Matching refs:desc
179 static ARK_INLINE bool CopyCodeToFort(MachineCodeDesc &desc)
181 uint8_t *pText = reinterpret_cast<uint8_t*>(desc.instructionsAddr);
182 if (desc.rodataSizeBeforeTextAlign != 0) {
183 pText += desc.rodataSizeBeforeTextAlign;
186 if ((uintptr_t)desc.codeSigner == 0) {
187 if (memcpy_s(pText, desc.codeSizeAlign, reinterpret_cast<uint8_t*>(desc.codeAddr), desc.codeSize) != EOK) {
194 << std::hex << (uintptr_t)desc.codeAddr << " size: " << desc.codeSize;
195 LOG_JIT(DEBUG) << " codeSigner = " << std::hex << (uintptr_t)desc.codeSigner;
197 reinterpret_cast<OHOS::Security::CodeSign::JitCodeSignerBase*>(desc.codeSigner);
199 signer, pText, reinterpret_cast<void *>(desc.codeAddr), desc.codeSize);
206 delete reinterpret_cast<OHOS::Security::CodeSign::JitCodeSignerBase*>(desc.codeSigner);
209 if (memcpy_s(pText, desc.codeSizeAlign, reinterpret_cast<uint8_t*>(desc.codeAddr), desc.codeSize) != EOK) {
217 ARK_INLINE bool JitCompiler::AllocFromFortAndCopy(CompilationEnv &compilationEnv, MachineCodeDesc &desc)
223 size_t size = JitTask::ComputePayLoadSize(desc);
226 if (desc.isHugeObj) {
228 size + MachineCode::SIZE, hostThread, &desc);
229 if (!region || !desc.instructionsAddr) {
232 desc.hugeObjRegion = ToUintPtr(region);
234 uintptr_t mem = heap->GetMachineCodeSpace()->JitFortAllocate(&desc);
238 desc.instructionsAddr = mem;
241 if (!CopyCodeToFort(desc)) {