Implement shufflevector builtin. (#36650)

This isn't _terribly_ useful as-is, because the only constant mask you can get at from Swift at present is the zeroinitializer, but even that is quite useful for optimizing the repeating: intializer on SIMD. At some future point we should wire up generating constant masks for the .even, .odd, .high and .low properties (and also eventually make shufflevector take non-constant masks in LLVM). But this is enough to be useful, so let's get it in.
This commit is contained in:
Stephen Canon
2021-04-04 23:23:53 -04:00
committed by GitHub
parent aedd3f27a3
commit 511b50e511
7 changed files with 52 additions and 2 deletions

View File

@@ -120,6 +120,7 @@ static bool isBarrier(SILInstruction *inst) {
case BuiltinValueKind::OnFastPath:
case BuiltinValueKind::ExtractElement:
case BuiltinValueKind::InsertElement:
case BuiltinValueKind::ShuffleVector:
case BuiltinValueKind::StaticReport:
case BuiltinValueKind::AssertConf:
case BuiltinValueKind::StringObjectOr: