RFR: 8238161: use os::fopen in HS code where possible

Baesken, Matthias matthias.baesken at sap.com
Mon Feb 3 13:08:06 UTC 2020


A little bit more info about testing -

I put the change in our internal  build/test queue , so it means   it went through   JTREG ,  JCK  and  some benchmarks and SAP application related tests .

Best regards, Matthias




Please review this change which adjusts a number of calls (in HS code)  from using  fopen  to os::fopen .

There exists for some time  a function os::fopen in HS code . This function sets "close-on-exec" flags (when possible) to the opened filedescriptor.
It might have some benefits to use os::fopen more in HS code, currently there are still quite a few calls directly to fopen .
(however there are also  already a number of calls to os::fopen  e.g.    some calls   in  os_linux.cpp /os_solaris.cpp should already look up  os::fopen  , and  logFileOutput.cpp  uses os::fopen directly   )


see also the thread
https://mail.openjdk.java.net/pipermail/hotspot-dev/2020-January/040641.html
on hotspot-dev about the topic.



Bug/webrev :

https://bugs.openjdk.java.net/browse/JDK-8238161

http://cr.openjdk.java.net/~mbaesken/webrevs/8238161.0/


Thanks, Matthias


More information about the hotspot-dev mailing list