Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1202)

Unified Diff: pkg/compiler/lib/src/ssa/optimize.dart

Issue 1803303002: Move all flags to CompilerOptions (first step to stop passing the compiler to (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: pkg/compiler/lib/src/ssa/optimize.dart
diff --git a/pkg/compiler/lib/src/ssa/optimize.dart b/pkg/compiler/lib/src/ssa/optimize.dart
index 484a78400bcc041ff6eb47adc239d2d4a7ec90c8..78d5391ad7e930da74188eaa7b260e90b3ea4e9c 100644
--- a/pkg/compiler/lib/src/ssa/optimize.dart
+++ b/pkg/compiler/lib/src/ssa/optimize.dart
@@ -61,7 +61,7 @@ class SsaOptimizerTask extends CompilerTask {
ConstantSystem constantSystem = compiler.backend.constantSystem;
JavaScriptItemCompilationContext context = work.compilationContext;
- bool trustPrimitives = compiler.trustPrimitives;
+ bool trustPrimitives = compiler.options.trustPrimitives;
measure(() {
List<OptimizationPhase> phases = <OptimizationPhase>[
// Run trivial instruction simplification first to optimize
@@ -393,7 +393,7 @@ class SsaInstructionSimplifier extends HBaseVisitor
} else if (applies(helpers.jsArrayAdd)) {
// The codegen special cases array calls, but does not
// inline argument type checks.
- if (!compiler.enableTypeAssertions) {
+ if (!compiler.options.enableTypeAssertions) {
target = helpers.jsArrayAdd;
}
}
@@ -513,7 +513,7 @@ class SsaInstructionSimplifier extends HBaseVisitor
if (type is FunctionType) {
canInline = false;
}
- if (compiler.enableTypeAssertions) {
+ if (compiler.options.enableTypeAssertions) {
// TODO(sra): Check if [input] is guaranteed to pass the parameter
// type check. Consider using a strengthened type check to avoid
// passing `null` to primitive types since the native methods usually
@@ -918,7 +918,7 @@ class SsaInstructionSimplifier extends HBaseVisitor
// interceptor calling convention, but is not a call on an
// interceptor.
HInstruction value = node.inputs.last;
- if (compiler.enableTypeAssertions) {
+ if (compiler.options.enableTypeAssertions) {
DartType type = field.type;
if (!type.treatAsRaw || type.isTypeVariable) {
// We cannot generate the correct type representation here, so don't
« no previous file with comments | « pkg/compiler/lib/src/ssa/invoke_dynamic_specializers.dart ('k') | pkg/compiler/lib/src/ssa/types_propagation.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698