@@ -1611,16 +1611,23 @@ NOTE: if you're sure you want to do this, please open an issue as to why. In the
1611
1611
. ensure ( dist:: DebuggerScripts { sysroot : builder. sysroot ( compiler) , host : target } ) ;
1612
1612
}
1613
1613
1614
- builder. ensure ( compile:: Std :: new ( compiler, target) ) ;
1614
+ if suite == "mir-opt" {
1615
+ builder. ensure ( compile:: Std :: new_for_mir_opt_tests ( compiler, target) ) ;
1616
+ } else {
1617
+ builder. ensure ( compile:: Std :: new ( compiler, target) ) ;
1618
+ }
1619
+
1615
1620
// ensure that `libproc_macro` is available on the host.
1616
1621
builder. ensure ( compile:: Std :: new ( compiler, compiler. host ) ) ;
1617
1622
1618
1623
// Also provide `rust_test_helpers` for the host.
1619
1624
builder. ensure ( TestHelpers { target : compiler. host } ) ;
1620
1625
1621
- // As well as the target, except for plain wasm32, which can't build it
1622
- if !target. contains ( "wasm" ) || target. contains ( "emscripten" ) {
1623
- builder. ensure ( TestHelpers { target } ) ;
1626
+ if suite != "mir-opt" {
1627
+ // As well as the target, except for plain wasm32, which can't build it
1628
+ if !target. contains ( "wasm" ) || target. contains ( "emscripten" ) {
1629
+ builder. ensure ( TestHelpers { target } ) ;
1630
+ }
1624
1631
}
1625
1632
1626
1633
builder. ensure ( RemoteCopyLibs { compiler, target } ) ;
@@ -1749,11 +1756,13 @@ NOTE: if you're sure you want to do this, please open an issue as to why. In the
1749
1756
cmd. arg ( "--host-rustcflags" ) . arg ( flag) ;
1750
1757
}
1751
1758
1752
- let mut targetflags = flags;
1753
- targetflags. push ( format ! ( "-Lnative={}" , builder. test_helpers_out( target) . display( ) ) ) ;
1754
- targetflags. extend ( linker_flags ( builder, compiler. host , LldThreads :: No ) ) ;
1755
- for flag in targetflags {
1756
- cmd. arg ( "--target-rustcflags" ) . arg ( flag) ;
1759
+ if mode != "mir-opt" {
1760
+ let mut targetflags = flags;
1761
+ targetflags. push ( format ! ( "-Lnative={}" , builder. test_helpers_out( target) . display( ) ) ) ;
1762
+ targetflags. extend ( linker_flags ( builder, compiler. host , LldThreads :: No ) ) ;
1763
+ for flag in targetflags {
1764
+ cmd. arg ( "--target-rustcflags" ) . arg ( flag) ;
1765
+ }
1757
1766
}
1758
1767
1759
1768
cmd. arg ( "--python" ) . arg ( builder. python ( ) ) ;
0 commit comments