Support _sysctl system call.

Partially resolves issue #1039.