package org.graalvm.compiler.phases.common.inlining;
import java.util.*;
import org.graalvm.compiler.options.*;
import org.graalvm.compiler.options.OptionType;
public class InliningPhase_OptionDescriptors implements OptionDescriptors {
@Override
public OptionDescriptor get(String value) {
switch (value) {
case "AlwaysInlineIntrinsics": {
return OptionDescriptor.create(
"AlwaysInlineIntrinsics",
OptionType.Debug,
Boolean.class,
"Unconditionally inline intrinsics",
InliningPhase.Options.class,
"AlwaysInlineIntrinsics",
InliningPhase.Options.AlwaysInlineIntrinsics);
}
case "MethodInlineBailoutLimit": {
return OptionDescriptor.create(
"MethodInlineBailoutLimit",
OptionType.Debug,
Integer.class,
"Per-compilation method inlining exploration limit before giving up (use 0 to disable)",
InliningPhase.Options.class,
"MethodInlineBailoutLimit",
InliningPhase.Options.MethodInlineBailoutLimit);
}
}
return null;
}
@Override
public Iterator<OptionDescriptor> iterator() {
return new Iterator<OptionDescriptor>() {
int i = 0;
@Override
public boolean hasNext() {
return i < 2;
}
@Override
public OptionDescriptor next() {
switch (i++) {
case 0: return get("AlwaysInlineIntrinsics");
case 1: return get("MethodInlineBailoutLimit");
}
throw new NoSuchElementException();
}
};
}
}