Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-48932

There is no macro for the host pointer size

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P4: Low
    • 5.6.0
    • 5.6.0 Alpha
    • Build System
    • None
    • 00f35b4ae7f94e0fe1c8c77efec401ab5f3c4855

    Description

      There is a QT_POINTER_SIZE, which is set to the size of pointers on the target system. However, for host tools, the pointer size might be different. So it would be useful to have a QT_HOST_POINTER_SIZE for this.

      The problematic case is QV4::Value, which stores (tagged) object pointers differently depending on 32/64 bit. The actual 'choice' is made by a macro, because the class has to be a PDO. Using a template to implement this, might remove the PDO status depending on how smart/correct the compiler is. The current work-around is quite fragile: because no pointers are stored in QV4::Value when using it in a host build, the two accessor methods are implemented as Q_UNREACHABLE(), and a 64bit storage scheme is forced.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            thiago Thiago Macieira
            erikv Erik Verbruggen
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes