Second attempt - with more efficient file reading.

Signed-off-by: joydeept <joydeept@microsoft.com>