Improve reading of file content.
Improve reading of file content.

Make sure we have a string properly pre-allocated and
don't read content character by character.

Signed-off-by: Henner Zeller <259ad50fabbfd39355f36ecd6c0afca541ea66ef@acm.org>

chipsalliance/Surelog,chipsalliance/Surelog,chipsalliance/Surelog,alainmarcel/Surelog,alainmarcel/Surelog,alainmarcel/Surelog,chipsalliance/Surelog,alainmarcel/Surelog