qnx_fd_attach

The doc says the handle is 16 bit only, is that really true?

  • Mario

Mario Charest wrote:

The doc says the handle is 16 bit only, is that really true?

In 16 bit mode it is.

In 32bit mode, there is some munging to get 24bits of handle into the
message to Proc, but it should still be a near pointer.

\

Cheers,
Adam

QNX Software Systems Ltd.
[ amallory@qnx.com ]

With a PC, I always felt limited by the software available.
On Unix, I am limited only by my knowledge.
–Peter J. Schoenster <pschon@baste.magibox.net>

“Adam Mallory” <amallory@qnx.com> wrote in message
news:cdm9l2$nt8$1@inn.qnx.com

Mario Charest wrote:
The doc says the handle is 16 bit only, is that really true?

In 16 bit mode it is.

In 32bit mode, there is some munging to get 24bits of handle into the
message to Proc, but it should still be a near pointer.

24 bits only? aren`t near pointer 32 bits in 32bit mode


Cheers,
Adam

QNX Software Systems Ltd.
[ > amallory@qnx.com > ]

With a PC, I always felt limited by the software available.
On Unix, I am limited only by my knowledge.
–Peter J. Schoenster <> pschon@baste.magibox.net

Mario Charest wrote:

24 bits only? aren`t near pointer 32 bits in 32bit mode

Yep, near ptrs are 32 bits in size in 32bit mode.

The handle isn’t nessesarily for function pointers - it’s just a unique
value. 16M-1 different unique values should be enough from an iomgr
point of view.

\

Cheers,
Adam

QNX Software Systems Ltd.
[ amallory@qnx.com ]

With a PC, I always felt limited by the software available.
On Unix, I am limited only by my knowledge.
–Peter J. Schoenster <pschon@baste.magibox.net>

“Adam Mallory” <amallory@qnx.com> wrote in message
news:cdocrs$dih$1@inn.qnx.com

Mario Charest wrote:

24 bits only? aren`t near pointer 32 bits in 32bit mode

Yep, near ptrs are 32 bits in size in 32bit mode.

The handle isn’t nessesarily for function pointers - it’s just a unique
value. 16M-1 different unique values should be enough from an iomgr
point of view.

Ok that explain the problem I’m seeing, I’m using it as a pointer hence
(store the value return by malloc), so most of the time it works but
sometimes it doesn’t


Cheers,
Adam

QNX Software Systems Ltd.
[ > amallory@qnx.com > ]

With a PC, I always felt limited by the software available.
On Unix, I am limited only by my knowledge.
–Peter J. Schoenster <> pschon@baste.magibox.net