[pypy-dev] lltype.Signed type in ThreadLocalReference

John Zhang John.Zhang at anu.edu.au
Tue Mar 21 01:29:08 EDT 2017


Hi all,
I’m wondering why rthread.ThreadLocalReference is initialised to have lltype.Signed type (rthread.py:387). If in get() it’s retrieved as rclass.OBJECTPTR, why not just set the type of the field to be OBJECTPTR? is this related to some specific optimisation?
The problem I’m having is that in my back-end I cannot cast an integer to a GC-ed heap object reference (which the OBJECTPTR translates to), it can only be cast to a non-GC-ed memory object reference (a different memory space not part of the GC managed heap).
Any ideas?

Regards,
John Zhang

------------------------------------------------------
John Zhang
Research Assistant
Programming Languages, Design & Implementation Division
Computer Systems Group
ANU College of Engineering & Computer Science
108 North Rd
The Australian National University
Acton ACT 2601
john.zhang at anu.edu.au<mailto:john.zhang at anu.edu.au>





-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/pypy-dev/attachments/20170321/bd2a2a89/attachment.html>


More information about the pypy-dev mailing list