8153407: javac, fold debug options

Reviewed-by: mcimadamore, jjg
This commit is contained in:
Vicente Romero 2016-07-08 16:47:13 -07:00
parent 003244f622
commit bec16625dc
33 changed files with 96 additions and 74 deletions

View File

@ -62,6 +62,8 @@ import java.util.Set;
import java.util.function.BiFunction;
import java.util.function.BiPredicate;
import com.sun.tools.javac.main.Option;
import static com.sun.tools.javac.code.TypeTag.*;
/** Helper class for type parameter inference, used by the attribution phase.
@ -87,7 +89,7 @@ public class Infer {
/**
* folder in which the inference dependency graphs should be written.
*/
final private String dependenciesFolder;
private final String dependenciesFolder;
/**
* List of graphs awaiting to be dumped to a file.
@ -114,7 +116,7 @@ public class Infer {
Options options = Options.instance(context);
allowGraphInference = Source.instance(context).allowGraphInference()
&& options.isUnset("useLegacyInference");
dependenciesFolder = options.get("dumpInferenceGraphsTo");
dependenciesFolder = options.get("debug.dumpInferenceGraphsTo");
pendingGraphs = List.nil();
emptyContext = new InferenceContext(this, List.<Type>nil());

View File

@ -68,6 +68,8 @@ import static com.sun.tools.javac.tree.JCTree.Tag.*;
import javax.lang.model.element.ElementKind;
import javax.lang.model.type.TypeKind;
import com.sun.tools.javac.main.Option;
/**
* This pass desugars lambda expressions into static methods
*
@ -104,7 +106,7 @@ public class LambdaToMethod extends TreeTranslator {
private KlassInfo kInfo;
/** dump statistics about lambda code generation */
private boolean dumpLambdaToMethodStats;
private final boolean dumpLambdaToMethodStats;
/** force serializable representation, for stress testing **/
private final boolean forceSerializable;
@ -142,7 +144,7 @@ public class LambdaToMethod extends TreeTranslator {
transTypes = TransTypes.instance(context);
analyzer = new LambdaAnalyzerPreprocessor();
Options options = Options.instance(context);
dumpLambdaToMethodStats = options.isSet("dumpLambdaToMethodStats");
dumpLambdaToMethodStats = options.isSet("debug.dumpLambdaToMethodStats");
attr = Attr.instance(context);
forceSerializable = options.isSet("forceSerializable");
}

View File

