@@ -18,18 +18,28 @@ def msbuildTypeMap = [
18
18
19
19
// convert `machine` parameter to OS component of PR task name
20
20
def machineTypeToOSTagMap = [
21
- ' Windows_NT' : ' Windows' , // Windows Server 2012 R2, equivalent to Windows 8.1 (aka Blue)
21
+ ' Windows 7' : ' Windows 7' , // Windows Server 2008 R2 ~= Windows 7
22
+ ' Windows_NT' : ' Windows' , // 'latest-or-auto' -> Windows Server 2012 R2 ~= Windows 8.1 aka Blue
23
+ ' windows.10.amd64.clientrs4.devex.open' : ' Windows' , // = Windows 10 RS4 with Dev 15.7
22
24
' Ubuntu16.04' : ' Ubuntu' ,
23
25
' OSX10.12' : ' OSX'
24
26
]
25
27
28
+ def defaultMachineTag = ' latest-or-auto'
29
+
30
+ def legacyWindowsMachine = ' Windows 7'
31
+ def legacyWindowsMachineTag = defaultMachineTag
32
+
33
+ def latestWindowsMachine = ' windows.10.amd64.clientrs4.devex.open' // Windows 10 RS4 with Dev 15.7
34
+ def latestWindowsMachineTag = null // all information is included in the machine name above
35
+
26
36
def dailyRegex = ' dailies'
27
37
28
38
// ---------------
29
39
// HELPER CLOSURES
30
40
// ---------------
31
41
32
- def CreateBuildTask = { isPR , buildArch , buildType , machine , configTag , buildExtra , testExtra , runCodeAnalysis , excludeConfigIf , nonDefaultTaskSetup ->
42
+ def CreateBuildTask = { isPR , buildArch , buildType , machine , machineTag , configTag , buildExtra , testExtra , runCodeAnalysis , excludeConfigIf , nonDefaultTaskSetup ->
33
43
if (excludeConfigIf && excludeConfigIf(isPR, buildArch, buildType)) {
34
44
return // early exit: we don't want to create a job for this configuration
35
45
}
@@ -75,7 +85,13 @@ def CreateBuildTask = { isPR, buildArch, buildType, machine, configTag, buildExt
75
85
false , // doNotFailIfNothingArchived=false ~= failIfNothingArchived
76
86
false ) // archiveOnlyIfSuccessful=false ~= archiveAlways
77
87
78
- Utilities . setMachineAffinity(newJob, machine, ' latest-or-auto' )
88
+ if (machineTag == null ) {
89
+ // note: this is a different overload and not equivalent to calling setMachineAffinity(_,_,null)
90
+ Utilities . setMachineAffinity(newJob, machine)
91
+ } else {
92
+ Utilities . setMachineAffinity(newJob, machine, machineTag)
93
+ }
94
+
79
95
Utilities . standardJobSetup(newJob, project, isPR, " */${ branch} " )
80
96
81
97
if (nonDefaultTaskSetup == null ) {
@@ -95,11 +111,11 @@ def CreateBuildTask = { isPR, buildArch, buildType, machine, configTag, buildExt
95
111
}
96
112
}
97
113
98
- def CreateBuildTasks = { machine , configTag , buildExtra , testExtra , runCodeAnalysis , excludeConfigIf , nonDefaultTaskSetup ->
114
+ def CreateBuildTasks = { machine , machineTag , configTag , buildExtra , testExtra , runCodeAnalysis , excludeConfigIf , nonDefaultTaskSetup ->
99
115
[true , false ]. each { isPR ->
100
116
[' x86' , ' x64' , ' arm' ]. each { buildArch ->
101
117
[' debug' , ' test' , ' release' ]. each { buildType ->
102
- CreateBuildTask (isPR, buildArch, buildType, machine, configTag, buildExtra, testExtra, runCodeAnalysis, excludeConfigIf, nonDefaultTaskSetup)
118
+ CreateBuildTask (isPR, buildArch, buildType, machine, machineTag, configTag, buildExtra, testExtra, runCodeAnalysis, excludeConfigIf, nonDefaultTaskSetup)
103
119
}
104
120
}
105
121
}
@@ -142,7 +158,7 @@ def CreateXPlatBuildTask = { isPR, buildType, staticBuild, machine, platform, co
142
158
true , // doNotFailIfNothingArchived=false ~= failIfNothingArchived (true ~= doNotFail)
143
159
false ) // archiveOnlyIfSuccessful=false ~= archiveAlways
144
160
145
- Utilities . setMachineAffinity(newJob, machine, ' latest-or-auto ' )
161
+ Utilities . setMachineAffinity(newJob, machine, defaultMachineTag )
146
162
Utilities . standardJobSetup(newJob, project, isPR, " */${ branch} " )
147
163
148
164
if (nonDefaultTaskSetup == null ) {
@@ -213,42 +229,53 @@ def CreateStyleCheckTasks = { taskString, taskName, checkName ->
213
229
Utilities . addGithubPushTrigger(newJob)
214
230
}
215
231
216
- Utilities . setMachineAffinity(newJob, ' Ubuntu16.04' , ' latest-or-auto ' )
232
+ Utilities . setMachineAffinity(newJob, ' Ubuntu16.04' , defaultMachineTag )
217
233
}
218
234
}
219
235
220
236
// ----------------
221
237
// INNER LOOP TASKS
222
238
// ----------------
223
239
224
- CreateBuildTasks (' Windows_NT ' , null , null , " -winBlue" , true , null , null )
240
+ CreateBuildTasks (latestWindowsMachine, latestWindowsMachineTag , null , null , " -winBlue" , true , null , null )
225
241
226
242
// Add some additional daily configs to trigger per-PR as a quality gate:
227
243
// x64_debug Slow Tests
228
244
CreateBuildTask (true , ' x64' , ' debug' ,
229
- ' Windows_NT ' , ' ci_slow' , null , ' -winBlue -includeSlow' , false , null , null )
245
+ latestWindowsMachine, latestWindowsMachineTag , ' ci_slow' , null , ' -winBlue -includeSlow' , false , null , null )
230
246
// x64_debug DisableJIT
231
247
CreateBuildTask (true , ' x64' , ' debug' ,
232
- ' Windows_NT ' , ' ci_disablejit' , ' "/p:BuildJIT=false"' , ' -winBlue -disablejit' , false , null , null )
248
+ latestWindowsMachine, latestWindowsMachineTag , ' ci_disablejit' , ' "/p:BuildJIT=false"' , ' -winBlue -disablejit' , false , null , null )
233
249
// x64_debug Lite
234
250
CreateBuildTask (true , ' x64' , ' debug' ,
235
- ' Windows_NT' , ' ci_lite' , ' "/p:BuildLite=true"' , ' -winBlue -lite' , false , null , null )
251
+ latestWindowsMachine, latestWindowsMachineTag, ' ci_lite' , ' "/p:BuildLite=true"' , ' -winBlue -lite' , false , null , null )
252
+ // x64_debug Legacy
253
+ CreateBuildTask (true , ' x64' , ' debug' ,
254
+ legacyWindowsMachine, legacyWindowsMachineTag, ' ci_legacy' , ' msbuild14' , ' -win7 -includeSlow' , false , null , null )
236
255
237
256
// -----------------
238
257
// DAILY BUILD TASKS
239
258
// -----------------
240
259
241
260
if (! branch. endsWith(' -ci' )) {
242
- // build and test on the usual configuration (VS 2015) with -includeSlow
243
- CreateBuildTasks (' Windows_NT' , ' daily_slow' , null , ' -winBlue -includeSlow' , false ,
261
+ // build and test on the legacy configuration (Windows 7 + VS 2015 (Dev14))
262
+ CreateBuildTasks (legacyWindowsMachine, legacyWindowsMachineTag, ' daily_legacy' , ' msbuild14' , ' -win7 -includeSlow' , false ,
263
+ /* excludeConfigIf */ { isPR , buildArch , buildType -> (buildArch == ' arm' ) },
264
+ /* nonDefaultTaskSetup */ { newJob , isPR , config ->
265
+ DailyBuildTaskSetup (newJob, isPR,
266
+ " Windows 7 ${ config} " ,
267
+ ' legacy\\ s+tests' )})
268
+
269
+ // build and test on the latest configuration (RS4 + VS 2017 Dev 15.7) with -includeSlow
270
+ CreateBuildTasks (latestWindowsMachine, latestWindowsMachineTag, ' daily_slow' , null , ' -winBlue -includeSlow' , false ,
244
271
/* excludeConfigIf */ null ,
245
272
/* nonDefaultTaskSetup */ { newJob , isPR , config ->
246
273
DailyBuildTaskSetup (newJob, isPR,
247
274
" Windows ${ config} " ,
248
275
' slow\\ s+tests' )})
249
276
250
- // build and test on the usual configuration (VS 2015 ) with JIT disabled
251
- CreateBuildTasks (' Windows_NT ' , ' daily_disablejit' , ' "/p:BuildJIT=false"' , ' -winBlue -disablejit' , true ,
277
+ // build and test on the latest configuration (RS4 + VS 2017 Dev 15.7 ) with JIT disabled
278
+ CreateBuildTasks (latestWindowsMachine, latestWindowsMachineTag , ' daily_disablejit' , ' "/p:BuildJIT=false"' , ' -winBlue -disablejit' , true ,
252
279
/* excludeConfigIf */ null ,
253
280
/* nonDefaultTaskSetup */ { newJob , isPR , config ->
254
281
DailyBuildTaskSetup (newJob, isPR,
@@ -292,7 +319,7 @@ if (isXPlatCompatibleBranch) {
292
319
CreateXPlatBuildTasks (osString, " linux" , " ubuntu" , branch, null , " " )
293
320
294
321
// Create a PR/continuous task to check ubuntu/static/debug/no-icu
295
- [true , false ]. each { isPR ->
322
+ [true , false ]. each { isPR ->
296
323
CreateXPlatBuildTask (isPR, " debug" , true , osString, " linux" ,
297
324
" ubuntu" , branch, null , " --no-icu" , " --not-tag exclude_noicu" , " " )
298
325
}
0 commit comments