memory poll for linux and windows.
test case for linux not complete.