From 5b3a992f5d166007c3c5a22f120ed08e0a27f01a Mon Sep 17 00:00:00 2001 From: Dai Date: Fri, 14 Oct 2022 13:07:43 +0200 Subject: Add VecSlot for unboxed sums of SIMD vectors This patch adds the missing `VecRep` case to `primRepSlot` function and all the necessary machinery to carry this new `VecSlot` through code generation. This allows programs involving unboxed sums of SIMD vectors to be written and compiled. Fixes #22187 --- compiler/GHC/Stg/Unarise.hs | 2 ++ 1 file changed, 2 insertions(+) (limited to 'compiler/GHC/Stg/Unarise.hs') diff --git a/compiler/GHC/Stg/Unarise.hs b/compiler/GHC/Stg/Unarise.hs index 440b184d44..8dfdeb607c 100644 --- a/compiler/GHC/Stg/Unarise.hs +++ b/compiler/GHC/Stg/Unarise.hs @@ -694,6 +694,8 @@ ubxSumRubbishArg WordSlot = StgLitArg (LitNumber LitNumWord 0) ubxSumRubbishArg Word64Slot = StgLitArg (LitNumber LitNumWord64 0) ubxSumRubbishArg FloatSlot = StgLitArg (LitFloat 0) ubxSumRubbishArg DoubleSlot = StgLitArg (LitDouble 0) +ubxSumRubbishArg (VecSlot n e) = StgLitArg (LitRubbish vec_rep) + where vec_rep = primRepToRuntimeRep (VecRep n e) -------------------------------------------------------------------------------- -- cgit v1.2.1