Go to the source code of this file.
Functions | |
benchmark () | |
The "Benchmark" code to run. | |
echo (val) | |
asDestination (host, port) | |
asFile (filename) | |
haveArgument (arg) | |
rpcOnce (handle) | |
createHandleOrDie (server, port) | |
executeRemoteCalls () | |
Variables | |
iterations = 10000 | |
The number of iterations to execute by default. | |
port = 5000 | |
The default port to use in the server process. | |
argv = .z.x | |
The command line arguments. | |
argc = count .z.x | |
The number of command line arguments. | |
argvAsDictionary = .Q.opt .z.x |
asDestination | ( | host | , | |
port | ||||
) |
A function to convert a hostname and port number into a destination that we can connect to using hopen.
host | The hostname of the remote machine | |
port | The remote port to connect to |
Definition at line 39 of file benchmark.q.
References port.
asFile | ( | filename | ) |
A function to convert a filename into a file descriptor we can open using hopen.
filename | The filename to make into a descriptor |
Definition at line 48 of file benchmark.q.
benchmark | ( | ) |
The "Benchmark" code to run.
Definition at line 16 of file benchmark.q.
createHandleOrDie | ( | server | , | |
port | ||||
) |
Try to connect to the remote server on the given port. If we fail, then complain and exit.
server | The server to connect to | |
port | The port on which to connect |
Definition at line 106 of file benchmark.q.
echo | ( | val | ) |
A function to print to a value to stdout.
val | The value to print |
Definition at line 29 of file benchmark.q.
executeRemoteCalls | ( | ) |
A function to open a connection to the server and execute 'iterations' number of RPC calls to the server. Save the timing data in the log file if requested.
Definition at line 113 of file benchmark.q.
haveArgument | ( | arg | ) |
A function to check whether we were passed a certain command line argument
arg | The symbolic form of a command line argument we are checking |
Definition at line 66 of file benchmark.q.
rpcOnce | ( | handle | ) |
Performs an RPC call to execute one call to the benchmark function.
handle | an open handle to the remote server |
Definition at line 96 of file benchmark.q.
argc = count .z.x |
The number of command line arguments.
Definition at line 56 of file benchmark.q.
argv = .z.x |
The command line arguments.
Definition at line 53 of file benchmark.q.
argvAsDictionary = .Q.opt .z.x |
The command line arguments as a dictionary. "-flag arg" is processed so `flag is a key and arg is the associated value.
Definition at line 60 of file benchmark.q.
iterations = 10000 |
The number of iterations to execute by default.
Definition at line 21 of file benchmark.q.
port = 5000 |
The default port to use in the server process.
Definition at line 24 of file benchmark.q.
Referenced by asDestination().