Skip to content

Commit 934d56a

Browse files
committed
Also allow returning PassMode::ByValPair directly into an ssa var
Benchmark #1: ./raytracer_cg_clif_pre Time (mean ± σ): 8.251 s ± 0.021 s [User: 8.245 s, System: 0.005 s] Range (min … max): 8.225 s … 8.292 s 10 runs Benchmark #2: ./raytracer_cg_clif_post Time (mean ± σ): 8.206 s ± 0.043 s [User: 8.199 s, System: 0.007 s] Range (min … max): 8.168 s … 8.279 s 10 runs
1 parent a12f601 commit 934d56a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/abi/returning.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ pub(crate) fn can_return_to_ssa_var<'tcx>(
1010
dest_layout: TyAndLayout<'tcx>,
1111
) -> bool {
1212
match get_pass_mode(tcx, dest_layout) {
13-
PassMode::NoPass | PassMode::ByVal(_) => true,
14-
// FIXME Make it possible to return ByValPair and ByRef to an ssa var.
15-
PassMode::ByValPair(_, _) | PassMode::ByRef { size: _ } => false,
13+
PassMode::NoPass | PassMode::ByVal(_) | PassMode::ByValPair(_, _) => true,
14+
// FIXME Make it possible to return ByRef to an ssa var.
15+
PassMode::ByRef { size: _ } => false,
1616
}
1717
}
1818

0 commit comments

Comments
 (0)