根据Maven GWT Plugin docs,默认优化级别为-1。目前还不清楚这与哪个优化级别相对应。那么,-1是否意味着代码在0到9之间的某个级别进行了优化?或者是完全不同的东西?
发布于 2013-01-17 00:33:16
GWT有9种不同的优化技巧,从级别1到级别9,除了常规的编译器级别的东西。但是,我们可以通过将其设置为0来选择退出这些优化。正如代码中注释的那样,不建议这样做。
您可能可以从ArgHandlerOptimize.java中的GWT源代码中获得更多信息。
@Override
public String getPurpose() {
return "Sets the optimization level used by the compiler. 0=none 9=maximum.";
}来自ArgHandlerOptimize.java的注释部分
* Set the optimization level from the command line. For now, level 1 is the same
* as draft compile, and level 9 is the same as the default (maximium optimization).
*
* TODO(zundel): In theory, a level 0 should be possible, where all optimizers
* are eliminated for the fastest possible compile. In practice, code generation
* depends on some optimizers being run.发布于 2013-01-17 00:32:09
这意味着它使用来自GWT编译器的默认值。我相信默认值是9。
https://stackoverflow.com/questions/14363018
复制相似问题