Skip to content

Commit

Permalink
Version 3.4.0-261.0.dev
Browse files Browse the repository at this point in the history
Merge 495d08e into dev
  • Loading branch information
Dart CI committed Mar 22, 2024
2 parents baf8e82 + 495d08e commit a959c7d
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 22 deletions.
26 changes: 22 additions & 4 deletions pkg/front_end/tool/update_expectations.dart
Original file line number Diff line number Diff line change
Expand Up @@ -36,18 +36,32 @@ Future<void> runStandardSuites([List<String>? args]) async {
// if the first compilation is a full compilation, i.e. not outline,
// because comments are generated during body building and inference.
'-DupdateComments=true',
'-DupdateExpectations=true'
'-DupdateExpectations=true',
]);
}

Future<void> runAllSpecialSuites([List<String>? args]) async {
List<String> testingArguments = [];
for (String suite in specialSuites) {
List<String> tests = args == null
? [suite]
: args.map((String arg) => '${suite}/$arg').toList();
testingArguments.addAll(tests);
}
await fasta.main([
'testing',
...testingArguments,
'-DupdateExpectations=true',
]);
}

Future<void> main(List<String> args) async {
if (args.isEmpty) {
await runStandardSuites();
for (String suite in specialSuites) {
await fasta.main(['testing', suite, '-DupdateExpectations=true']);
}
await runAllSpecialSuites();
} else {
List<String> standardTests = <String>[];
List<String> wildcardSpecialTests = <String>[];
for (String arg in args) {
bool isSpecial = false;
for (String suite in specialSuites) {
Expand All @@ -58,9 +72,13 @@ Future<void> main(List<String> args) async {
}
}
if (!isSpecial) {
wildcardSpecialTests.add(arg);
standardTests.add(arg);
}
}
if (wildcardSpecialTests.isNotEmpty) {
await runAllSpecialSuites(wildcardSpecialTests);
}
if (standardTests.isNotEmpty) {
await runStandardSuites(standardTests);
}
Expand Down
2 changes: 1 addition & 1 deletion tools/VERSION
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,5 @@ CHANNEL dev
MAJOR 3
MINOR 4
PATCH 0
PRERELEASE 260
PRERELEASE 261
PRERELEASE_PATCH 0
30 changes: 13 additions & 17 deletions tools/gn.py
Original file line number Diff line number Diff line change
Expand Up @@ -344,6 +344,13 @@ def ProcessOsOption(os_name):


def ProcessOptions(args):
if args.goma:
print('Warning: Goma will be discontinued in the near future')
args.rbe = False
if args.verify_sdk_hash == None:
args.verify_sdk_hash = not args.rbe
if args.git_version == None:
args.git_version = not args.rbe
if args.arch == 'all':
if platform.system() == 'Darwin':
# Targeting 32 bits not supported on MacOS.
Expand Down Expand Up @@ -411,18 +418,11 @@ def ProcessOptions(args):
if HOST_OS != 'win' and args.use_crashpad:
print("Crashpad is only supported on Windows")
return False
default_rbe = os.environ.get('RBE') == '1' or \
os.environ.get('DART_RBE') == '1' or \
os.environ.get('RBE_cfg') != None
if not default_rbe and args.rbe:
args.goma = False
elif default_rbe and args.goma:
args.rbe = False
if not args.rbe and \
(socket.getfqdn().endswith('.corp.google.com') or
socket.getfqdn().endswith('.c.googlers.com')):
print('You can speed up your build by following: go/dart-rbe')
if not args.rbe and not args.goma:
if not args.goma:
print('Goma is no longer enabled by default since RBE is ready.')
old_rbe_cfg = 'win-intel.cfg' if HOST_OS == 'win32' else 'linux-intel.cfg'
new_rbe_cfg = 'windows.cfg' if HOST_OS == 'win32' else 'unix.cfg'
Expand Down Expand Up @@ -450,24 +450,20 @@ def ide_switch(host_os):
def AddCommonGnOptionArgs(parser):
"""Adds arguments that will change the default GN arguments."""

default_rbe = os.environ.get('RBE') == '1' or \
os.environ.get('DART_RBE') == '1' or \
os.environ.get('RBE_cfg') != None

parser.add_argument('--goma', help='Use goma', action='store_true')
parser.add_argument('--no-goma',
help='Disable goma',
dest='goma',
action='store_false')
parser.set_defaults(
goma=not default_rbe and sys.platform not in ['linux', 'win32'])

parser.add_argument('--rbe', help='Use rbe', action='store_true')
parser.add_argument('--no-rbe',
help='Disable rbe',
dest='rbe',
action='store_false')
parser.set_defaults(rbe=default_rbe)
parser.set_defaults(rbe=os.environ.get('RBE') == '1' or \
os.environ.get('DART_RBE') == '1' or \
os.environ.get('RBE_cfg') != None)

# Disable git hashes when remote compiling to ensure cache hits of the final
# output artifacts when nothing has changed.
Expand All @@ -480,7 +476,7 @@ def AddCommonGnOptionArgs(parser):
help='Disable SDK hash checks',
dest='verify_sdk_hash',
action='store_false')
parser.set_defaults(verify_sdk_hash=not default_rbe)
parser.set_defaults(verify_sdk_hash=None)

parser.add_argument('--git-version',
help='Enable git commit in version',
Expand All @@ -491,7 +487,7 @@ def AddCommonGnOptionArgs(parser):
help='Disable git commit in version',
dest='git_version',
action='store_false')
parser.set_defaults(git_version=not default_rbe)
parser.set_defaults(git_version=None)

parser.add_argument('--clang', help='Use Clang', action='store_true')
parser.add_argument('--no-clang',
Expand Down

0 comments on commit a959c7d

Please sign in to comment.