On Fri, 12 Aug 2022 04:05:47 GMT, Jie Fu <ji...@openjdk.org> wrote:

>> test/jdk/jdk/internal/vm/Continuation/Fuzz.java line 81:
>> 
>>> 79:     static final boolean VERBOSE = false;
>>> 80: 
>>> 81:     static float timeoutFactor = 
>>> Float.parseFloat(System.getProperty("test.timeout.factor", "1.0"));
>> 
>> How about something like this?
>> 
>> System.getProperty("test.timeout.factor", "5.0")
>
> Or
> 
> 
> static final int COMPILATION_TIMEOUT = max((int)(1_000 * timeoutFactor), 
> 5_000); // ms

> System.getProperty("test.timeout.factor", "5.0")

Definitely not. Traditional default value for no specified timeoutFactor value 
is 1.0.

> static final int COMPILATION_TIMEOUT = max((int)(1_000 * timeoutFactor), 
> 5_000); // ms

So you're trying to make sure we have a minimum COMPILATION_TIMEOUT value of 5 
seconds,
but I'm not sure why you want that.


static final int COMPILATION_TIMEOUT = (int)(5_000 * timeoutFactor); // ms


i.e., a `default value * timeoutFactor` is the usual way to do this. I've seen 
some
folks use a timeoutFactor of 0.5 on really fast machines, but that wouldn't work
with your minimum COMPILATION_TIMEOUT value of 5 seconds above.

-------------

PR: https://git.openjdk.org/jdk/pull/9844

Reply via email to