Project Home
Project Home
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
BroadcastCommunity.qnx.com will be offline from May 31 6:00pm until June 2 12:00AM for upcoming system upgrades. For more information please go to https://community.qnx.com/sf/discussion/do/listPosts/projects.bazaar/discussion.bazaar.topc28418
Forum Topic - Forwarding large amounts of data: Page 1 of 3 (3 Items)
   
Forwarding large amounts of data  
Hi,

In QNX 6.3.0SP3 I would like to implement forwarding of large data block read from socket into a write() call over QNet 
to another node (the transfer MUST be performed with a single write). To avoid allocating large memory block on the 
forwarder node I would be eager to implement "read on demand" schema.
For example, having input data amount of NxM bytes, consider setting up I/O vector with with M pointers to a 
inaccessible memory blocks of N bytes each and calling writev(). Then, when kernel attempts to read from memory and 
segmentation fault occurs, the program catches the SIGSEGV remaps the memory to allow access, reads the block from 
socket and exits the signal handler to retry the operation.
Could that be theoretically possible in QNX architecture?