Exemplo n.º 1
0
    def is_jit_address(self, pc):
        if self.proc_mappings is not None:
            return not self.text_address_claimed(pc)

        cx = self.get_tls_context()
        runtime = cx['runtime_']['value']
        if long(runtime.address) == 0:
            return False

        jitRuntime = runtime['jitRuntime_']
        if long(jitRuntime.address) == 0:
            return False

        execAllocators = [jitRuntime['execAlloc_'], jitRuntime['backedgeExecAlloc_']]
        for execAlloc in execAllocators:
            for pool in jsjitExecutableAllocator(execAlloc, self.typecache):
                pages = pool['m_allocation']['pages']
                size = pool['m_allocation']['size']
                if pages <= pc and pc < pages + size:
                    return True
        return False
Exemplo n.º 2
0
    def is_jit_address(self, pc):
        if self.proc_mappings != None:
            return not self.text_address_claimed(pc)

        ptd = self.get_tls_per_thread_data()
        runtime = ptd['runtime_']
        if runtime == 0:
            return False

        jitRuntime = runtime['jitRuntime_']
        if jitRuntime == 0:
            return False

        execAllocators = [jitRuntime['execAlloc_'], jitRuntime['backedgeExecAlloc_']]
        for execAlloc in execAllocators:
            for pool in jsjitExecutableAllocator(execAlloc, self.typecache):
                pages = pool['m_allocation']['pages']
                size = pool['m_allocation']['size']
                if pages <= pc and pc < pages + size:
                    return True
        return False