Memory limit in one of my sites is set as 20000000 not 20M. This will cause memory_is_mem_available to fail because php_to_byte reports 1/10 of memory configured.
If none of the units match, we should return something more correct. Patch included to return a more correct value.