@ -180,7 +180,7 @@ public class Resolve {
}
static EnumSet<VerboseResolutionMode> getVerboseResolutionMode(Options opts) {
String s = opts.get("verboseResolution");
String s = opts.get("debug.verboseResolution");
EnumSet<VerboseResolutionMode> res = EnumSet.noneOf(VerboseResolutionMode.class);
if (s == null) return res;
if (s.contains("all")) {

View File

@ -47,6 +47,7 @@ import com.sun.tools.javac.jvm.Pool.DynamicMethod;
import com.sun.tools.javac.jvm.Pool.Method;
import com.sun.tools.javac.jvm.Pool.MethodHandle;
import com.sun.tools.javac.jvm.Pool.Variable;
import com.sun.tools.javac.main.Option;
import com.sun.tools.javac.util.*;
import static com.sun.tools.javac.code.Flags.*;
@ -84,7 +85,7 @@ public class ClassWriter extends ClassFile {
/** Switch: describe the generated stackmap.
*/
boolean debugstackmap;
private boolean debugstackmap;
/**
* Target class version.
@ -181,20 +182,18 @@ public class ClassWriter extends ClassFile {
verbose = options.isSet(VERBOSE);
genCrt = options.isSet(XJCOV);
debugstackmap = options.isSet("debugstackmap");
debugstackmap = options.isSet("debug.stackmap");
emitSourceFile = options.isUnset(G_CUSTOM) ||
options.isSet(G_CUSTOM, "source");
String dumpModFlags = options.get("dumpmodifiers");
dumpClassModifiers =
(dumpModFlags != null && dumpModFlags.indexOf('c') != -1);
dumpFieldModifiers =
(dumpModFlags != null && dumpModFlags.indexOf('f') != -1);
dumpInnerClassModifiers =
(dumpModFlags != null && dumpModFlags.indexOf('i') != -1);
dumpMethodModifiers =
(dumpModFlags != null && dumpModFlags.indexOf('m') != -1);
String modifierFlags = options.get("debug.dumpmodifiers");
if (modifierFlags != null) {
dumpClassModifiers = modifierFlags.indexOf('c') != -1;
dumpFieldModifiers = modifierFlags.indexOf('f') != -1;
dumpInnerClassModifiers = modifierFlags.indexOf('i') != -1;
dumpMethodModifiers = modifierFlags.indexOf('m') != -1;
}
}
/******************************************************************
@ -210,10 +209,10 @@ public class ClassWriter extends ClassFile {
* For example, to dump everything:
* javac -XDdumpmodifiers=cifm MyProg.java
*/
private final boolean dumpClassModifiers; // -XDdumpmodifiers=c
private final boolean dumpFieldModifiers; // -XDdumpmodifiers=f
private final boolean dumpInnerClassModifiers; // -XDdumpmodifiers=i
private final boolean dumpMethodModifiers; // -XDdumpmodifiers=m
private boolean dumpClassModifiers; // -XDdumpmodifiers=c
private boolean dumpFieldModifiers; // -XDdumpmodifiers=f
private boolean dumpInnerClassModifiers; // -XDdumpmodifiers=i
private boolean dumpMethodModifiers; // -XDdumpmodifiers=m
/** Return flags as a string, separated by " ".

View File

@ -38,6 +38,7 @@ import com.sun.tools.javac.code.Symbol.*;
import com.sun.tools.javac.code.Type.*;
import com.sun.tools.javac.jvm.Code.*;
import com.sun.tools.javac.jvm.Items.*;
import com.sun.tools.javac.main.Option;
import com.sun.tools.javac.tree.EndPosTable;
import com.sun.tools.javac.tree.JCTree.*;
@ -124,7 +125,7 @@ public class Gen extends JCTree.Visitor {
? options.isSet(G)
: options.isSet(G_CUSTOM, "vars");
genCrt = options.isSet(XJCOV);
debugCode = options.isSet("debugcode");
debugCode = options.isSet("debug.code");
allowBetterNullChecks = target.hasObjects();
pool = new Pool(types);

View File

@ -243,7 +243,7 @@ public class Main {
return Result.OK;
// init Dependencies
if (options.isSet("completionDeps")) {
if (options.isSet("debug.completionDeps")) {
Dependencies.GraphDependencies.preRegister(context);
}

View File

@ -517,15 +517,32 @@ public enum Option {
}
@Override
public boolean process(OptionHelper helper, String option) {
option = option.substring(text.length());
int eq = option.indexOf('=');
String key = (eq < 0) ? option : option.substring(0, eq);
String value = (eq < 0) ? option : option.substring(eq+1);
return process(helper, option, option.substring(text.length()));
}
@Override
public boolean process(OptionHelper helper, String option, String arg) {
int eq = arg.indexOf('=');
String key = (eq < 0) ? arg : arg.substring(0, eq);
String value = (eq < 0) ? arg : arg.substring(eq+1);
helper.put(key, value);
return false;
}
},
XDEBUG("-Xdebug:", null, HIDDEN, BASIC) {
@Override
public boolean process(OptionHelper helper, String option) {
String p = option.substring(option.indexOf(':') + 1).trim();
String[] subOptions = p.split(";");
for (String subOption : subOptions) {
subOption = "debug." + subOption.trim();
XD.process(helper, subOption, subOption);
}
return false;
}
},
XADDEXPORTS("-XaddExports:", "opt.arg.addExports", "opt.addExports", EXTENDED, BASIC) {
@Override
public boolean process(OptionHelper helper, String option) {

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2014, 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -47,8 +47,6 @@ import java.util.List;
import java.util.Map;
import java.util.Properties;
import java.util.Stack;
import java.util.stream.Collectors;
import java.util.stream.Stream;
import javax.tools.JavaFileObject;
@ -126,9 +124,9 @@ public abstract class Dependencies {
*/
GraphDependencies(Context context) {
super(context);
Options options = Options.instance(context);
//fetch filename
String[] modes = options.get("completionDeps").split(",");
Options options = Options.instance(context);
String[] modes = options.get("debug.completionDeps").split(",");
for (String mode : modes) {
if (mode.startsWith("file=")) {
dependenciesFile = mode.substring(5);

View File

@ -313,7 +313,7 @@ public class Options {
}
// Enable dependency generation
args.add("-XDcompletionDeps=source,class");
args.add("-Xdebug:completionDeps=source,class");
// This can't be anything but 'none'. Enforced by sjavac main method.
args.add("-implicit:" + implicitPolicy);

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 1998, 2010, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1998, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -28,7 +28,7 @@
* file are correct, including those within InnerClasses attributes.
* @author John Rose (jrose). Entered as a regression test by Bill Maddox (maddox).
*
* @compile/ref=ClassModifiers.out -XDdumpmodifiers=ci ClassModifiers.java
* @compile/ref=ClassModifiers.out -Xdebug:dumpmodifiers=ci ClassModifiers.java
*
*/

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1999, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -26,7 +26,7 @@
* @bug 4249112 4785453
* @summary Verify that implicit member modifiers are set correctly.
*
* @compile/ref=MemberModifiers.out -XDdumpmodifiers=cfm MemberModifiers.java
* @compile/ref=MemberModifiers.out -Xdebug:dumpmodifiers=cfm MemberModifiers.java
*/
// Currently, we check only that members of final classes are not final.

View File

@ -47,7 +47,7 @@ public class DepsAndAnno {
public static void main(String[] args) {
ToolBox toolBox = new ToolBox();
new JavacTask(toolBox, Task.Mode.CMDLINE)
.options("-XDcompletionDeps")
.options("-Xdebug:completionDeps")
.outdir(".")
.files(ToolBox.testSrc + "/DepsAndAnno.java")
.run();

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -25,7 +25,7 @@
* @test
* @bug 8078389
* @summary Make sure there is no interference between completionDeps and doclint
* @compile -XDcompletionDeps -Xdoclint DepsAndDocLint.java
* @compile -Xdebug:completionDeps -Xdoclint DepsAndDocLint.java
*/
public class DepsAndDocLint {

View File

@ -257,6 +257,9 @@ public class CheckResourceKeys {
// ignore package and class names
if (cs.matches("(com|java|javax|jdk|sun)\\.[A-Za-z.]+"))
continue;
// ignore debug flag names
if (cs.startsWith("debug."))
continue;
// explicit known exceptions
if (noResourceRequired.contains(cs))
continue;

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -23,7 +23,7 @@
// key: compiler.misc.applicable.method.found
// key: compiler.note.verbose.resolve.multi
// options: -XDverboseResolution=applicable,success
// options: -Xdebug:verboseResolution=applicable,success
class ApplicableMethodFound {

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -24,7 +24,7 @@
// key: compiler.misc.applicable.method.found.1
// key: compiler.note.verbose.resolve.multi
// key: compiler.misc.partial.inst.sig
// options: -XDverboseResolution=applicable,success
// options: -Xdebug:verboseResolution=applicable,success
class ApplicableMethodFound1 {

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -25,7 +25,7 @@
// key: compiler.note.verbose.resolve.multi
// key: compiler.note.deferred.method.inst
// key: compiler.misc.partial.inst.sig
// options: -XDverboseResolution=applicable,success,deferred-inference
// options: -Xdebug:verboseResolution=applicable,success,deferred-inference
class DeferredMethodInst {

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -22,7 +22,7 @@
*/
// key: compiler.note.lambda.stat
// options: -XDdumpLambdaToMethodStats
// options: -Xdebug:dumpLambdaToMethodStats
class LambdaStat {
Runnable r = ()->{};

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -22,7 +22,7 @@
*/
// key: compiler.note.mref.stat
// options: -XDdumpLambdaToMethodStats
// options: -Xdebug:dumpLambdaToMethodStats
class MrefStat {
Runnable r = MrefStat::m;

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2013, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -22,7 +22,7 @@
*/
// key: compiler.note.mref.stat.1
// options: -XDdumpLambdaToMethodStats
// options: -Xdebug:dumpLambdaToMethodStats
class MrefStat1 {

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -26,7 +26,7 @@
// key: compiler.err.cant.apply.symbol
// key: compiler.misc.no.conforming.assignment.exists
// key: compiler.misc.inconvertible.types
// options: -XDverboseResolution=inapplicable,failure
// options: -Xdebug:verboseResolution=inapplicable,failure
class NotApplicableMethodFound {

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -24,7 +24,7 @@
// key: compiler.misc.applicable.method.found.1
// key: compiler.note.verbose.resolve.multi
// key: compiler.misc.partial.inst.sig
// options: -XDverboseResolution=applicable,success
// options: -Xdebug:verboseResolution=applicable,success
class PartialInstSig {

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -23,7 +23,7 @@
// key: compiler.misc.applicable.method.found
// key: compiler.note.verbose.resolve.multi
// options: -XDverboseResolution=applicable,success
// options: -Xdebug:verboseResolution=applicable,success
class VerboseResolveMulti {

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -26,7 +26,7 @@
// key: compiler.err.cant.apply.symbol
// key: compiler.misc.no.conforming.assignment.exists
// key: compiler.misc.inconvertible.types
// options: -XDverboseResolution=inapplicable,failure
// options: -Xdebug:verboseResolution=inapplicable,failure
class VerboseResolveMulti1 {

View File

@ -27,7 +27,7 @@
* @test
* @bug 8158355
* @summary Inference graph dot support broken
* @compile -XDdumpInferenceGraphsTo=. T8158355.java
* @compile -Xdebug:dumpInferenceGraphsTo=. T8158355.java
*/
import java.util.List;

View File

@ -2,7 +2,7 @@
* @test /nodynamiccopyright/
* @bug 8029718
* @summary Should always use lambda body structure to disambiguate overload resolution
* @compile/fail/ref=MostSpecific09.out -XDrawDiagnostics -XDshouldStopPolicy=ATTR -XDverboseResolution=applicable,success MostSpecific09.java
* @compile/fail/ref=MostSpecific09.out -XDrawDiagnostics -XDshouldStopPolicy=ATTR -Xdebug:verboseResolution=applicable,success MostSpecific09.java
*/
class MostSpecific09 {

View File

@ -3,7 +3,7 @@ MostSpecific09.java:26:9: compiler.note.verbose.resolve.multi: foo, MostSpecific
MostSpecific09.java:27:9: compiler.note.verbose.resolve.multi: foo, MostSpecific09, 0, BASIC, compiler.misc.type.none, compiler.misc.no.args,{(compiler.misc.applicable.method.found: 0, foo(MostSpecific09.J), null)}
MostSpecific09.java:27:32: compiler.note.verbose.resolve.multi: println, java.io.PrintStream, 1, BASIC, java.lang.String, compiler.misc.no.args,{(compiler.misc.applicable.method.found: 0, println(java.lang.Object), null),(compiler.misc.applicable.method.found: 1, println(java.lang.String), null)}
MostSpecific09.java:28:13: compiler.err.lambda.body.neither.value.nor.void.compatible
MostSpecific09.java:28:9: compiler.err.cant.apply.symbols: kindname.method, foo, @680,{(compiler.misc.inapplicable.method: kindname.method, MostSpecific09, foo(MostSpecific09.I), (compiler.misc.no.conforming.assignment.exists: (compiler.misc.incompatible.ret.type.in.lambda: (compiler.misc.missing.ret.val: java.lang.String)))),(compiler.misc.inapplicable.method: kindname.method, MostSpecific09, foo(MostSpecific09.J), (compiler.misc.no.conforming.assignment.exists: (compiler.misc.unexpected.ret.val)))}
MostSpecific09.java:28:9: compiler.err.cant.apply.symbols: kindname.method, foo, @685,{(compiler.misc.inapplicable.method: kindname.method, MostSpecific09, foo(MostSpecific09.I), (compiler.misc.no.conforming.assignment.exists: (compiler.misc.incompatible.ret.type.in.lambda: (compiler.misc.missing.ret.val: java.lang.String)))),(compiler.misc.inapplicable.method: kindname.method, MostSpecific09, foo(MostSpecific09.J), (compiler.misc.no.conforming.assignment.exists: (compiler.misc.unexpected.ret.val)))}
MostSpecific09.java:28:43: compiler.note.verbose.resolve.multi: println, java.io.PrintStream, 1, BASIC, java.lang.String, compiler.misc.no.args,{(compiler.misc.applicable.method.found: 0, println(java.lang.Object), null),(compiler.misc.applicable.method.found: 1, println(java.lang.String), null)}
MostSpecific09.java:29:9: compiler.err.ref.ambiguous: foo, kindname.method, foo(MostSpecific09.I), MostSpecific09, kindname.method, foo(MostSpecific09.J), MostSpecific09
MostSpecific09.java:29:28: compiler.note.verbose.resolve.multi: <init>, java.lang.RuntimeException, 0, BASIC, compiler.misc.no.args, compiler.misc.no.args,{(compiler.misc.applicable.method.found: 0, java.lang.RuntimeException(), null)}
@ -11,7 +11,7 @@ MostSpecific09.java:30:9: compiler.err.ref.ambiguous: foo, kindname.method, foo(
MostSpecific09.java:32:9: compiler.err.ref.ambiguous: foo, kindname.method, foo(MostSpecific09.I), MostSpecific09, kindname.method, foo(MostSpecific09.J), MostSpecific09
MostSpecific09.java:33:9: compiler.note.verbose.resolve.multi: foo, MostSpecific09, 0, BASIC, compiler.misc.type.none, compiler.misc.no.args,{(compiler.misc.applicable.method.found: 0, foo(MostSpecific09.I), null)}
MostSpecific09.java:42:13: compiler.err.lambda.body.neither.value.nor.void.compatible
MostSpecific09.java:42:9: compiler.err.cant.apply.symbols: kindname.method, foo, @1129,{(compiler.misc.inapplicable.method: kindname.method, MostSpecific09, foo(MostSpecific09.I), (compiler.misc.no.conforming.assignment.exists: (compiler.misc.incompatible.ret.type.in.lambda: (compiler.misc.missing.ret.val: java.lang.String)))),(compiler.misc.inapplicable.method: kindname.method, MostSpecific09, foo(MostSpecific09.J), (compiler.misc.no.conforming.assignment.exists: (compiler.misc.unexpected.ret.val)))}
MostSpecific09.java:42:9: compiler.err.cant.apply.symbols: kindname.method, foo, @1134,{(compiler.misc.inapplicable.method: kindname.method, MostSpecific09, foo(MostSpecific09.I), (compiler.misc.no.conforming.assignment.exists: (compiler.misc.incompatible.ret.type.in.lambda: (compiler.misc.missing.ret.val: java.lang.String)))),(compiler.misc.inapplicable.method: kindname.method, MostSpecific09, foo(MostSpecific09.J), (compiler.misc.no.conforming.assignment.exists: (compiler.misc.unexpected.ret.val)))}
MostSpecific09.java:46:23: compiler.note.verbose.resolve.multi: println, java.io.PrintStream, 1, BASIC, java.lang.String, compiler.misc.no.args,{(compiler.misc.applicable.method.found: 0, println(java.lang.Object), null),(compiler.misc.applicable.method.found: 1, println(java.lang.String), null)}
MostSpecific09.java:49:9: compiler.note.verbose.resolve.multi: foo, MostSpecific09, 0, BASIC, compiler.misc.type.none, compiler.misc.no.args,{(compiler.misc.applicable.method.found: 0, foo(MostSpecific09.J), null)}
MostSpecific09.java:56:25: compiler.note.verbose.resolve.multi: <init>, Bar, 0, BASIC, compiler.misc.no.args, compiler.misc.no.args,{(compiler.misc.applicable.method.found: 0, Bar(), null)}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -122,7 +122,7 @@ public class TestLambdaToMethodStats extends ComboInstance<TestLambdaToMethodSta
@Override
public void doWork() throws IOException {
check(newCompilationTask()
.withOption("-XDdumpLambdaToMethodStats")
.withOption("-Xdebug:dumpLambdaToMethodStats")
.withSourceFromTemplate(template)
.generate());
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -25,7 +25,7 @@
* @test
* @bug 8143217
* @summary javac throws NPE when printing diagnostics for Lambda expressions
* @compile XDdumpLambdaToMethodStats.java -XDdumpLambdaToMethodStats
* @compile XDdumpLambdaToMethodStats.java -Xdebug:dumpLambdaToMethodStats
*
*/

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2013, 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -274,7 +274,7 @@ public class TestMetafactoryBridges {
sourcefiles.add(new JavaSource(ck));
}
JavacTask ct = (JavacTask)tool.getTask(debugWriter, null, diagChecker,
Arrays.asList("-XDdumpLambdaToMethodStats", "-d", outDir.getAbsolutePath(),
Arrays.asList("-Xdebug:dumpLambdaToMethodStats", "-d", outDir.getAbsolutePath(),
"-sourcepath", srcDir.getAbsolutePath(),
"-classpath", classesDir.getAbsolutePath(),
pp.preferOpt), null, sourcefiles);

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2012, 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -210,7 +210,7 @@ public class StructuralMostSpecificTest extends ComboInstance<StructuralMostSpec
public void doWork() throws Throwable {
check(newCompilationTask()
.withSourceFromTemplate(sourceTemplate)
.withOption("-XDverboseResolution=all,-predef,-internal,-object-init")
.withOption("-Xdebug:verboseResolution=all,-predef,-internal,-object-init")
.analyze());
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -133,7 +133,7 @@ public class ResolveHarness implements javax.tools.DiagnosticListener<JavaFileOb
protected void check() throws Exception {
String[] options = {
"-XDshouldStopPolicy=ATTR",
"-XDverboseResolution=success,failure,applicable,inapplicable,deferred-inference,predef"
"-Xdebug:verboseResolution=success,failure,applicable,inapplicable,deferred-inference,predef"
};
AbstractProcessor[] processors = { new ResolveCandidateFinder(), null };

View File

@ -96,7 +96,7 @@ public class JavacOptionPrep {
// Ignore this option for now. When the file=... requirement goes
// away, this will be easier to handle.
if (option.startsWith("-XDcompletionDeps"))
if (option.startsWith("-Xdebug:completionDeps"))
continue;
switch (option) {