User`s guide

Developing LUC Applications [5]
This chapter describes how to use the LUC library in your application. The following
tasks are discussed:
Constructing a client
Constructing a server
Making remote procedure calls
5.1 Programming Considerations for LUC Applications
On the service (Linux) nodes, int is defined as 4 bytes. On the MTK compute
nodes int is defined as 8 bytes. To avoid potential issues, programmers should
use types that have explicit sizes, for example int64_t.
There is a limit of 256 MB of data that can be transferred in a single call. This
applies to both input and output buffers.
Linux and MTK have different native byte ordering, Linux is little endian (4
bytes) and MTK is big endian (8 bytes). LUC does not byte-swap or otherwise
interpret the application's input and output data so you must add byte-swapping
into your application that will perform byte swapping for data transfers between
the server and client applications.
The number of threads that are assigned to an object during a call to
startService should be determined by the length of time function calls made
by that object are expected to take. Allocate enough threads so that an operation is
never stalled while waiting for a thread to become available.
The Linux version of the library can only honor a requestedPid value other than
PTL_PID_ANY for the first endpoint in an application process. The exception is
that subsequent values of requestedPid may be honored if they are equal to the
requestedPid of the first endpoint for a process.
5.2 Creating and Using a LUC Client
Use the following procedure to create a client object.
S247920 53