diff --git a/parser-typechecker/src/Unison/Runtime/ANF.hs b/parser-typechecker/src/Unison/Runtime/ANF.hs index 135a8fa6b1..07cd4d1b9e 100644 --- a/parser-typechecker/src/Unison/Runtime/ANF.hs +++ b/parser-typechecker/src/Unison/Runtime/ANF.hs @@ -10,6 +10,7 @@ module Unison.Runtime.ANF ( minimizeCyclesOrCrash, pattern TVar, pattern TLit, + pattern TBLit, pattern TApp, pattern TApv, pattern TCom, @@ -43,6 +44,7 @@ module Unison.Runtime.ANF floatGroup, lamLift, lamLiftGroup, + litRef, inlineAlias, addDefaultCases, ANormalF (.., AApv, ACom, ACon, AKon, AReq, APrm, AFOp), @@ -668,6 +670,7 @@ data ANormalF v e = ALet (Direction Word16) [Mem] e e | AName (Either Reference v) [v] e | ALit Lit + | ABLit Lit -- direct boxed literal | AMatch v (Branched e) | AShift Reference e | AHnd [Reference] v e @@ -745,6 +748,7 @@ instance Num CTag where instance Functor (ANormalF v) where fmap _ (AVar v) = AVar v fmap _ (ALit l) = ALit l + fmap _ (ABLit l) = ABLit l fmap f (ALet d m bn bo) = ALet d m (f bn) (f bo) fmap f (AName n as bo) = AName n as $ f bo fmap f (AMatch v br) = AMatch v $ f <$> br @@ -756,6 +760,7 @@ instance Functor (ANormalF v) where instance Bifunctor ANormalF where bimap f _ (AVar v) = AVar (f v) bimap _ _ (ALit l) = ALit l + bimap _ _ (ABLit l) = ABLit l bimap _ g (ALet d m bn bo) = ALet d m (g bn) (g bo) bimap f g (AName n as bo) = AName (f <$> n) (f <$> as) $ g bo bimap f g (AMatch v br) = AMatch (f v) $ fmap g br @@ -767,6 +772,7 @@ instance Bifunctor ANormalF where instance Bifoldable ANormalF where bifoldMap f _ (AVar v) = f v bifoldMap _ _ (ALit _) = mempty + bifoldMap _ _ (ABLit _) = mempty bifoldMap _ g (ALet _ _ b e) = g b <> g e bifoldMap f g (AName n as e) = foldMap f n <> foldMap f as <> g e bifoldMap f g (AMatch v br) = f v <> foldMap g br @@ -779,6 +785,8 @@ instance ABTN.Align ANormalF where align f _ (AVar u) (AVar v) = Just $ AVar <$> f u v align _ _ (ALit l) (ALit r) | l == r = Just $ pure (ALit l) + align _ _ (ABLit l) (ABLit r) + | l == r = Just $ pure (ABLit l) align _ g (ALet dl ccl bl el) (ALet dr ccr br er) | dl == dr, ccl == ccr = @@ -886,6 +894,14 @@ alignBranch f (MatchSum bl) (MatchSum br) | keysSet bl == keysSet br, all (\w -> fst (bl ! w) == fst (br ! w)) (keys bl) = Just $ MatchSum <$> interverse (alignCCs f) bl br +alignBranch f (MatchNumeric rl bl dl) (MatchNumeric rr br dr) + | rl == rr, + keysSet bl == keysSet br, + Just ds <- alignMaybe f dl dr = + Just $ + MatchNumeric rl + <$> interverse f bl br + <*> ds alignBranch _ _ _ = Nothing alignCCs :: (Functor f) => (l -> r -> f s) -> (a, l) -> (a, r) -> f (a, s) @@ -946,6 +962,12 @@ pattern TLit :: ABTN.Term ANormalF v pattern TLit l = ABTN.TTm (ALit l) +pattern TBLit :: + (ABT.Var v) => + Lit -> + ABTN.Term ANormalF v +pattern TBLit l = ABTN.TTm (ABLit l) + pattern TApp :: (ABT.Var v) => Func v -> @@ -1110,6 +1132,10 @@ pattern TBinds ctx bd <- data SeqEnd = SLeft | SRight deriving (Eq, Ord, Enum, Show) +-- Note: MatchNumeric is a new form for matching directly on boxed +-- numeric data. This leaves MatchIntegral around so that builtins can +-- continue to use it. But interchanged code can be free of unboxed +-- details. data Branched e = MatchIntegral (EnumMap Word64 e) (Maybe e) | MatchText (Map.Map Util.Text.Text e) (Maybe e) @@ -1117,6 +1143,7 @@ data Branched e | MatchEmpty | MatchData Reference (EnumMap CTag ([Mem], e)) (Maybe e) | MatchSum (EnumMap Word64 ([Mem], e)) + | MatchNumeric Reference (EnumMap Word64 e) (Maybe e) deriving (Show, Eq, Functor, Foldable, Traversable) -- Data cases expected to cover all constructors @@ -1496,6 +1523,11 @@ data BLit | Quote Value | Code (SuperGroup Symbol) | BArr PA.ByteArray + | Pos Word64 + | Neg Word64 + | Char Char + | Float Double + | Arr (PA.Array Value) deriving (Show) groupVars :: ANFM v (Set v) @@ -1711,14 +1743,8 @@ anfBlock (Match' scrut cas) = do ) AccumText df cs -> pure (sctx <> cx, pure . TMatch v $ MatchText cs df) - AccumIntegral r df cs -> do - i <- fresh - let dcs = - MatchDataCover - r - (EC.mapSingleton 0 ([UN], ABTN.TAbss [i] ics)) - ics = TMatch i $ MatchIntegral cs df - pure (sctx <> cx, pure $ TMatch v dcs) + AccumIntegral r df cs -> + pure (sctx <> cx, pure $ TMatch v $ MatchNumeric r cs df) AccumData r df cs -> pure (sctx <> cx, pure . TMatch v $ MatchData r cs df) AccumSeqEmpty _ -> @@ -1747,21 +1773,22 @@ anfBlock (Match' scrut cas) = do AccumSeqSplit en n mdf bd -> do i <- fresh r <- fresh - n <- fresh + s <- fresh + b <- binder + let split = ST1 (Indirect b) r BX (TCom op [i, v]) pure - ( sctx <> cx <> directed [lit i, split i r], - pure . TMatch r . MatchSum $ + ( sctx <> cx <> directed [lit i, split], + pure . TMatch r . MatchDataCover Ty.seqViewRef $ mapFromList - [ (0, ([], df n)), - (1, ([BX, BX], bd)) + [ (fromIntegral Ty.seqViewEmpty, ([], df s)), + (fromIntegral Ty.seqViewElem, ([BX, BX], bd)) ] ) where op - | SLeft <- en = SPLL - | otherwise = SPLR - lit i = ST1 Direct i UN (TLit . N $ fromIntegral n) - split i r = ST1 Direct r UN (TPrm op [i, v]) + | SLeft <- en = Builtin "List.splitLeft" + | otherwise = Builtin "List.splitRight" + lit i = ST1 Direct i BX (TBLit . N $ fromIntegral n) df n = fromMaybe ( TLet Direct n BX (TLit (T "pattern match failure")) $ @@ -1802,12 +1829,8 @@ anfBlock (Boolean' b) = pure (mempty, pure $ TCon Ty.booleanRef (if b then 1 else 0) []) anfBlock (Lit' l@(T _)) = pure (mempty, pure $ TLit l) -anfBlock (Lit' l) = do - lv <- fresh - pure - ( directed [ST1 Direct lv UN $ TLit l], - pure $ TCon (litRef l) 0 [lv] - ) +anfBlock (Lit' l) = + pure (mempty, pure $ TBLit l) anfBlock (Ref' r) = pure (mempty, (Indirect (), TCom r [])) anfBlock (Blank' b) = do nm <- fresh @@ -2033,6 +2056,8 @@ branchLinks _ g (MatchText m e) = MatchText <$> traverse g m <*> traverse g e branchLinks _ g (MatchIntegral m e) = MatchIntegral <$> traverse g m <*> traverse g e +branchLinks _ g (MatchNumeric r m e) = + MatchNumeric r <$> traverse g m <*> traverse g e branchLinks _ g (MatchSum m) = MatchSum <$> (traverse . traverse) g m branchLinks _ _ MatchEmpty = pure MatchEmpty @@ -2252,6 +2277,9 @@ prettyBranches ind bs = case bs of (uncurry $ prettyCase ind . shows) id (mapToList $ snd <$> bs) + MatchNumeric _ bs df -> + maybe id (\e -> prettyCase ind (showString "_") e id) df + . foldr (uncurry $ prettyCase ind . shows) id (mapToList bs) -- _ -> error "prettyBranches: todo" where -- prettyReq :: Reference -> CTag -> ShowS diff --git a/parser-typechecker/src/Unison/Runtime/ANF/Serialize.hs b/parser-typechecker/src/Unison/Runtime/ANF/Serialize.hs index 2c09e07df0..4130f86a66 100644 --- a/parser-typechecker/src/Unison/Runtime/ANF/Serialize.hs +++ b/parser-typechecker/src/Unison/Runtime/ANF/Serialize.hs @@ -22,6 +22,7 @@ import Data.Word (Word16, Word32, Word64) import GHC.Stack import Unison.ABT.Normalized (Term (..)) import Unison.Reference (Reference, Reference' (Builtin), pattern Derived) +import Unison.Runtime.Array qualified as PA import Unison.Runtime.ANF as ANF hiding (Tag) import Unison.Runtime.Exception import Unison.Runtime.Serialize @@ -44,6 +45,7 @@ data TmTag | NameVarT | LetDirT | LetIndT + | BxLitT data FnTag = FVarT @@ -61,6 +63,7 @@ data MtTag | MEmptyT | MDataT | MSumT + | MNumT data LtTag = IT @@ -80,6 +83,11 @@ data BLTag | QuoteT | CodeT | BArrT + | PosT + | NegT + | CharT + | FloatT + | ArrT data VaTag = PartialT | DataT | ContT | BLitT @@ -98,6 +106,7 @@ instance Tag TmTag where NameVarT -> 9 LetDirT -> 10 LetIndT -> 11 + BxLitT -> 12 word2tag = \case 1 -> pure VarT 2 -> pure ForceT @@ -110,6 +119,7 @@ instance Tag TmTag where 9 -> pure NameVarT 10 -> pure LetDirT 11 -> pure LetIndT + 12 -> pure BxLitT n -> unknownTag "TmTag" n instance Tag FnTag where @@ -140,6 +150,7 @@ instance Tag MtTag where MEmptyT -> 3 MDataT -> 4 MSumT -> 5 + MNumT -> 6 word2tag = \case 0 -> pure MIntT @@ -148,6 +159,7 @@ instance Tag MtTag where 3 -> pure MEmptyT 4 -> pure MDataT 5 -> pure MSumT + 6 -> pure MNumT n -> unknownTag "MtTag" n instance Tag LtTag where @@ -180,6 +192,11 @@ instance Tag BLTag where QuoteT -> 5 CodeT -> 6 BArrT -> 7 + PosT -> 8 + NegT -> 9 + CharT -> 10 + FloatT -> 11 + ArrT -> 12 word2tag = \case 0 -> pure TextT @@ -190,6 +207,11 @@ instance Tag BLTag where 5 -> pure QuoteT 6 -> pure CodeT 7 -> pure BArrT + 8 -> pure PosT + 9 -> pure NegT + 10 -> pure CharT + 11 -> pure FloatT + 12 -> pure ArrT t -> unknownTag "BLTag" t instance Tag VaTag where @@ -353,6 +375,7 @@ putNormal refrep fops ctx tm = case tm of *> putVar ctx v *> putBranches refrep fops ctx bs TLit l -> putTag LitT *> putLit l + TBLit l -> putTag BxLitT *> putLit l TName v (Left r) as e -> putTag NameRefT *> pr @@ -393,6 +416,7 @@ getNormal ctx frsh0 = v = getFresh frsh0 MatchT -> TMatch <$> getVar ctx <*> getBranches ctx frsh0 LitT -> TLit <$> getLit + BxLitT -> TBLit <$> getLit NameRefT -> TName v . Left <$> getReference @@ -635,6 +659,11 @@ putBLit (Bytes b) = putTag BytesT *> putBytes b putBLit (Quote v) = putTag QuoteT *> putValue v putBLit (Code g) = putTag CodeT *> putGroup mempty mempty g putBLit (BArr a) = putTag BArrT *> putByteArray a +putBLit (Pos n) = putTag PosT *> putPositive n +putBLit (Neg n) = putTag NegT *> putPositive n +putBLit (Char c) = putTag CharT *> putChar c +putBLit (Float d) = putTag FloatT *> putFloat d +putBLit (Arr a) = putTag ArrT *> putFoldable putValue a getBLit :: (MonadGet m) => Version -> m BLit getBLit v = @@ -647,6 +676,11 @@ getBLit v = QuoteT -> Quote <$> getValue v CodeT -> Code <$> getGroup BArrT -> BArr <$> getByteArray + PosT -> Pos <$> getPositive + NegT -> Neg <$> getPositive + CharT -> Char <$> getChar + FloatT -> Float <$> getFloat + ArrT -> Arr . PA.fromList <$> getList (getValue v) putRefs :: (MonadPut m) => [Reference] -> m () putRefs rs = putFoldable putReference rs @@ -676,8 +710,6 @@ putBranches refrep fops ctx bs = case bs of putTag MReqT putMap putReference (putEnumMap putCTag (putCase refrep fops ctx)) m putNormal refrep fops (v : ctx) df - where - MatchData r m df -> do putTag MDataT putReference r @@ -686,6 +718,11 @@ putBranches refrep fops ctx bs = case bs of MatchSum m -> do putTag MSumT putEnumMap putWord64be (putCase refrep fops ctx) m + MatchNumeric r m df -> do + putTag MNumT + putReference r + putEnumMap putWord64be (putNormal refrep fops ctx) m + putMaybe df $ putNormal refrep fops ctx _ -> exn "putBranches: malformed intermediate term" getBranches :: @@ -713,6 +750,11 @@ getBranches ctx frsh0 = <*> getEnumMap getCTag (getCase ctx frsh0) <*> getMaybe (getNormal ctx frsh0) MSumT -> MatchSum <$> getEnumMap getWord64be (getCase ctx frsh0) + MNumT -> + MatchNumeric + <$> getReference + <*> getEnumMap getWord64be (getNormal ctx frsh0) + <*> getMaybe (getNormal ctx frsh0) putCase :: (MonadPut m) => @@ -746,77 +788,128 @@ putGroupRef (GR r i) = getGroupRef :: (MonadGet m) => m GroupRef getGroupRef = GR <$> getReference <*> getWord64be +-- Notes +-- +-- Starting with version 4 of the value format, it is expected that +-- unboxed data does not actually occur in the values being sent. For +-- most values this was not a problem: +-- +-- - Partial applications had no way of directly including unboxed +-- values, because they all result from surface level unison +-- applications +-- - Unboxed values in Data only occurred to represent certain +-- builtin types. Those have been replaced by BLits. +-- +-- However, some work was required to make sure no unboxed data ended +-- up in Cont. The runtime has been modified to avoid using the +-- unboxed stack in generated code, so now only builtins use it, +-- effectively. Since continuations are never captured inside builtins +-- (and even if we wanted to do that, we could arrange for a clean +-- unboxed stack), this is no longer a problem, either. +-- +-- So, unboxed data is completely absent from the format. We are now +-- exchanging unison surface values, effectively. putValue :: (MonadPut m) => Value -> m () -putValue (Partial gr ws vs) = +putValue (Partial gr [] vs) = putTag PartialT *> putGroupRef gr - *> putFoldable putWord64be ws *> putFoldable putValue vs -putValue (Data r t ws vs) = +putValue Partial {} = + exn "putValue: Partial with unboxed values no longer supported" +putValue (Data r t [] vs) = putTag DataT *> putReference r *> putWord64be t - *> putFoldable putWord64be ws *> putFoldable putValue vs -putValue (Cont us bs k) = +putValue Data {} = + exn "putValue: Data with unboxed contents no longer supported" +putValue (Cont [] bs k) = putTag ContT - *> putFoldable putWord64be us *> putFoldable putValue bs *> putCont k +putValue Cont {} = + exn "putValue: Cont with unboxed stack no longer supported" putValue (BLit l) = putTag BLitT *> putBLit l getValue :: (MonadGet m) => Version -> m Value getValue v = getTag >>= \case - PartialT -> - Partial <$> getGroupRef <*> getList getWord64be <*> getList (getValue v) - DataT -> - Data - <$> getReference - <*> getWord64be - <*> getList getWord64be - <*> getList (getValue v) - ContT -> Cont <$> getList getWord64be <*> getList (getValue v) <*> getCont v + PartialT + | v < 4 -> + Partial <$> getGroupRef <*> getList getWord64be <*> getList (getValue v) + | otherwise -> + flip Partial [] <$> getGroupRef <*> getList (getValue v) + DataT + | v < 4 -> + Data + <$> getReference + <*> getWord64be + <*> getList getWord64be + <*> getList (getValue v) + | otherwise -> + (\r t -> Data r t []) + <$> getReference + <*> getWord64be + <*> getList (getValue v) + ContT + | v < 4 -> + Cont <$> getList getWord64be <*> getList (getValue v) <*> getCont v + | otherwise -> Cont [] <$> getList (getValue v) <*> getCont v BLitT -> BLit <$> getBLit v putCont :: (MonadPut m) => Cont -> m () putCont KE = putTag KET -putCont (Mark ua ba rs ds k) = +putCont (Mark 0 ba rs ds k) = putTag MarkT - *> putWord64be ua *> putWord64be ba *> putFoldable putReference rs *> putMap putReference putValue ds *> putCont k -putCont (Push i j m n gr k) = +putCont Mark {} = + exn "putCont: Mark with unboxed args no longer supported" +putCont (Push 0 j 0 n gr k) = putTag PushT - *> putWord64be i *> putWord64be j - *> putWord64be m *> putWord64be n *> putGroupRef gr *> putCont k +putCont Push {} = + exn "putCont: Push with unboxed information no longer supported" getCont :: (MonadGet m) => Version -> m Cont getCont v = getTag >>= \case KET -> pure KE - MarkT -> - Mark - <$> getWord64be - <*> getWord64be - <*> getList getReference - <*> getMap getReference (getValue v) - <*> getCont v - PushT -> - Push - <$> getWord64be - <*> getWord64be - <*> getWord64be - <*> getWord64be - <*> getGroupRef - <*> getCont v + MarkT + | v < 4 -> + Mark + <$> getWord64be + <*> getWord64be + <*> getList getReference + <*> getMap getReference (getValue v) + <*> getCont v + | otherwise -> + Mark 0 + <$> getWord64be + <*> getList getReference + <*> getMap getReference (getValue v) + <*> getCont v + PushT + | v < 4 -> + Push + <$> getWord64be + <*> getWord64be + <*> getWord64be + <*> getWord64be + <*> getGroupRef + <*> getCont v + | otherwise -> + (\j n -> Push 0 j 0 n) + <$> getWord64be + <*> getWord64be + <*> getGroupRef + <*> getCont v deserializeGroup :: (Var v) => ByteString -> Either String (SuperGroup v) deserializeGroup bs = runGetS (getVersion *> getGroup) bs @@ -824,6 +917,7 @@ deserializeGroup bs = runGetS (getVersion *> getGroup) bs getVersion = getWord32be >>= \case 1 -> pure () + 2 -> pure () n -> fail $ "deserializeGroup: unknown version: " ++ show n serializeGroup :: @@ -874,7 +968,7 @@ deserializeValue bs = runGetS (getVersion >>= getValue) bs n | n < 1 -> fail $ "deserializeValue: unknown version: " ++ show n | n < 3 -> fail $ "deserializeValue: unsupported version: " ++ show n - | n == 3 -> pure n + | n <= 4 -> pure n | otherwise -> fail $ "deserializeValue: unknown version: " ++ show n serializeValue :: Value -> ByteString @@ -888,7 +982,7 @@ serializeValueLazy v = runPutLazy (putVersion *> putValue v) putVersion = putWord32be valueVersion valueVersion :: Word32 -valueVersion = 3 +valueVersion = 4 codeVersion :: Word32 -codeVersion = 1 +codeVersion = 2 diff --git a/parser-typechecker/src/Unison/Runtime/Builtin.hs b/parser-typechecker/src/Unison/Runtime/Builtin.hs index 6df7ec7193..581381e274 100644 --- a/parser-typechecker/src/Unison/Runtime/Builtin.hs +++ b/parser-typechecker/src/Unison/Runtime/Builtin.hs @@ -680,6 +680,27 @@ viewrs = unop0 3 $ \[s, u, i, l] -> (1, ([BX, BX], TAbss [i, l] $ seqViewElem i l)) ] +splitls, splitrs :: (Var v) => SuperNormal v +splitls = binop0 4 $ \[n0, s, n, t, l, r] -> + unbox n0 Ty.natRef n + . TLetD t UN (TPrm SPLL [n, s]) + . TMatch t + . MatchSum + $ mapFromList + [ (0, ([], seqViewEmpty)), + (1, ([BX, BX], TAbss [l, r] $ seqViewElem l r)) + ] + +splitrs = binop0 4 $ \[n0, s, n, t, l, r] -> + unbox n0 Ty.natRef n + . TLetD t UN (TPrm SPLR [n, s]) + . TMatch t + . MatchSum + $ mapFromList + [ (0, ([], seqViewEmpty)), + (1, ([BX, BX], TAbss [l, r] $ seqViewElem l r)) + ] + eqt, neqt, leqt, geqt, lesst, great :: SuperNormal Symbol eqt = binop0 1 $ \[x, y, b] -> TLetD b UN (TPrm EQLT [x, y]) $ @@ -906,21 +927,16 @@ watch = raise :: SuperNormal Symbol raise = - unop0 4 $ \[r, f, n, j, k] -> - TMatch r . flip (MatchData Ty.exceptionRef) Nothing $ - mapFromList - [ (0, ([BX], TAbs f $ TVar f)), - ( i, - ( [UN, BX], - TAbss [j, f] - . TShift Ty.exceptionRef k - . TLetD n BX (TLit $ T "builtin.raise") - $ TPrm EROR [n, f] - ) + unop0 3 $ \[r, f, n, k] -> + TMatch r . flip MatchRequest (TAbs f $ TVar f) + . Map.singleton Ty.exceptionRef + $ mapSingleton 0 + ( [BX], + TAbs f + . TShift Ty.exceptionRef k + . TLetD n BX (TLit $ T "builtin.raise") + $ TPrm EROR [n, f] ) - ] - where - i = fromIntegral $ builtinTypeNumbering Map.! Ty.exceptionRef gen'trace :: SuperNormal Symbol gen'trace = @@ -2126,6 +2142,8 @@ builtinLookup = ("List.empty", (Untracked, emptys)), ("List.viewl", (Untracked, viewls)), ("List.viewr", (Untracked, viewrs)), + ("List.splitLeft", (Untracked, splitls)), + ("List.splitRight", (Untracked, splitrs)), -- -- , B "Debug.watch" $ forall1 "a" (\a -> text --> a --> a) ("Universal.==", (Untracked, equ)), @@ -2444,10 +2462,10 @@ declareForeigns = do declareForeign Tracked "IO.stdHandle" standard'handle . mkForeign $ \(n :: Int) -> case n of - 0 -> pure (Just SYS.stdin) - 1 -> pure (Just SYS.stdout) - 2 -> pure (Just SYS.stderr) - _ -> pure Nothing + 0 -> pure SYS.stdin + 1 -> pure SYS.stdout + 2 -> pure SYS.stderr + _ -> die "IO.stdHandle: invalid input." let exitDecode ExitSuccess = 0 exitDecode (ExitFailure n) = n diff --git a/parser-typechecker/src/Unison/Runtime/MCode.hs b/parser-typechecker/src/Unison/Runtime/MCode.hs index 9e6cef5196..ecbbf7c80c 100644 --- a/parser-typechecker/src/Unison/Runtime/MCode.hs +++ b/parser-typechecker/src/Unison/Runtime/MCode.hs @@ -42,6 +42,7 @@ import Data.Bits (shiftL, shiftR, (.|.)) import Data.Coerce import Data.List (partition) import Data.Map.Strict qualified as M +import Data.Primitive.ByteArray import Data.Primitive.PrimArray import Data.Word (Word16, Word64) import GHC.Stack (HasCallStack) @@ -57,7 +58,6 @@ import Unison.Runtime.ANF Mem (..), SuperGroup (..), SuperNormal (..), - Tag (..), internalBug, packTags, pattern TApp, @@ -66,6 +66,7 @@ import Unison.Runtime.ANF pattern THnd, pattern TLets, pattern TLit, + pattern TBLit, pattern TMatch, pattern TName, pattern TPrm, @@ -486,6 +487,8 @@ data Instr !Int -- stack index of data to unpack | -- Push a particular value onto the appropriate stack Lit !MLit -- value to push onto the stack + | -- Push a particular value directly onto the boxed stack + BLit !Reference !MLit | -- Print a value on the unboxed stack Print !Int -- index of the primitive value to print | -- Put a delimiter on the continuation @@ -539,6 +542,23 @@ data Section | -- Immediately stop a thread of interpretation. This is more of -- a debugging tool than a proper operation to target. Exit + | -- Branch on a data type without dumping the tag onto the unboxed + -- stack. + DMatch + !(Maybe Reference) -- expected data type + !Int -- index of data item on boxed stack + !Branch -- branches + | -- Branch on a numeric type without dumping it to the stack + NMatch + !(Maybe Reference) -- expected data type + !Int -- index of data item on boxed stack + !Branch -- branches + | -- Branch on a request representation without dumping the tag + -- portion to the unboxed stack. + RMatch + !Int -- index of request item on the boxed stack + !Section -- pure case + !(EnumMap Word64 Branch) -- effect cases deriving (Show, Eq, Ord) data CombIx @@ -607,6 +627,10 @@ pattern MatchW i d cs = Match i (TestW d cs) pattern MatchT :: Int -> Section -> M.Map Text Section -> Section pattern MatchT i d cs = Match i (TestT d cs) +pattern NMatchW :: + Maybe Reference -> Int -> Section -> EnumMap Word64 Section -> Section +pattern NMatchW r i d cs = NMatch r i (TestW d cs) + -- Representation of the variable context available in the current -- frame. This tracks tags that have been dumped to the stack for -- proper indexing. The `Block` constructor is used to mark when we @@ -834,15 +858,17 @@ emitSection _ _ _ _ ctx (TLit l) = | ANF.LM {} <- l = addCount 0 1 | ANF.LY {} <- l = addCount 0 1 | otherwise = addCount 1 0 +emitSection _ _ _ _ ctx (TBLit l) = + addCount 0 1 . countCtx ctx . Ins (emitBLit l) . Yield $ BArg1 0 emitSection rns grpr grpn rec ctx (TMatch v bs) | Just (i, BX) <- ctxResolve ctx v, MatchData r cs df <- bs = - Ins (Unpack (Just r) i) + DMatch (Just r) i <$> emitDataMatching r rns grpr grpn rec ctx cs df | Just (i, BX) <- ctxResolve ctx v, MatchRequest hs0 df <- bs, hs <- mapFromList $ first (dnum rns) <$> M.toList hs0 = - Ins (Unpack Nothing i) + uncurry (RMatch i) <$> emitRequestMatching rns grpr grpn rec ctx hs df | Just (i, UN) <- ctxResolve ctx v, MatchIntegral cs df <- bs = @@ -857,6 +883,19 @@ emitSection rns grpr grpn rec ctx (TMatch v bs) i cs df + | Just (i, BX) <- ctxResolve ctx v, + MatchNumeric r cs df <- bs = + emitLitMatching + (NMatchW (Just r)) + "missing integral case" + rns + grpr + grpn + rec + ctx + i + cs + df | Just (i, BX) <- ctxResolve ctx v, MatchText cs df <- bs = emitLitMatching @@ -933,14 +972,12 @@ emitFunction rns _ _ _ (FReq r e) as = -- Currently implementing packed calling convention for abilities -- TODO ct is 16 bits, but a is 48 bits. This will be a problem if we have -- more than 2^16 types. - Ins (Lit (MI . fromIntegral $ rawTag e)) - . Ins (Pack r (packTags rt ct) (reqArgs as)) + Ins (Pack r (packTags rt e) as) . App True (Dyn a) $ BArg1 0 where a = dnum rns r rt = toEnum . fromIntegral $ a - ct = toEnum . fromIntegral $ a emitFunction _ _ _ ctx (FCont k) as | Just (i, BX) <- ctxResolve ctx k = Jump i as | Nothing <- ctxResolve ctx k = emitFunctionVErr k @@ -948,39 +985,6 @@ emitFunction _ _ _ ctx (FCont k) as emitFunction _ _ _ _ (FPrim _) _ = internalBug "emitFunction: impossible" --- Modify function arguments for packing into a request -reqArgs :: Args -> Args -reqArgs = \case - ZArgs -> UArg1 0 - UArg1 i -> UArg2 0 (i + 1) - UArg2 i j - | i == 0 && j == 1 -> UArgR 0 3 - | otherwise -> UArgN (fl [0, i + 1, j + 1]) - BArg1 i -> DArg2 0 i - BArg2 i j - | j == i + 1 -> DArgR 0 1 i 2 - | otherwise -> DArgN (fl [0]) (fl [i, j]) - DArg2 i j - | i == 0 -> DArgR 0 2 j 1 - | otherwise -> DArgN (fl [0, i + 1]) (fl [j]) - UArgR i l - | i == 0 -> UArgR 0 (l + 1) - | otherwise -> UArgN (fl $ [0] ++ Prelude.take l [i + 1 ..]) - BArgR i l -> DArgR 0 1 i l - DArgR ui ul bi bl - | ui == 0 -> DArgR 0 (ul + 1) bi bl - | otherwise -> - DArgN - (fl $ [0] ++ Prelude.take ul [ui + 1 ..]) - (fl $ Prelude.take bl [bi ..]) - UArgN us -> UArgN (fl $ [0] ++ fmap (+ 1) (tl us)) - BArgN bs -> DArgN (fl [0]) bs - DArgN us bs -> DArgN (fl $ [0] ++ fmap (+ 1) (tl us)) bs - DArgV i j -> DArgV i j - where - fl = primArrayFromList - tl = primArrayToList - countBlock :: Ctx v -> (Int, Int) countBlock = go 0 0 where @@ -996,6 +1000,7 @@ matchCallingError cc b = "(" ++ show cc ++ "," ++ brs ++ ")" | MatchData _ _ _ <- b = "MatchData" | MatchEmpty <- b = "MatchEmpty" | MatchIntegral _ _ <- b = "MatchIntegral" + | MatchNumeric _ _ _ <- b = "MatchNumeric" | MatchRequest _ _ <- b = "MatchRequest" | MatchSum _ <- b = "MatchSum" | MatchText _ _ <- b = "MatchText" @@ -1033,6 +1038,9 @@ emitLet :: Emit Section emitLet _ _ _ _ _ _ _ (TLit l) = fmap (Ins $ emitLit l) +emitLet _ _ _ _ _ _ _ (TBLit l) = + fmap (Ins $ emitBLit l) + -- emitLet rns grp _ _ _ ctx (TApp (FComb r) args) -- -- We should be able to tell if we are making a saturated call -- -- or not here. We aren't carrying the information here yet, though. @@ -1256,9 +1264,9 @@ emitDataMatching :: Ctx v -> EnumMap CTag ([Mem], ANormal v) -> Maybe (ANormal v) -> - Emit Section + Emit Branch emitDataMatching r rns grpr grpn rec ctx cs df = - MatchW 0 <$> edf <*> traverse (emitCase rns grpr grpn rec ctx) (coerce cs) + TestW <$> edf <*> traverse (emitCase rns grpr grpn rec ctx) (coerce cs) where -- Note: this is not really accurate. A default data case needs -- stack space corresponding to the actual data that shows up there. @@ -1297,14 +1305,12 @@ emitRequestMatching :: Ctx v -> EnumMap Word64 (EnumMap CTag ([Mem], ANormal v)) -> ANormal v -> - Emit Section -emitRequestMatching rns grpr grpn rec ctx hs df = MatchW 0 edf <$> tops + Emit (Section, EnumMap Word64 Branch) +emitRequestMatching rns grpr grpn rec ctx hs df = (,) <$> pur <*> tops where - tops = - mapInsert 0 - <$> emitCase rns grpr grpn rec ctx ([BX], df) - <*> traverse f (coerce hs) - f cs = MatchW 1 edf <$> traverse (emitCase rns grpr grpn rec ctx) cs + pur = emitCase rns grpr grpn rec ctx ([BX], df) + tops = traverse f (coerce hs) + f cs = TestW edf <$> traverse (emitCase rns grpr grpn rec ctx) cs edf = Die "unhandled ability" emitLitMatching :: @@ -1338,7 +1344,7 @@ emitCase :: ([Mem], ANormal v) -> Emit Section emitCase rns grpr grpn rec ctx (ccs, TAbss vs bo) = - emitSection rns grpr grpn rec (Tag $ pushCtx (zip vs ccs) ctx) bo + emitSection rns grpr grpn rec (pushCtx (zip vs ccs) ctx) bo emitSumCase :: (Var v) => @@ -1353,15 +1359,24 @@ emitSumCase :: emitSumCase rns grpr grpn rec ctx v (ccs, TAbss vs bo) = emitSection rns grpr grpn rec (sumCtx ctx v $ zip vs ccs) bo +litToMLit :: ANF.Lit -> MLit +litToMLit (ANF.I i) = MI $ fromIntegral i +litToMLit (ANF.N n) = MI $ fromIntegral n +litToMLit (ANF.C c) = MI $ fromEnum c +litToMLit (ANF.F d) = MD d +litToMLit (ANF.T t) = MT t +litToMLit (ANF.LM r) = MM r +litToMLit (ANF.LY r) = MY r + emitLit :: ANF.Lit -> Instr -emitLit l = Lit $ case l of - ANF.I i -> MI $ fromIntegral i - ANF.N n -> MI $ fromIntegral n - ANF.C c -> MI $ fromEnum c - ANF.F d -> MD d - ANF.T t -> MT t - ANF.LM r -> MM r - ANF.LY r -> MY r +emitLit = Lit . litToMLit + +doubleToInt :: Double -> Int +doubleToInt d = indexByteArray (byteArrayFromList [d]) 0 + +emitBLit :: ANF.Lit -> Instr +emitBLit l@(ANF.F d) = BLit (ANF.litRef l) (MI $ doubleToInt d) +emitBLit l = BLit (ANF.litRef l) (litToMLit l) -- Emits some fix-up code for calling functions. Some of the -- variables in scope come from the top-level let rec, but these @@ -1513,6 +1528,28 @@ prettySection ind sec = . prettyIx n Die s -> showString $ "Die " ++ s Exit -> showString "Exit" + DMatch _ i bs -> + showString "DMatch " + . shows i + . showString "\n" + . prettyBranches (ind + 1) bs + NMatch _ i bs -> + showString "NMatch " + . shows i + . showString "\n" + . prettyBranches (ind + 1) bs + RMatch i pu bs -> + showString "RMatch " + . shows i + . showString "\nPUR ->\n" + . prettySection (ind + 1) pu + . foldr (\p r -> rqc p . r) id (mapToList bs) + where + rqc (i , e) = + showString "\n" + . shows i + . showString " ->\n" + . prettyBranches (ind + 1) e prettyIx :: CombIx -> ShowS prettyIx (CIx _ c s) = diff --git a/parser-typechecker/src/Unison/Runtime/MCode/Serialize.hs b/parser-typechecker/src/Unison/Runtime/MCode/Serialize.hs index 7eb7935af6..2d1cabf8d3 100644 --- a/parser-typechecker/src/Unison/Runtime/MCode/Serialize.hs +++ b/parser-typechecker/src/Unison/Runtime/MCode/Serialize.hs @@ -36,6 +36,9 @@ data SectionT | LetT | DieT | ExitT + | DMatchT + | NMatchT + | RMatchT instance Tag SectionT where tag2word AppT = 0 @@ -47,6 +50,9 @@ instance Tag SectionT where tag2word LetT = 6 tag2word DieT = 7 tag2word ExitT = 8 + tag2word DMatchT = 9 + tag2word NMatchT = 10 + tag2word RMatchT = 11 word2tag 0 = pure AppT word2tag 1 = pure CallT @@ -57,6 +63,9 @@ instance Tag SectionT where word2tag 6 = pure LetT word2tag 7 = pure DieT word2tag 8 = pure ExitT + word2tag 9 = pure DMatchT + word2tag 10 = pure NMatchT + word2tag 11 = pure RMatchT word2tag i = unknownTag "SectionT" i putSection :: (MonadPut m) => Section -> m () @@ -78,6 +87,15 @@ putSection (Die s) = putTag DieT *> serialize s putSection Exit = putTag ExitT +putSection (DMatch mr i b) = + putTag DMatchT *> putMaybe mr putReference *> pInt i *> putBranch b +putSection (NMatch mr i b) = + putTag NMatchT *> putMaybe mr putReference *> pInt i *> putBranch b +putSection (RMatch i pu bs) = + putTag RMatchT + *> pInt i + *> putSection pu + *> putEnumMap pWord putBranch bs getSection :: (MonadGet m) => m Section getSection = @@ -91,6 +109,10 @@ getSection = LetT -> Let <$> getSection <*> getCombIx DieT -> Die <$> deserialize ExitT -> pure Exit + DMatchT -> DMatch <$> getMaybe getReference <*> gInt <*> getBranch + NMatchT -> NMatch <$> getMaybe getReference <*> gInt <*> getBranch + RMatchT -> + RMatch <$> gInt <*> getSection <*> getEnumMap gWord getBranch data InstrT = UPrim1T @@ -111,6 +133,7 @@ data InstrT | AtomicallyT | SeqT | TryForceT + | BLitT instance Tag InstrT where tag2word UPrim1T = 0 @@ -131,6 +154,7 @@ instance Tag InstrT where tag2word AtomicallyT = 15 tag2word SeqT = 16 tag2word TryForceT = 17 + tag2word BLitT = 18 word2tag 0 = pure UPrim1T word2tag 1 = pure UPrim2T @@ -150,6 +174,7 @@ instance Tag InstrT where word2tag 15 = pure AtomicallyT word2tag 16 = pure SeqT word2tag 17 = pure TryForceT + word2tag 18 = pure BLitT word2tag n = unknownTag "InstrT" n putInstr :: (MonadPut m) => Instr -> m () @@ -177,6 +202,8 @@ putInstr (Unpack mr i) = putTag UnpackT *> putMaybe mr putReference *> pInt i putInstr (Lit l) = putTag LitT *> putLit l +putInstr (BLit r l) = + putTag BLitT *> putReference r *> putLit l putInstr (Print i) = putTag PrintT *> pInt i putInstr (Reset s) = @@ -205,6 +232,7 @@ getInstr = PackT -> Pack <$> getReference <*> gWord <*> getArgs UnpackT -> Unpack <$> getMaybe getReference <*> gInt LitT -> Lit <$> getLit + BLitT -> BLit <$> getReference <*> getLit PrintT -> Print <$> gInt ResetT -> Reset <$> getEnumSet gWord ForkT -> Fork <$> gInt diff --git a/parser-typechecker/src/Unison/Runtime/Machine.hs b/parser-typechecker/src/Unison/Runtime/Machine.hs index f276c5fcd4..479c2790cb 100644 --- a/parser-typechecker/src/Unison/Runtime/Machine.hs +++ b/parser-typechecker/src/Unison/Runtime/Machine.hs @@ -15,6 +15,7 @@ import Control.Exception import Data.Bits import Data.Map.Strict qualified as M import Data.Ord (comparing) +import Data.Primitive.ByteArray qualified as BA import Data.Sequence qualified as Sq import Data.Set qualified as S import Data.Set qualified as Set @@ -238,6 +239,17 @@ unitValue = Enum Rf.unitRef unitTag lookupDenv :: Word64 -> DEnv -> Closure lookupDenv p denv = fromMaybe BlackHole $ EC.lookup p denv +buildLit :: Reference -> MLit -> Closure +buildLit rf (MI i) + | Just n <- M.lookup rf builtinTypeNumbering, + rt <- toEnum (fromIntegral n) = + DataU1 rf (packTags rt 0) i + | otherwise = error "buildLit: unknown reference" +buildLit _ (MT t) = Foreign (Wrap Rf.textRef t) +buildLit _ (MM r) = Foreign (Wrap Rf.termLinkRef r) +buildLit _ (MY r) = Foreign (Wrap Rf.typeLinkRef r) +buildLit _ (MD _) = error "buildLit: double" + exec :: CCache -> DEnv -> @@ -453,6 +465,10 @@ exec !_ !denv !_activeThreads !ustk !bstk !k _ (Lit (MY r)) = do bstk <- bump bstk poke bstk (Foreign (Wrap Rf.typeLinkRef r)) pure (denv, ustk, bstk, k) +exec !_ !denv !_activeThreads !ustk !bstk !k _ (BLit rf l) = do + bstk <- bump bstk + poke bstk $ buildLit rf l + pure (denv, ustk, bstk, k) exec !_ !denv !_activeThreads !ustk !bstk !k _ (Reset ps) = do (ustk, ua) <- saveArgs ustk (bstk, ba) <- saveArgs bstk @@ -528,6 +544,14 @@ encodeExn ustk bstk (Left exn) = do (Rf.threadKilledFailureRef, disp ie, unitValue) | otherwise = (Rf.miscFailureRef, disp exn, unitValue) +numValue :: Maybe Reference -> Closure -> IO Word64 +numValue _ (DataU1 _ _ i) = pure (fromIntegral i) +numValue mr clo = + die $ + "numValue: bad closure: " + ++ show clo + ++ maybe "" (\r -> "\nexpected type: " ++ show r) mr + eval :: CCache -> DEnv -> @@ -544,6 +568,22 @@ eval !env !denv !activeThreads !ustk !bstk !k r (Match i (TestT df cs)) = do eval !env !denv !activeThreads !ustk !bstk !k r (Match i br) = do n <- peekOffN ustk i eval env denv activeThreads ustk bstk k r $ selectBranch n br +eval !env !denv !activeThreads !ustk !bstk !k r (DMatch mr i br) = do + (t, ustk, bstk) <- dumpDataNoTag mr ustk bstk =<< peekOff bstk i + eval env denv activeThreads ustk bstk k r $ + selectBranch (maskTags t) br +eval !env !denv !activeThreads !ustk !bstk !k r (NMatch mr i br) = do + n <- numValue mr =<< peekOff bstk i + eval env denv activeThreads ustk bstk k r $ selectBranch n br +eval !env !denv !activeThreads !ustk !bstk !k r (RMatch i pu br) = do + (t, ustk, bstk) <- dumpDataNoTag Nothing ustk bstk =<< peekOff bstk i + if t == 0 + then eval env denv activeThreads ustk bstk k r pu + else case ANF.unpackTags t of + (ANF.rawTag -> e, ANF.rawTag -> t) + | Just ebs <- EC.lookup e br -> + eval env denv activeThreads ustk bstk k r $ selectBranch t ebs + | otherwise -> unhandledErr "eval" env e eval !env !denv !activeThreads !ustk !bstk !k _ (Yield args) | asize ustk + asize bstk > 0, BArg1 i <- args = @@ -889,6 +929,50 @@ buildData !ustk !bstk !r !t (DArgV ui bi) = do bl = fsize bstk - bi {-# INLINE buildData #-} +-- Dumps a data type closure to the stack without writing its tag. +-- Instead, the tag is returned for direct case analysis. +dumpDataNoTag :: + Maybe Reference -> + Stack 'UN -> + Stack 'BX -> + Closure -> + IO (Word64, Stack 'UN, Stack 'BX) +dumpDataNoTag !_ !ustk !bstk (Enum _ t) = pure (t, ustk, bstk) +dumpDataNoTag !_ !ustk !bstk (DataU1 _ t x) = do + ustk <- bump ustk + poke ustk x + pure (t, ustk, bstk) +dumpDataNoTag !_ !ustk !bstk (DataU2 _ t x y) = do + ustk <- bumpn ustk 2 + pokeOff ustk 1 y + poke ustk x + pure (t, ustk, bstk) +dumpDataNoTag !_ !ustk !bstk (DataB1 _ t x) = do + bstk <- bump bstk + poke bstk x + pure (t, ustk, bstk) +dumpDataNoTag !_ !ustk !bstk (DataB2 _ t x y) = do + bstk <- bumpn bstk 2 + pokeOff bstk 1 y + poke bstk x + pure (t, ustk, bstk) +dumpDataNoTag !_ !ustk !bstk (DataUB _ t x y) = do + ustk <- bump ustk + bstk <- bump bstk + poke ustk x + poke bstk y + pure (t, ustk, bstk) +dumpDataNoTag !_ !ustk !bstk (DataG _ t us bs) = do + ustk <- dumpSeg ustk us S + bstk <- dumpSeg bstk bs S + pure (t, ustk, bstk) +dumpDataNoTag !mr !_ !_ clo = + die $ + "dumpDataNoTag: bad closure: " + ++ show clo + ++ maybe "" (\r -> "\nexpected type: " ++ show r) mr +{-# INLINE dumpDataNoTag #-} + dumpData :: Maybe Reference -> Stack 'UN -> @@ -1805,12 +1889,15 @@ resolve env _ _ (Env n i) = resolve _ _ bstk (Stk i) = peekOff bstk i resolve env denv _ (Dyn i) = case EC.lookup i denv of Just clo -> pure clo - Nothing -> readTVarIO (tagRefs env) >>= err - where - unhandled rs = case EC.lookup i rs of - Just r -> show r - Nothing -> show i - err rs = die $ "resolve: unhandled ability request: " ++ unhandled rs + Nothing -> unhandledErr "resolve" env i + +unhandledErr :: String -> CCache -> Word64 -> IO a +unhandledErr fname env i = + readTVarIO (tagRefs env) >>= \rs -> case EC.lookup i rs of + Just r -> bomb (show r) + Nothing -> bomb (show i) + where + bomb sh = die $ fname ++ ": unhandled ability request: " ++ sh combSection :: (HasCallStack) => CCache -> CombIx -> IO Comb combSection env (CIx _ n i) = @@ -1994,6 +2081,7 @@ reflectValue rty = goV goV (PApV cix ua ba) = ANF.Partial (goIx cix) (fromIntegral <$> ua) <$> traverse goV ba + goV (DataC _ t [w] []) = ANF.BLit <$> reflectUData t w goV (DataC r t us bs) = ANF.Data r (maskTags t) (fromIntegral <$> us) <$> traverse goV bs goV (CapV k _ _ us bs) = @@ -2033,8 +2121,19 @@ reflectValue rty = goV pure (ANF.Code g) | Just a <- maybeUnwrapForeign Rf.ibytearrayRef f = pure (ANF.BArr a) + | Just a <- maybeUnwrapForeign Rf.iarrayRef f = + ANF.Arr <$> traverse goV a | otherwise = die $ err $ "foreign value: " <> (show f) + reflectUData :: Word64 -> Int -> IO ANF.BLit + reflectUData t v + | t == natTag = pure $ ANF.Pos (fromIntegral v) + | t == charTag = pure $ ANF.Char (toEnum v) + | t == intTag, v >= 0 = pure $ ANF.Pos (fromIntegral v) + | t == intTag, v < 0 = pure $ ANF.Neg (fromIntegral (-v)) + | t == floatTag = pure $ ANF.Float (intToDouble v) + | otherwise = die . err $ "unboxed data: " <> show (t, v) + reifyValue :: CCache -> ANF.Value -> IO (Either [Reference] Closure) reifyValue cc val = do erc <- @@ -2108,6 +2207,20 @@ reifyValue0 (rty, rtm) = goV goL (ANF.Quote v) = pure . Foreign $ Wrap Rf.valueRef v goL (ANF.Code g) = pure . Foreign $ Wrap Rf.codeRef g goL (ANF.BArr a) = pure . Foreign $ Wrap Rf.ibytearrayRef a + goL (ANF.Char c) = pure $ DataU1 Rf.charRef charTag (fromEnum c) + goL (ANF.Pos w) = + pure $ DataU1 Rf.natRef natTag (fromIntegral w) + goL (ANF.Neg w) = + pure $ DataU1 Rf.intRef intTag (-fromIntegral w) + goL (ANF.Float d) = + pure $ DataU1 Rf.floatRef floatTag (doubleToInt d) + goL (ANF.Arr a) = Foreign . Wrap Rf.iarrayRef <$> traverse goV a + +doubleToInt :: Double -> Int +doubleToInt d = indexByteArray (BA.byteArrayFromList [d]) 0 + +intToDouble :: Int -> Double +intToDouble w = indexByteArray (BA.byteArrayFromList [w]) 0 -- Universal comparison functions @@ -2126,6 +2239,8 @@ universalEq :: universalEq frn = eqc where eql cm l r = length l == length r && and (zipWith cm l r) + eqc (DataC _ ct1 [w1] []) (DataC _ ct2 [w2] []) = + matchTags ct1 ct2 && w1 == w2 eqc (DataC _ ct1 us1 bs1) (DataC _ ct2 us2 bs2) = ct1 == ct2 && eql (==) us1 us2 @@ -2150,6 +2265,13 @@ universalEq frn = eqc | otherwise = frn fl fr eqc c d = closureNum c == closureNum d + -- serialization doesn't necessarily preserve Int tags, so be + -- more accepting for those. + matchTags ct1 ct2 = + ct1 == ct2 + || (ct1 == intTag && ct2 == natTag) + || (ct1 == natTag && ct2 == intTag) + arrayEq :: (Closure -> Closure -> Bool) -> PA.Array Closure -> PA.Array Closure -> Bool arrayEq eqc l r | PA.sizeofArray l /= PA.sizeofArray r = False @@ -2211,6 +2333,13 @@ natTag packTags rt 0 | otherwise = error "internal error: natTag" +intTag :: Word64 +intTag + | Just n <- M.lookup Rf.intRef builtinTypeNumbering, + rt <- toEnum (fromIntegral n) = + packTags rt 0 + | otherwise = error "internal error: intTag" + charTag :: Word64 charTag | Just n <- M.lookup Rf.charRef builtinTypeNumbering, @@ -2235,8 +2364,10 @@ universalCompare frn = cmpc False cmpl cm l r = compare (length l) (length r) <> fold (zipWith cm l r) cmpc _ (DataC _ ct1 [i] []) (DataC _ ct2 [j] []) - | ct1 == floatTag && ct2 == floatTag = compareAsFloat i j - | ct1 == natTag && ct2 == natTag = compareAsNat i j + | ct1 == floatTag, ct2 == floatTag = compareAsFloat i j + | ct1 == natTag, ct2 == natTag = compareAsNat i j + | ct1 == intTag, ct2 == natTag = compare i j + | ct1 == natTag, ct2 == intTag = compare i j cmpc tyEq (DataC rf1 ct1 us1 bs1) (DataC rf2 ct2 us2 bs2) = (if tyEq && ct1 /= ct2 then compare rf1 rf2 else EQ) <> compare (maskTags ct1) (maskTags ct2) diff --git a/parser-typechecker/src/Unison/Runtime/Serialize.hs b/parser-typechecker/src/Unison/Runtime/Serialize.hs index 2e43eff276..31e518a251 100644 --- a/parser-typechecker/src/Unison/Runtime/Serialize.hs +++ b/parser-typechecker/src/Unison/Runtime/Serialize.hs @@ -72,6 +72,16 @@ putFloat = serializeBE getFloat :: (MonadGet m) => m Double getFloat = deserializeBE +putBool :: (MonadPut m) => Bool -> m () +putBool b = putWord8 (if b then 1 else 0) + +getBool :: (MonadGet m) => m Bool +getBool = d =<< getWord8 + where + d 0 = pure False + d 1 = pure True + d n = exn $ "getBool: bad tag: " ++ show n + putNat :: (MonadPut m) => Word64 -> m () putNat = putWord64be @@ -105,6 +115,40 @@ getLength :: m n getLength = unVarInt <$> deserialize +-- Checks for negatives, in case you put an Integer, which does not +-- behave properly for negative numbers. +putPositive :: + MonadPut m => + Bits n => + Bits (Unsigned n) => + Integral n => + Integral (Unsigned n) => + n -> + m () +putPositive n + | n < 0 = exn $ "putPositive: negative number: " ++ show (toInteger n) + | otherwise = serialize (VarInt n) + +-- Reads as an Integer, then checks that the result will fit in the +-- result type. +getPositive :: + forall m n. + Bounded n => + Integral n => + MonadGet m => + m n +getPositive = validate . unVarInt =<< deserialize + where + mx0 :: n + mx0 = maxBound + mx :: Integer + mx = fromIntegral mx0 + + validate :: Integer -> m n + validate n + | n <= mx = pure $ fromIntegral n + | otherwise = fail $ "getPositive: overflow: " ++ show n + putFoldable :: (Foldable f, MonadPut m) => (a -> m ()) -> f a -> m () putFoldable putA as = do diff --git a/parser-typechecker/tests/Unison/Test/ANF.hs b/parser-typechecker/tests/Unison/Test/ANF.hs index c3340f123c..9e2aa9c4b6 100644 --- a/parser-typechecker/tests/Unison/Test/ANF.hs +++ b/parser-typechecker/tests/Unison/Test/ANF.hs @@ -59,16 +59,19 @@ testLift s = case cs of !_ -> ok . lamLift mempty $ tm s +denormalizeLit :: (Var v) => Lit -> Term.Term0 v +denormalizeLit (I i) = Term.int () i +denormalizeLit (N n) = Term.nat () n +denormalizeLit (F f) = Term.float () f +denormalizeLit (T t) = Term.text () (Util.Text.toText t) +denormalizeLit (C c) = Term.char () c +denormalizeLit (LM r) = Term.termLink () r +denormalizeLit (LY r) = Term.typeLink () r + denormalize :: (Var v) => ANormal v -> Term.Term0 v denormalize (TVar v) = Term.var () v -denormalize (TLit l) = case l of - I i -> Term.int () i - N n -> Term.nat () n - F f -> Term.float () f - T t -> Term.text () (Util.Text.toText t) - C c -> Term.char () c - LM r -> Term.termLink () r - LY r -> Term.typeLink () r +denormalize (TLit l) = denormalizeLit l +denormalize (TBLit l) = denormalizeLit l denormalize (THnd _ _ _) = error "denormalize handler" -- = Term.match () (denormalize b) $ denormalizeHandler h @@ -131,6 +134,8 @@ denormalizeMatch b | MatchData r m df <- b = (dcase (dpat r) . fmap snd <$> mapToList m) ++ dfcase df | MatchRequest hs df <- b = denormalizeHandler hs df + | MatchNumeric _ cs df <- b = + (dcase (ipat @Word64 @Integer Ty.intRef) <$> mapToList cs) ++ dfcase df | MatchSum _ <- b = error "MatchSum not a compilation target" where dfcase (Just d) = diff --git a/scheme-libs/racket/unison/primops-generated.rkt b/scheme-libs/racket/unison/primops-generated.rkt index d4ea0cd16f..ef7946c246 100644 --- a/scheme-libs/racket/unison/primops-generated.rkt +++ b/scheme-libs/racket/unison/primops-generated.rkt @@ -210,12 +210,17 @@ [(unison-data _ t (list l)) (cond [(= t unison-vlit-bytes:tag) l] + [(= t unison-vlit-char:tag) l] [(= t unison-vlit-bytearray:tag) l] [(= t unison-vlit-text:tag) l] - [(= t unison-vlit-typelink:tag) (reference->typelink l)] [(= t unison-vlit-termlink:tag) (referent->termlink l)] - [(= t unison-vlit-code:tag) (unison-code l)] + [(= t unison-vlit-typelink:tag) (reference->typelink l)] + [(= t unison-vlit-float:tag) l] + [(= t unison-vlit-pos:tag) l] + [(= t unison-vlit-neg:tag) (- l)] [(= t unison-vlit-quote:tag) (unison-quote l)] + [(= t unison-vlit-code:tag) (unison-code l)] + [(= t unison-vlit-array:tag) (vector-map reify-value l)] [(= t unison-vlit-seq:tag) ; TODO: better map over chunked list (vector->chunked-list @@ -225,33 +230,19 @@ (define (reify-value v) (match v - [(unison-data _ t (list rf rt us0 bs0)) + [(unison-data _ t (list rf rt bs0)) #:when (= t unison-value-data:tag) - (let ([us (chunked-list->list us0)] - [bs (map reify-value (chunked-list->list bs0))]) - (cond - [(null? us) (make-data (reference->typelink rf) rt bs)] - [(and (null? bs) (= 1 (length us))) (car us)] - [else - (raise - (format - "reify-value: unimplemented data case: ~a" - (describe-value v)))]))] - [(unison-data _ t (list gr us0 bs0)) + (let ([bs (map reify-value (chunked-list->list bs0))]) + (make-data (reference->typelink rf) rt bs))] + [(unison-data _ t (list gr bs0)) #:when (= t unison-value-partial:tag) - (let ([us (chunked-list->list us0)] - [bs (map reify-value (chunked-list->list bs0))]) - (cond - [(null? us) - (let ([proc (resolve-proc gr)]) - (apply proc bs))] - [else - (raise - "reify-value: unimplemented partial application case")]))] + (let ([bs (map reify-value (chunked-list->list bs0))] + [proc (resolve-proc gr)]) + (apply proc bs))] [(unison-data _ t (list vl)) #:when (= t unison-value-vlit:tag) (reify-vlit vl)] - [(unison-data _ t (list us0 bs0 k)) + [(unison-data _ t (list bs0 k)) #:when (= t unison-value-cont:tag) (raise "reify-value: unimplemented cont case")] [(unison-data r t fs) @@ -287,16 +278,22 @@ (define (reflect-value v) (match v - [(? number?) - (unison-value-data - (number-reference v) - 0 - (list->chunked-list (list v)) - empty-chunked-list)] + [(? exact-nonnegative-integer?) + (unison-value-vlit (unison-vlit-pos v))] + [(? exact-integer?) + (unison-value-vlit (unison-vlit-neg (- v)))] + [(? inexact-real?) + (unison-value-vlit (unison-vlit-float v))] + [(? char?) + (unison-value-vlit (unison-vlit-char v))] [(? chunked-bytes?) (unison-value-vlit (unison-vlit-bytes v))] [(? bytes?) (unison-value-vlit (unison-vlit-bytearray v))] + [(? vector?) + (unison-value-vlit + (unison-vlit-array + (vector-map reflect-value v)))] [(? chunked-string?) (unison-value-vlit (unison-vlit-text v))] ; TODO: better map over chunked lists @@ -314,18 +311,15 @@ [(unison-closure f as) (unison-value-partial (function->groupref f) - empty-chunked-list (list->chunked-list (map reflect-value as)))] [(? procedure?) (unison-value-partial (function->groupref v) - empty-chunked-list empty-chunked-list)] [(unison-data rf t fs) (unison-value-data (reflect-typelink rf) t - empty-chunked-list (list->chunked-list (map reflect-value fs)))])) ; replacment for Value.unsafeValue : a -> Value diff --git a/scheme-libs/racket/unison/primops.ss b/scheme-libs/racket/unison/primops.ss index be1cee3e83..cf8bd3a2cb 100644 --- a/scheme-libs/racket/unison/primops.ss +++ b/scheme-libs/racket/unison/primops.ss @@ -53,6 +53,9 @@ builtin-Bytes.indexOf builtin-IO.randomBytes + builtin-List.splitLeft + builtin-List.splitRight + builtin-Value.toBuiltin builtin-Value.fromBuiltin builtin-Code.fromGroup @@ -464,6 +467,16 @@ (define-unison (builtin-IO.randomBytes n) (bytes->chunked-bytes (crypto-random-bytes n))) + (define-unison (builtin-List.splitLeft n s) + (match (unison-POp-SPLL n s) + [(unison-sum 0 fs) (unison-seqview-empty)] + [(unison-sum 1 (list l r)) (unison-seqview-elem l r)])) + + (define-unison (builtin-List.splitRight n s) + (match (unison-POp-SPLR n s) + [(unison-sum 0 fs) (unison-seqview-empty)] + [(unison-sum 1 (list l r)) (unison-seqview-elem l r)])) + (define (unison-POp-UPKB bs) (build-chunked-list (chunked-bytes-length bs) diff --git a/unison-cli/src/Unison/JitInfo.hs b/unison-cli/src/Unison/JitInfo.hs index e178503089..d09f6fda46 100644 --- a/unison-cli/src/Unison/JitInfo.hs +++ b/unison-cli/src/Unison/JitInfo.hs @@ -1,4 +1,4 @@ module Unison.JitInfo (currentRelease) where currentRelease :: String -currentRelease = "releases/0.0.3" +currentRelease = "releases/0.0.5" diff --git a/unison-src/builtin-tests/array-tests.u b/unison-src/builtin-tests/array-tests.u index b1f9b81d2f..abe6349c96 100644 --- a/unison-src/builtin-tests/array-tests.u +++ b/unison-src/builtin-tests/array-tests.u @@ -50,6 +50,14 @@ boxarrTests = do checkEqual "boxed immutable copied" (Raw.read iarr2 0) "hello" + bs = Value.serialize (Value.value iarr2) + match Value.deserialize bs with + Left err -> fail "boxed serial" err + Right v -> match Value.load v with + Left missing -> fail "boxed serial" "missing deps" + Right ia -> checkEqual "boxed serial" iarr2 ia + + bytearrTests : '{IO,Exception,Tests} () bytearrTests = do iarr = ByteArray.Raw.new! 32 (marr -> let diff --git a/unison-src/builtin-tests/serial-tests.u b/unison-src/builtin-tests/serial-tests.u index 27fa9c3275..c04afc48d5 100644 --- a/unison-src/builtin-tests/serial-tests.u +++ b/unison-src/builtin-tests/serial-tests.u @@ -9,10 +9,10 @@ serial.availableCases _ = use List map p = cases (FilePath nm) -> contains ".ser" nm slice = cases (FilePath nm) -> - Text.take (Text.size nm - 4) nm + Text.take (Text.size nm - 7) nm -- caseNums = ["00", "01", "02", "03"] caseNums = ["00", "02"] - files = map (n -> FilePath ("case-" ++ n ++ ".ser")) caseNums + files = map (n -> FilePath ("case-" ++ n ++ ".v4.ser")) caseNums map slice (filter p files) serial.gen : Nat -> Nat -> (Nat, Nat) @@ -94,9 +94,9 @@ serial.loadSelfContained name path = serial.runTestCase : Text ->{Tests,IO} () serial.runTestCase name = - sfile = directory <+> FilePath (name ++ ".ser") + sfile = directory <+> FilePath (name ++ ".v4.ser") ofile = directory <+> FilePath (name ++ ".out") - hfile = directory <+> FilePath (name ++ ".hash") + hfile = directory <+> FilePath (name ++ ".v4.hash") handle p@(f, i) = loadSelfContained name sfile diff --git a/unison-src/transcripts-using-base/all-base-hashes.output.md b/unison-src/transcripts-using-base/all-base-hashes.output.md index 3dae7715de..3e6e7006cd 100644 --- a/unison-src/transcripts-using-base/all-base-hashes.output.md +++ b/unison-src/transcripts-using-base/all-base-hashes.output.md @@ -2698,180 +2698,184 @@ This transcript is intended to make visible accidental changes to the hashing al 773. -- #o1gssqn32qvl4pa79a0lko5ksvbn0rtv8u5g9jpd73ig94om2r4nlbcqa4nd968q74ios37eg0ol36776praolimpch8jsbohg47j2o List.forEach : [a] -> (a ->{e} ()) ->{e} () - 774. -- #marlqbcbculvqjfro3iidf899g2ncob2f8ld3gosg7kas5t9hlh341d49uh57ff5litvrt0hlb2ms7tj0mkfqs9do67cm4msodt8dng + 774. -- #atruig2897q7u699k1u4ruou8epfb9qsok7ojkm5om67fhhaqgdi597jr7dvr09h9qndupc49obo4cccir98ei1grfehrcd5qhnkcq0 + List.range : Nat -> Nat -> [Nat] + + 775. -- #marlqbcbculvqjfro3iidf899g2ncob2f8ld3gosg7kas5t9hlh341d49uh57ff5litvrt0hlb2ms7tj0mkfqs9do67cm4msodt8dng List.reverse : [a] -> [a] - 775. -- #30hfqasco93u0oipi7irfoabh5uofuu2aeplo2c87p4dg0386si6gvv715dbr21s4ftfquev4baj5ost3h17mt8fajn64mbffp6c8c0 + 776. -- #30hfqasco93u0oipi7irfoabh5uofuu2aeplo2c87p4dg0386si6gvv715dbr21s4ftfquev4baj5ost3h17mt8fajn64mbffp6c8c0 List.unzip : [(a, b)] -> ([a], [b]) - 776. -- #s8l7maltpsr01naqadvs5ssttg7eim4ca2096lbo3f3he1i1b11kk95ahtgb5ukb8cjr6kg4r4c1qrvshk9e8dp5fkq87254gc1pk48 + 777. -- #s8l7maltpsr01naqadvs5ssttg7eim4ca2096lbo3f3he1i1b11kk95ahtgb5ukb8cjr6kg4r4c1qrvshk9e8dp5fkq87254gc1pk48 List.zip : [a] -> [b] -> [(a, b)] - 777. -- #g6g6lhj9upe46032doaeo0ndu8lh1krfkc56gvupeg4a16me5vghhi6bthphnsvgtve9ogl73qab6d69ju6uorpj029g97pjg3p2k2o + 778. -- #g6g6lhj9upe46032doaeo0ndu8lh1krfkc56gvupeg4a16me5vghhi6bthphnsvgtve9ogl73qab6d69ju6uorpj029g97pjg3p2k2o listen : Socket ->{IO, Exception} () - 778. -- #ilva5f9uoaia9l8suc3hl9kh2bg1lah1k7uvm8mlq3mt0b9krdh15kurbhb9pu7a8irmvk6m2lpulg75a5alf0a95u0rp0v0n9folmg + 779. -- #ilva5f9uoaia9l8suc3hl9kh2bg1lah1k7uvm8mlq3mt0b9krdh15kurbhb9pu7a8irmvk6m2lpulg75a5alf0a95u0rp0v0n9folmg loadCodeBytes : Bytes ->{Exception} Code - 779. -- #tjj9c7fbprd57jlnndl8huslhvfbhi1bt1mr45v1fvvr2b3bguhnjtll3lbsbnqqjb290tm9cnuafpbtlfev1csbtjjog0r2kfv0e50 + 780. -- #tjj9c7fbprd57jlnndl8huslhvfbhi1bt1mr45v1fvvr2b3bguhnjtll3lbsbnqqjb290tm9cnuafpbtlfev1csbtjjog0r2kfv0e50 loadSelfContained : Text ->{IO, Exception} a - 780. -- #1pkgu9vbcdl57d9pn9ses1htmfokjq6212ed5oo9jscjkf8t2s407j71287hd9nr1shgsjmn0eunm5e7h262id4hh3t4op6barrvc70 + 781. -- #1pkgu9vbcdl57d9pn9ses1htmfokjq6212ed5oo9jscjkf8t2s407j71287hd9nr1shgsjmn0eunm5e7h262id4hh3t4op6barrvc70 loadValueBytes : Bytes ->{IO, Exception} ([(Link.Term, Code)], Value) - 781. -- #nqodnhhovq1ilb5fstpc61l8omfto62r8s0qq8s4ij39ulorqpgtinef64mullq0ns4914gck6obeuu6so1hds09hh5o1ptpt4k909g + 782. -- #nqodnhhovq1ilb5fstpc61l8omfto62r8s0qq8s4ij39ulorqpgtinef64mullq0ns4914gck6obeuu6so1hds09hh5o1ptpt4k909g MVar.put : MVar i -> i ->{IO, Exception} () - 782. -- #4ck8hqiu4m7478q5p7osqd1g9piie53g2v6j89en9s90f3cnhb9jr2515f35605e18ohiod7nb93t03765cil0lecob3hcsht9870g0 + 783. -- #4ck8hqiu4m7478q5p7osqd1g9piie53g2v6j89en9s90f3cnhb9jr2515f35605e18ohiod7nb93t03765cil0lecob3hcsht9870g0 MVar.read : MVar o ->{IO, Exception} o - 783. -- #tchse01rs4t1e6bk9br5ofad23ahlb9eanlv9nqqlk5eh7rv7qtpd5jmdjrcksm1q3uji64kqblrqq0vgap9tmak3urkr3ok4kg2ci0 + 784. -- #tchse01rs4t1e6bk9br5ofad23ahlb9eanlv9nqqlk5eh7rv7qtpd5jmdjrcksm1q3uji64kqblrqq0vgap9tmak3urkr3ok4kg2ci0 MVar.swap : MVar o -> o ->{IO, Exception} o - 784. -- #23nq5mshk51uktsg3su3mnkr9s4fe3sktf4q388bpsluiik64l8h060qptgfv48r25fcskecmc9t4gdsm8im9fhjf70i1klp34epksg + 785. -- #23nq5mshk51uktsg3su3mnkr9s4fe3sktf4q388bpsluiik64l8h060qptgfv48r25fcskecmc9t4gdsm8im9fhjf70i1klp34epksg MVar.take : MVar o ->{IO, Exception} o - 785. -- #18pqussken2f5u9vuall7ds58cf4fajoc4trf7p93vk4640ia88vsh2lgq9kgu8fvpr86518443ecvn7eo5tessq2hmgs55aiftui8g + 786. -- #18pqussken2f5u9vuall7ds58cf4fajoc4trf7p93vk4640ia88vsh2lgq9kgu8fvpr86518443ecvn7eo5tessq2hmgs55aiftui8g newClient : ClientConfig -> Socket ->{IO, Exception} Tls - 786. -- #mmoj281h8bimgcfqfpfg6mfriu8cta5vva4ppo41ioc6phegdfii26ic2s5sh0lf5tc6o15o7v79ui8eeh2mbicup07tl6hkrq9q34o + 787. -- #mmoj281h8bimgcfqfpfg6mfriu8cta5vva4ppo41ioc6phegdfii26ic2s5sh0lf5tc6o15o7v79ui8eeh2mbicup07tl6hkrq9q34o newServer : ServerConfig -> Socket ->{IO, Exception} Tls - 787. -- #r6l6s6ni7ut1b9le2d84el9dkhqjcjhodhd0l1qsksahm4cbgdk0odjck9jnku08v0pn909kabe2v88p43jisavkariomtgmtrrtbu8 + 788. -- #r6l6s6ni7ut1b9le2d84el9dkhqjcjhodhd0l1qsksahm4cbgdk0odjck9jnku08v0pn909kabe2v88p43jisavkariomtgmtrrtbu8 openFile : Text -> FileMode ->{IO, Exception} Handle - 788. -- #c58qbcgd90d965dokk7bu82uehegkbe8jttm7lv4j0ohgi2qm3e3p4v1qfr8vc2dlsmsl9tv0v71kco8c18mneule0ntrhte4ks1090 + 789. -- #c58qbcgd90d965dokk7bu82uehegkbe8jttm7lv4j0ohgi2qm3e3p4v1qfr8vc2dlsmsl9tv0v71kco8c18mneule0ntrhte4ks1090 printLine : Text ->{IO, Exception} () - 789. -- #dck7pb7qv05ol3b0o76l88a22bc7enl781ton5qbs2umvgsua3p16n22il02m29592oohsnbt3cr7hnlumpdhv2ibjp6iji9te4iot0 + 790. -- #dck7pb7qv05ol3b0o76l88a22bc7enl781ton5qbs2umvgsua3p16n22il02m29592oohsnbt3cr7hnlumpdhv2ibjp6iji9te4iot0 printText : Text ->{IO} Either Failure () - 790. -- #5si7baedo99eap6jgd9krvt7q4ak8s98t4ushnno8mgjp7u9li137ferm3dn11g4k3mds1m8n33sbuodrohstbm9hcqm1937tfj7iq8 + 791. -- #5si7baedo99eap6jgd9krvt7q4ak8s98t4ushnno8mgjp7u9li137ferm3dn11g4k3mds1m8n33sbuodrohstbm9hcqm1937tfj7iq8 putBytes : Handle -> Bytes ->{IO, Exception} () - 791. -- #gkd4pi7uossfe12b19s0mrr0a04v5vvhnfmq3qer3cu7jr24m5v4e1qu59mktrornbrrqgihsvkj1f29je971oqimpngiqgebkr9i58 + 792. -- #gkd4pi7uossfe12b19s0mrr0a04v5vvhnfmq3qer3cu7jr24m5v4e1qu59mktrornbrrqgihsvkj1f29je971oqimpngiqgebkr9i58 readFile : Text ->{IO, Exception} Bytes - 792. -- #ak95mrmd6jhaiikkr42qsvd5lu7au0mpveqm1e347mkr7s4f846apqhh203ei1p3pqi18dcuhuotf53l8p2ivsjs8octc1eenjdqb48 + 793. -- #ak95mrmd6jhaiikkr42qsvd5lu7au0mpveqm1e347mkr7s4f846apqhh203ei1p3pqi18dcuhuotf53l8p2ivsjs8octc1eenjdqb48 ready : Handle ->{IO, Exception} Boolean - 793. -- #gpogpcuoc1dsktoh5t50ofl6dc4vulm0fsqoeevuuoivbrin87ah166b8k8vq3s3977ha0p7np5mn198gglqkjj1gh7nbv31eb7dbqo + 794. -- #gpogpcuoc1dsktoh5t50ofl6dc4vulm0fsqoeevuuoivbrin87ah166b8k8vq3s3977ha0p7np5mn198gglqkjj1gh7nbv31eb7dbqo receive : Tls ->{IO, Exception} Bytes - 794. -- #7rctbhido3s7lm9tjb6dit94cg2jofasr6div31976q840e5va5j6tu6p0pugkt106mcjrtiqndimaknakrnssdo6ul0jef6a9nf1qo + 795. -- #7rctbhido3s7lm9tjb6dit94cg2jofasr6div31976q840e5va5j6tu6p0pugkt106mcjrtiqndimaknakrnssdo6ul0jef6a9nf1qo removeDirectory : Text ->{IO, Exception} () - 795. -- #710k006oln987ch4k1c986sb0jfqtpusp0a235te6cejhns51um6umr311ltgfiv80kt0s8sb8r0ic63gj2nvgbi66vq10s4ilkk5ng + 796. -- #710k006oln987ch4k1c986sb0jfqtpusp0a235te6cejhns51um6umr311ltgfiv80kt0s8sb8r0ic63gj2nvgbi66vq10s4ilkk5ng renameDirectory : Text -> Text ->{IO, Exception} () - 796. -- #vb50tjb967ic3mr4brs0pro9819ftcj4q48eoeal8gmk02f05isuqhn0accbi7rv07g3i4hjgntu2b2r8b9bn15mjc59v10u9c3gjdo + 797. -- #vb50tjb967ic3mr4brs0pro9819ftcj4q48eoeal8gmk02f05isuqhn0accbi7rv07g3i4hjgntu2b2r8b9bn15mjc59v10u9c3gjdo runTest : '{IO, TempDirs, Exception, Stream Result} a ->{IO} [Result] - 797. -- #ub9vp3rs8gh7kj9ksq0dbpoj22r61iq179co8tpgsj9m52n36qha52rm5hlht4hesgqfb8917cp1tk8jhgcft6sufgis6bgemmd57ag + 798. -- #ub9vp3rs8gh7kj9ksq0dbpoj22r61iq179co8tpgsj9m52n36qha52rm5hlht4hesgqfb8917cp1tk8jhgcft6sufgis6bgemmd57ag saveSelfContained : a -> Text ->{IO, Exception} () - 798. -- #utcu5rk68sot520tjcsjhrpipbb0dq3idd81o04ctparap6iusco52v3ojh3r0d6j0nnbfjvtiuo0f0ob7udshasudvlftjo6hnpsjg + 799. -- #6jriif58nb7gbb576kcabft4k4qaa74prd4dpsomokbqceust7p0gu0jlpar4o70qt987lkki2sj1pknkr0ggoif8fcvu2jg2uenqe8 saveTestCase : Text + -> Text -> (a -> Text) -> a ->{IO, Exception} () - 799. -- #uq87p0r1djq5clhkbimp3fc325e5kp3bv33dc8fpphotdqp95a0ps2c2ch8d2ftdpdualpq2oo9dmnka6kvnc9kvugs2538q62up4t0 + 800. -- #uq87p0r1djq5clhkbimp3fc325e5kp3bv33dc8fpphotdqp95a0ps2c2ch8d2ftdpdualpq2oo9dmnka6kvnc9kvugs2538q62up4t0 seekHandle : Handle -> SeekMode -> Int ->{IO, Exception} () - 800. -- #ftkuro0u0et9ahigdr1k38tl2sl7i0plm7cv5nciccdd71t6a64icla66ss0ufu7llfuj7cuvg3ms4ieel6penfi8gkahb9tm3sfhjo + 801. -- #ftkuro0u0et9ahigdr1k38tl2sl7i0plm7cv5nciccdd71t6a64icla66ss0ufu7llfuj7cuvg3ms4ieel6penfi8gkahb9tm3sfhjo send : Tls -> Bytes ->{IO, Exception} () - 801. -- #k6gmcn3qg50h49gealh8o7j7tp74rvhgn040kftsavd2cldqopcv9945olnooe04cqitgpvekpcbr5ccqjosg7r9gb1lagju5v9ln0o + 802. -- #k6gmcn3qg50h49gealh8o7j7tp74rvhgn040kftsavd2cldqopcv9945olnooe04cqitgpvekpcbr5ccqjosg7r9gb1lagju5v9ln0o serverSocket : Optional Text -> Text ->{IO, Exception} Socket - 802. -- #umje4ibrfv3c6vsjrdkbne1u7c8hg4ll9185m3frqr2rsr8738hp5fq12kepa28h63u9qi23stsegjp1hv0incr5djbl7ulp2s12d8g + 803. -- #umje4ibrfv3c6vsjrdkbne1u7c8hg4ll9185m3frqr2rsr8738hp5fq12kepa28h63u9qi23stsegjp1hv0incr5djbl7ulp2s12d8g setBuffering : Handle -> BufferMode ->{IO, Exception} () - 803. -- #je6s0pdkrg3mvphpg535pubchjd40mepki6ipum7498sma7pll9l89h6de65063bufihf2jb5ihepth2jahir8rs757ggfrnpp7fs7o + 804. -- #je6s0pdkrg3mvphpg535pubchjd40mepki6ipum7498sma7pll9l89h6de65063bufihf2jb5ihepth2jahir8rs757ggfrnpp7fs7o setEcho : Handle -> Boolean ->{IO, Exception} () - 804. -- #in06o7cfgnlmm6pvdtv0jv9hniahcli0fvh27o01ork1p77ro2v51rc05ts1h6p9mtffqld4ufs8klcc4bse1tsj93cu0na0bbiuqb0 + 805. -- #in06o7cfgnlmm6pvdtv0jv9hniahcli0fvh27o01ork1p77ro2v51rc05ts1h6p9mtffqld4ufs8klcc4bse1tsj93cu0na0bbiuqb0 snd : ∀ a1 a. (a1, a) -> a - 805. -- #km3cpkvcnvcos0isfbnb7pb3s45ri5q42n74jmm9c4v1bcu8nlk63353u4ohfr7av4k00s4s180ddnqbam6a01thhlt2tie1hm5a9bo + 806. -- #km3cpkvcnvcos0isfbnb7pb3s45ri5q42n74jmm9c4v1bcu8nlk63353u4ohfr7av4k00s4s180ddnqbam6a01thhlt2tie1hm5a9bo socketAccept : Socket ->{IO, Exception} Socket - 806. -- #ubteu6e7h7om7o40e8mm1rcmp8uur7qn7p5d92gtp3q92rtr459nn3rff4i9q46o2o60tmh77i9vgu0pub768s9kvn9egtcds30nk88 + 807. -- #ubteu6e7h7om7o40e8mm1rcmp8uur7qn7p5d92gtp3q92rtr459nn3rff4i9q46o2o60tmh77i9vgu0pub768s9kvn9egtcds30nk88 socketPort : Socket ->{IO, Exception} Nat - 807. -- #3rp8h0dt7g60nrjdehuhqga9dmomti5rdqho7r1rm5rg5moet7kt3ieempo7c9urur752njachq6k48ggbic4ugbbv75jl2mfbk57a0 + 808. -- #3rp8h0dt7g60nrjdehuhqga9dmomti5rdqho7r1rm5rg5moet7kt3ieempo7c9urur752njachq6k48ggbic4ugbbv75jl2mfbk57a0 startsWith : Text -> Text -> Boolean - 808. -- #elsab3sc7p4c6bj73pgvklv0j7qu268rn5isv6micfp7ib8grjoustpqdq0pkd4a379mr5ijb8duu2q0n040osfurppp8pt8vaue2fo + 809. -- #elsab3sc7p4c6bj73pgvklv0j7qu268rn5isv6micfp7ib8grjoustpqdq0pkd4a379mr5ijb8duu2q0n040osfurppp8pt8vaue2fo stdout : Handle - 809. -- #rfi1v9429f9qluv533l2iba77aadttilrpmnhljfapfnfa6sru2nr8ibpqvib9nc4s4nb9s1as45upsfqfqe6ivqi2p82b2vd866it8 + 810. -- #rfi1v9429f9qluv533l2iba77aadttilrpmnhljfapfnfa6sru2nr8ibpqvib9nc4s4nb9s1as45upsfqfqe6ivqi2p82b2vd866it8 structural ability Stream a - 810. -- #s76vfp9t00khf3bvrg01h9u7gnqj5m62sere8ac97un79ojd82b71q2e0cllj002jn4r2g3qhjft40gkqotgor74v0iogkt3lfftlug + 811. -- #s76vfp9t00khf3bvrg01h9u7gnqj5m62sere8ac97un79ojd82b71q2e0cllj002jn4r2g3qhjft40gkqotgor74v0iogkt3lfftlug Stream.collect : '{e, Stream a} r ->{e} ([a], r) - 811. -- #abc5m7k74em3fk9et4lrj0ee2lsbvp8vp826josen26l1g3lh9ansb47b68efe1vhhi8f6l6kaircd5t4ihlbt0pq4nlipgde9rq8v8 + 812. -- #abc5m7k74em3fk9et4lrj0ee2lsbvp8vp826josen26l1g3lh9ansb47b68efe1vhhi8f6l6kaircd5t4ihlbt0pq4nlipgde9rq8v8 Stream.collect.handler : Request {Stream a} r -> ([a], r) - 812. -- #rfi1v9429f9qluv533l2iba77aadttilrpmnhljfapfnfa6sru2nr8ibpqvib9nc4s4nb9s1as45upsfqfqe6ivqi2p82b2vd866it8#0 + 813. -- #rfi1v9429f9qluv533l2iba77aadttilrpmnhljfapfnfa6sru2nr8ibpqvib9nc4s4nb9s1as45upsfqfqe6ivqi2p82b2vd866it8#0 Stream.emit : a ->{Stream a} () - 813. -- #mrhqdu5he7p8adejmvt4ss09apkbnu8jn66g4lpf0uas9dvm8goa6g65bo2u7s0175hrrofd6uqg7ogmduf928knfpkd12042k6o860 + 814. -- #mrhqdu5he7p8adejmvt4ss09apkbnu8jn66g4lpf0uas9dvm8goa6g65bo2u7s0175hrrofd6uqg7ogmduf928knfpkd12042k6o860 Stream.toList : '{Stream a} r -> [a] - 814. -- #t3klufmrq2bk8gg0o4lukenlmu0dkkcssq9l80m4p3dm6rqesrt51nrebfujfgco9h47f4e5nplmj7rvc3salvs65labd7nvj2fkne8 + 815. -- #t3klufmrq2bk8gg0o4lukenlmu0dkkcssq9l80m4p3dm6rqesrt51nrebfujfgco9h47f4e5nplmj7rvc3salvs65labd7nvj2fkne8 Stream.toList.handler : Request {Stream a} r -> [a] - 815. -- #pus3urtj4e1bhv5p5l16d7vnv4g2hso78pcfussnufkt3d53j7oaqde1ajvijr1g6f0cv2c4ice34g8g8n17hd7hql6hvl8sgcgu6s8 + 816. -- #pus3urtj4e1bhv5p5l16d7vnv4g2hso78pcfussnufkt3d53j7oaqde1ajvijr1g6f0cv2c4ice34g8g8n17hd7hql6hvl8sgcgu6s8 systemTime : '{IO, Exception} Nat - 816. -- #11mhfqj6rts8lm3im7saf44tn3km5bboqtu1td0udnaiit4qqg6ar1ecmccosl6gufsnp6sug3vcmgapsc58sgj7dh7rg8msq2qkj18 + 817. -- #11mhfqj6rts8lm3im7saf44tn3km5bboqtu1td0udnaiit4qqg6ar1ecmccosl6gufsnp6sug3vcmgapsc58sgj7dh7rg8msq2qkj18 structural ability TempDirs - 817. -- #11mhfqj6rts8lm3im7saf44tn3km5bboqtu1td0udnaiit4qqg6ar1ecmccosl6gufsnp6sug3vcmgapsc58sgj7dh7rg8msq2qkj18#0 + 818. -- #11mhfqj6rts8lm3im7saf44tn3km5bboqtu1td0udnaiit4qqg6ar1ecmccosl6gufsnp6sug3vcmgapsc58sgj7dh7rg8msq2qkj18#0 TempDirs.newTempDir : Text ->{TempDirs} Text - 818. -- #11mhfqj6rts8lm3im7saf44tn3km5bboqtu1td0udnaiit4qqg6ar1ecmccosl6gufsnp6sug3vcmgapsc58sgj7dh7rg8msq2qkj18#1 + 819. -- #11mhfqj6rts8lm3im7saf44tn3km5bboqtu1td0udnaiit4qqg6ar1ecmccosl6gufsnp6sug3vcmgapsc58sgj7dh7rg8msq2qkj18#1 TempDirs.removeDir : Text ->{TempDirs} () - 819. -- #ibj0sc16l6bd7r6ptft93jeocitrjod98g210beogdk30t3tb127fbe33vau29j0j4gt8mbs2asfs5rslgk0fl3o4did2t9oa8o5kf8 + 820. -- #ibj0sc16l6bd7r6ptft93jeocitrjod98g210beogdk30t3tb127fbe33vau29j0j4gt8mbs2asfs5rslgk0fl3o4did2t9oa8o5kf8 terminate : Tls ->{IO, Exception} () - 820. -- #iis8ph5ljlq8ijd9jsdlsga91fh1354fii7955l4v52mnvn71cd76maculs0eathrmtfjqh0knbc600kmvq6abj4k2ntnbh5ee10m2o + 821. -- #iis8ph5ljlq8ijd9jsdlsga91fh1354fii7955l4v52mnvn71cd76maculs0eathrmtfjqh0knbc600kmvq6abj4k2ntnbh5ee10m2o testAutoClean : '{IO} [Result] - 821. -- #k1prgid1t9d4fu6f60rct978khcuinkpq49ps95aqaimt2tfoa77fc0c8i3pmc8toeth1s98al3nosaa1mhbh2j2k2nvqivm0ks963o + 822. -- #k1prgid1t9d4fu6f60rct978khcuinkpq49ps95aqaimt2tfoa77fc0c8i3pmc8toeth1s98al3nosaa1mhbh2j2k2nvqivm0ks963o Text.fromUtf8 : Bytes ->{Exception} Text - 822. -- #32q9jqhmi8f08pec3hj0je4u7k52f9f1hdfsmn9ncg2kpki5da9dabigplvdcot3a00k7s5npc4n78psd6ojaumqjla259e9pqd4ov8 + 823. -- #32q9jqhmi8f08pec3hj0je4u7k52f9f1hdfsmn9ncg2kpki5da9dabigplvdcot3a00k7s5npc4n78psd6ojaumqjla259e9pqd4ov8 structural ability Throw e - 823. -- #32q9jqhmi8f08pec3hj0je4u7k52f9f1hdfsmn9ncg2kpki5da9dabigplvdcot3a00k7s5npc4n78psd6ojaumqjla259e9pqd4ov8#0 + 824. -- #32q9jqhmi8f08pec3hj0je4u7k52f9f1hdfsmn9ncg2kpki5da9dabigplvdcot3a00k7s5npc4n78psd6ojaumqjla259e9pqd4ov8#0 Throw.throw : e ->{Throw e} a - 824. -- #f6pkvs6ukf8ngh2j8lm935p1bqadso76o7e3t0j1ukupjh1rg0m1rhtp7u492sq17p3bkbintbnjehc1cqs33qlhnfkoihf5uee4ug0 + 825. -- #f6pkvs6ukf8ngh2j8lm935p1bqadso76o7e3t0j1ukupjh1rg0m1rhtp7u492sq17p3bkbintbnjehc1cqs33qlhnfkoihf5uee4ug0 uncurry : ∀ i1 g1 i g o. (i1 ->{g1} i ->{g} o) -> (i1, i) ->{g1, g} o - 825. -- #u1o44hd0cdlfa8racf458sahdmgea409k8baajgc5k7bqukf2ak5ggs2ped0u3h85v99pgefgb9r7ct2dv4nn9eihjghnqf30p4l57g + 826. -- #u1o44hd0cdlfa8racf458sahdmgea409k8baajgc5k7bqukf2ak5ggs2ped0u3h85v99pgefgb9r7ct2dv4nn9eihjghnqf30p4l57g Value.transitiveDeps : Value ->{IO} [(Link.Term, Code)] - 826. -- #o5bg5el7ckak28ib98j5b6rt26bqbprpddd1brrg3s18qahhbbe3uohufjjnt5eenvtjg0hrvnvpra95jmdppqrovvmcfm1ih2k7guo + 827. -- #o5bg5el7ckak28ib98j5b6rt26bqbprpddd1brrg3s18qahhbbe3uohufjjnt5eenvtjg0hrvnvpra95jmdppqrovvmcfm1ih2k7guo void : x -> () - 827. -- #b4pssu6mf30r4irqj43vvgbc6geq8pp7eg4o2erl948qp3nskp6io5damjj54o2eq9q76mrhsijr1q1d0bna4soed3oggddfvdajaj8 + 828. -- #b4pssu6mf30r4irqj43vvgbc6geq8pp7eg4o2erl948qp3nskp6io5damjj54o2eq9q76mrhsijr1q1d0bna4soed3oggddfvdajaj8 writeFile : Text -> Bytes ->{IO, Exception} () - 828. -- #lcmj2envm11lrflvvcl290lplhvbccv82utoej0lg0eomhmsf2vrv8af17k6if7ff98fp1b13rkseng3fng4stlr495c8dn3gn4k400 + 829. -- #lcmj2envm11lrflvvcl290lplhvbccv82utoej0lg0eomhmsf2vrv8af17k6if7ff98fp1b13rkseng3fng4stlr495c8dn3gn4k400 |> : a -> (a ->{g} t) ->{g} t diff --git a/unison-src/transcripts-using-base/base.u b/unison-src/transcripts-using-base/base.u index 6f334f136b..b181e33b85 100644 --- a/unison-src/transcripts-using-base/base.u +++ b/unison-src/transcripts-using-base/base.u @@ -58,6 +58,15 @@ Exception.unsafeRun! e = structural ability Throw e where throw : e -> a +List.range : Nat -> Nat -> [Nat] +List.range m = + go acc n = + if n <= m then acc + else + n' = drop n 1 + go (n' +: acc) n' + go [] + List.all : (a ->{ε} Boolean) -> [a] ->{ε} Boolean List.all f = cases [] -> true @@ -429,12 +438,12 @@ loadSelfContained path = Left l -> fail "value missing deps" l Right x -> x -saveTestCase : Text -> (a ->{} Text) -> a ->{IO,Exception} () -saveTestCase name f i = +saveTestCase : Text -> Text -> (a ->{} Text) -> a ->{IO,Exception} () +saveTestCase name ver f i = dir = "unison-src/transcripts-using-base/serialized-cases/" - sfile = dir ++ name ++ ".ser" + sfile = dir ++ name ++ "." ++ ver ++ ".ser" ofile = dir ++ name ++ ".out" - hfile = dir ++ name ++ ".hash" + hfile = dir ++ name ++ "." ++ ver ++ ".hash" output = f i diff --git a/unison-src/transcripts-using-base/hashing.md b/unison-src/transcripts-using-base/hashing.md index fc6f64dc85..56240777d5 100644 --- a/unison-src/transcripts-using-base/hashing.md +++ b/unison-src/transcripts-using-base/hashing.md @@ -184,6 +184,14 @@ test> blake2b_512.tests.ex3 = ex Blake2b_512 "The quick brown fox jumps over the lazy dof" "ab6b007747d8068c02e25a6008db8a77c218d94f3b40d2291a7dc8a62090a744c082ea27af01521a102e42f480a31e9844053f456b4b41e8aa78bbe5c12957bb" + +-- check that hashing positive numbers that fit in both Nat and +-- Int yields the same answer +test> crypto.hash.numTests = + t n = + i = Int.fromRepresentation n + hash Blake2b_256 n == hash Blake2b_256 i + checks (List.map t (range 0 20)) ``` ```ucm:hide diff --git a/unison-src/transcripts-using-base/hashing.output.md b/unison-src/transcripts-using-base/hashing.output.md index 5c6825c952..de8c15c8ad 100644 --- a/unison-src/transcripts-using-base/hashing.output.md +++ b/unison-src/transcripts-using-base/hashing.output.md @@ -108,11 +108,11 @@ ex5 = crypto.hmac Sha2_256 mysecret f |> hex 25 | > ex4 ⧩ - "73625f9ba7204540fdeda8c2de201f394e582a83b79218beede62f2245bb4dd8" + "764a6e91271bce6ce8d8f49d551ba0e586a1e20d8bc2df0dff3117fcd9a11d9a" 26 | > ex5 ⧩ - "42c3b22ab8410b48691a325bcdef6c61e771557bfe55a144e5a25e4737106ace" + "abd0e845a5544ced19b1c05df18a05c10b252a355957b18b99b33970d5217de6" ``` And here's the full API: @@ -156,7 +156,7 @@ Note that the universal versions of `hash` and `hmac` are currently unimplemente 1 | > crypto.hash Sha3_256 (fromHex "3849238492") ⧩ - 0xse8a4c3e486840b57c45f437b6675572dcdabdf8a0c2d73c7efc4371fe1464448 + 0xs1259de8ec2c8b925dce24f591ed5cc1d1a5dc01cf88cf8f2343fc9728e124af4 ``` ## Hashing tests @@ -285,6 +285,14 @@ test> blake2b_512.tests.ex3 = ex Blake2b_512 "The quick brown fox jumps over the lazy dof" "ab6b007747d8068c02e25a6008db8a77c218d94f3b40d2291a7dc8a62090a744c082ea27af01521a102e42f480a31e9844053f456b4b41e8aa78bbe5c12957bb" + +-- check that hashing positive numbers that fit in both Nat and +-- Int yields the same answer +test> crypto.hash.numTests = + t n = + i = Int.fromRepresentation n + hash Blake2b_256 n == hash Blake2b_256 i + checks (List.map t (range 0 20)) ``` ```ucm @@ -296,6 +304,7 @@ test> blake2b_512.tests.ex3 = ◉ blake2b_512.tests.ex2 Passed ◉ blake2b_512.tests.ex3 Passed ◉ blake2s_256.tests.ex1 Passed + ◉ crypto.hash.numTests Passed ◉ sha1.tests.ex1 Passed ◉ sha1.tests.ex2 Passed ◉ sha1.tests.ex3 Passed @@ -317,7 +326,7 @@ test> blake2b_512.tests.ex3 = ◉ sha3_512.tests.ex3 Passed ◉ sha3_512.tests.ex4 Passed - ✅ 24 test(s) passing + ✅ 25 test(s) passing Tip: Use view blake2b_512.tests.ex1 to view the source of a test. @@ -454,6 +463,7 @@ test> md5.tests.ex3 = ◉ blake2b_512.tests.ex2 Passed ◉ blake2b_512.tests.ex3 Passed ◉ blake2s_256.tests.ex1 Passed + ◉ crypto.hash.numTests Passed ◉ md5.tests.ex1 Passed ◉ md5.tests.ex2 Passed ◉ md5.tests.ex3 Passed @@ -478,7 +488,7 @@ test> md5.tests.ex3 = ◉ sha3_512.tests.ex3 Passed ◉ sha3_512.tests.ex4 Passed - ✅ 27 test(s) passing + ✅ 28 test(s) passing Tip: Use view blake2b_512.tests.ex1 to view the source of a test. diff --git a/unison-src/transcripts-using-base/random-deserial.md b/unison-src/transcripts-using-base/random-deserial.md index 9b0672764e..aea57bf405 100644 --- a/unison-src/transcripts-using-base/random-deserial.md +++ b/unison-src/transcripts-using-base/random-deserial.md @@ -8,7 +8,7 @@ directory = "unison-src/transcripts-using-base/serialized-cases/" availableCases : '{IO,Exception} [Text] availableCases _ = l = filter (contains ".ser") (directoryContents directory) - map (t -> Text.take (drop (Text.size t) 4) t) l + map (t -> Text.take (drop (Text.size t) 7) t) l gen : Nat -> Nat -> (Nat, Nat) gen seed k = @@ -29,20 +29,24 @@ shuffle = runTestCase : Text ->{Exception,IO} (Text, Test.Result) runTestCase name = - sfile = directory ++ name ++ ".ser" + sfile = directory ++ name ++ ".v4.ser" + lsfile = directory ++ name ++ ".v3.ser" ofile = directory ++ name ++ ".out" - hfile = directory ++ name ++ ".hash" + hfile = directory ++ name ++ ".v4.hash" p@(f, i) = loadSelfContained sfile + pl@(fl, il) = loadSelfContained lsfile o = fromUtf8 (readFile ofile) h = readFile hfile result = - if f i == o - then if toBase32 (crypto.hash Sha3_512 p) == h - then Ok name - else Fail (name ++ " hash mismatch") - else Fail (name ++ " output mismatch") + if not (f i == o) + then Fail (name ++ " output mismatch") + else if not (toBase32 (crypto.hash Sha3_512 p) == h) + then Fail (name ++ " hash mismatch") + else if not (fl il == f i) + then Fail (name ++ " legacy mismatch") + else Ok name (name, result) serialTests : '{IO,Exception} [Test.Result] diff --git a/unison-src/transcripts-using-base/random-deserial.output.md b/unison-src/transcripts-using-base/random-deserial.output.md index 24f21d771f..bae2409510 100644 --- a/unison-src/transcripts-using-base/random-deserial.output.md +++ b/unison-src/transcripts-using-base/random-deserial.output.md @@ -4,7 +4,7 @@ directory = "unison-src/transcripts-using-base/serialized-cases/" availableCases : '{IO,Exception} [Text] availableCases _ = l = filter (contains ".ser") (directoryContents directory) - map (t -> Text.take (drop (Text.size t) 4) t) l + map (t -> Text.take (drop (Text.size t) 7) t) l gen : Nat -> Nat -> (Nat, Nat) gen seed k = @@ -25,20 +25,24 @@ shuffle = runTestCase : Text ->{Exception,IO} (Text, Test.Result) runTestCase name = - sfile = directory ++ name ++ ".ser" + sfile = directory ++ name ++ ".v4.ser" + lsfile = directory ++ name ++ ".v3.ser" ofile = directory ++ name ++ ".out" - hfile = directory ++ name ++ ".hash" + hfile = directory ++ name ++ ".v4.hash" p@(f, i) = loadSelfContained sfile + pl@(fl, il) = loadSelfContained lsfile o = fromUtf8 (readFile ofile) h = readFile hfile result = - if f i == o - then if toBase32 (crypto.hash Sha3_512 p) == h - then Ok name - else Fail (name ++ " hash mismatch") - else Fail (name ++ " output mismatch") + if not (f i == o) + then Fail (name ++ " output mismatch") + else if not (toBase32 (crypto.hash Sha3_512 p) == h) + then Fail (name ++ " hash mismatch") + else if not (fl il == f i) + then Fail (name ++ " legacy mismatch") + else Ok name (name, result) serialTests : '{IO,Exception} [Test.Result] diff --git a/unison-src/transcripts-using-base/serial-test-00.md b/unison-src/transcripts-using-base/serial-test-00.md index 63eb7726ee..657a8d796d 100644 --- a/unison-src/transcripts-using-base/serial-test-00.md +++ b/unison-src/transcripts-using-base/serial-test-00.md @@ -68,7 +68,7 @@ mkTestCase = do f = evaluate balancedSum catenate tup = (tree0, tree1, tree2, tree3) - saveTestCase "case-00" f tup + saveTestCase "case-00" "v4" f tup ``` ```ucm diff --git a/unison-src/transcripts-using-base/serial-test-00.output.md b/unison-src/transcripts-using-base/serial-test-00.output.md index c4154c6e9e..a4688bec7b 100644 --- a/unison-src/transcripts-using-base/serial-test-00.output.md +++ b/unison-src/transcripts-using-base/serial-test-00.output.md @@ -64,7 +64,7 @@ mkTestCase = do f = evaluate balancedSum catenate tup = (tree0, tree1, tree2, tree3) - saveTestCase "case-00" f tup + saveTestCase "case-00" "v4" f tup ``` ```ucm diff --git a/unison-src/transcripts-using-base/serial-test-01.md b/unison-src/transcripts-using-base/serial-test-01.md index d0589c43bd..50dc14de7e 100644 --- a/unison-src/transcripts-using-base/serial-test-01.md +++ b/unison-src/transcripts-using-base/serial-test-01.md @@ -16,7 +16,7 @@ combines = cases "(" ++ toText rx ++ ", " ++ toText ry ++ ", \"" ++ rz ++ "\")" mkTestCase = do - saveTestCase "case-01" combines (l1, l2, l3) + saveTestCase "case-01" "v4" combines (l1, l2, l3) ``` ```ucm diff --git a/unison-src/transcripts-using-base/serial-test-01.output.md b/unison-src/transcripts-using-base/serial-test-01.output.md index 30b79d0ef1..73e75a2302 100644 --- a/unison-src/transcripts-using-base/serial-test-01.output.md +++ b/unison-src/transcripts-using-base/serial-test-01.output.md @@ -12,7 +12,7 @@ combines = cases "(" ++ toText rx ++ ", " ++ toText ry ++ ", \"" ++ rz ++ "\")" mkTestCase = do - saveTestCase "case-01" combines (l1, l2, l3) + saveTestCase "case-01" "v4" combines (l1, l2, l3) ``` ```ucm diff --git a/unison-src/transcripts-using-base/serial-test-02.md b/unison-src/transcripts-using-base/serial-test-02.md index af856f2471..1767a69014 100644 --- a/unison-src/transcripts-using-base/serial-test-02.md +++ b/unison-src/transcripts-using-base/serial-test-02.md @@ -29,7 +29,7 @@ products = cases (x, y, z) -> "(" ++ toText px ++ ", " ++ toText py ++ ", \"" ++ toText pz ++ "\")" mkTestCase = do - saveTestCase "case-02" products (l1, l2, l3) + saveTestCase "case-02" "v4" products (l1, l2, l3) ``` diff --git a/unison-src/transcripts-using-base/serial-test-02.output.md b/unison-src/transcripts-using-base/serial-test-02.output.md index 0f81f1dcbb..57b3421505 100644 --- a/unison-src/transcripts-using-base/serial-test-02.output.md +++ b/unison-src/transcripts-using-base/serial-test-02.output.md @@ -25,7 +25,7 @@ products = cases (x, y, z) -> "(" ++ toText px ++ ", " ++ toText py ++ ", \"" ++ toText pz ++ "\")" mkTestCase = do - saveTestCase "case-02" products (l1, l2, l3) + saveTestCase "case-02" "v4" products (l1, l2, l3) ``` diff --git a/unison-src/transcripts-using-base/serial-test-03.md b/unison-src/transcripts-using-base/serial-test-03.md index ae851e6f32..47aa811993 100644 --- a/unison-src/transcripts-using-base/serial-test-03.md +++ b/unison-src/transcripts-using-base/serial-test-03.md @@ -44,7 +44,7 @@ finish = cases (x, y, z) -> mkTestCase = do trip = (suspSum l1, suspSum l2, suspSum l3) - saveTestCase "case-03" finish trip + saveTestCase "case-03" "v4" finish trip ``` ```ucm diff --git a/unison-src/transcripts-using-base/serial-test-03.output.md b/unison-src/transcripts-using-base/serial-test-03.output.md index c089f95b0e..bbbdde7e06 100644 --- a/unison-src/transcripts-using-base/serial-test-03.output.md +++ b/unison-src/transcripts-using-base/serial-test-03.output.md @@ -40,7 +40,7 @@ finish = cases (x, y, z) -> mkTestCase = do trip = (suspSum l1, suspSum l2, suspSum l3) - saveTestCase "case-03" finish trip + saveTestCase "case-03" "v4" finish trip ``` ```ucm diff --git a/unison-src/transcripts-using-base/serialized-cases/case-00.hash b/unison-src/transcripts-using-base/serialized-cases/case-00.hash deleted file mode 100644 index caafeead02..0000000000 --- a/unison-src/transcripts-using-base/serialized-cases/case-00.hash +++ /dev/null @@ -1 +0,0 @@ -TSYSF5D3I7HEZR4T7JITBL3NDM5RUXEUCQXLFUXLZKHWSTL6DXA6HCFBYT4ABZTX676DBYVBDTRBUHEUPLKOPYYYHRVSXN5XUYIDRWI= \ No newline at end of file diff --git a/unison-src/transcripts-using-base/serialized-cases/case-00.ser b/unison-src/transcripts-using-base/serialized-cases/case-00.v3.ser similarity index 100% rename from unison-src/transcripts-using-base/serialized-cases/case-00.ser rename to unison-src/transcripts-using-base/serialized-cases/case-00.v3.ser diff --git a/unison-src/transcripts-using-base/serialized-cases/case-00.v4.hash b/unison-src/transcripts-using-base/serialized-cases/case-00.v4.hash new file mode 100644 index 0000000000..181c564dc3 --- /dev/null +++ b/unison-src/transcripts-using-base/serialized-cases/case-00.v4.hash @@ -0,0 +1 @@ +Z6EW6IDZJXHDMNGTVSKYLMZVG47ORYF4O6JDQXQGQFJP476SLM75FXFOYI27OJHMIX5OIHKQ6LXWLYQ5LDGEYWEXK6GQPP6JKH6SVMI= \ No newline at end of file diff --git a/unison-src/transcripts-using-base/serialized-cases/case-00.v4.ser b/unison-src/transcripts-using-base/serialized-cases/case-00.v4.ser new file mode 100644 index 0000000000..ebd7626b6d --- /dev/null +++ b/unison-src/transcripts-using-base/serialized-cases/case-00.v4.ser @@ -0,0 +1 @@ +AAAAABABAFABKYCFITJNTOQRE3BRWTYOOLZIFGNVKRU5GVLMBALLTNRPXH2ZPF4XNLZYXJVJEXKJWKPQNL7E3K7B2E3V4XY2ROGIXGCG4I3T5ZYZ6UAAAAAAAAAAAAAAAIBQCAYBAFABKYCFITJNTOQRE3BRWTYOOLZIFGNVKRU5GVLMBALLTNRPXH2ZPF4XNLZYXJVJEXKJWKPQNL7E3K7B2E3V4XY2ROGIXGCG4I3T5ZYZ6UAAAAAAAAAAAAAAAIBQEAABEEACITAXWMOCQYHP2S67NQK5TVVWHTWRHFIEUOIEFN74DGYKE2OBEPAAAEAUAFLAIVCNFWN2CETMGG2PBZZPFAUZWVKGTU2VNQEBNONWF647LF4XS5VPHC5GVES5JGZJ6BVP4TNL4HITOXS7DKFYZC4YI3RDOPXHDH2QAAAAAAAAAAAAAABAGBQAAQAQCAIBAYAAIAKAVNVYCKXZSHU43Z7M4UVJXJC34TQNL7UBPR4WVYGEY5MHXUFY4VSGME4Q4YGZISBZLWLHHH4C4YVGRWWO756FKRLIORSNPQSF346AB7AAAIAAAAIBAEBQCAIBBMAACAIBAMAQCIIAERGBPMY4FBQO7VF563AV3HLLMPHNCOKQJI4QIK37YGNQUJU4CI6AABAGAUCAECYAAIAQCAYAA4AQECYAAMAQCAYBAEQQAJCMC6ZRYKDA57KL35WBLWOWWY6O2E4VASRZAQVX7QM3BITJYER4AACAQBYGAIFQABABAEBQACACAEAAGAAJAIBQAAABAFAAAL7RKMFUH4QQ5G2NTSQN244XUAWGVES3B5ALZMIZQ472Z3Z2SNRY5NY74Q7LRMSAM6YKIY6LXDY4GMGUQNR5G27OEYPJPYTZR5GN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VYGEY5MHXUFY4VSGME4Q4YGZISBZLWLHHH4C4YVGRWWO756FKRLIORSNPQSF346AB7AAAAAAAAAAAAAAAAADAACGO33PMQAQCQFLNOASV6MR5HG6P3HFFKN2IW7E4DK75AL4PFVOBRGHLB55BOHFMRTBHEHGBWKEQOK5SZZZ7AXGFJUNVTX7PRKUK2DUMTL4ERO7HQAPYAAAAAAAAAAAAAAAAAYAANRHSZIBAFAKW24BFL4ZD2ON47WOKKU3URN6JYGV72AXY6LK4DCMOWD32C4OKZDGCOIOMDMUJA4V3FTTT6BOMKTI3LHP67CVIVUHIZGXYJC56PAA7QAAAAAAAAAAAAAAAAAQCQAAF7YVGC2D6IIOTNGZZIG5OOL2ALDKSJNQ6QF4WEMYOP5M545JGY4OW4P6IPVYWJAGPMFEMPF3R4ODGDKIGY6TNPXCMHUX4J4Y6TGQEAAAAAAAAAAAAAAAAAIBIAAC74KTBNB7EEHJWTM4UDOXHF5AFRVJEWYPIC6LCGMHH6WO6OUTMOHLOH7EH24LEQDHWCSGHS5Y6HBTBVEDMPJWX3RGD2L6E6MPJTICAAAAAAAAAAAAAAAAAEAUAABP6FJQWQ7SCDU3JWOKBXLTS6QCY2USLMHUBPFRDGDT7LHPHKJWHDVXD7SD5OFSIBT3BJDDZO4PDQZQ2SBWHU3L5YTB5F7CPGHUZUBAAAAAAAAAAAAAAAAA==== \ No newline at end of file diff --git a/unison-src/transcripts-using-base/serialized-cases/case-01.hash b/unison-src/transcripts-using-base/serialized-cases/case-01.hash deleted file mode 100644 index 57576cb52e..0000000000 --- a/unison-src/transcripts-using-base/serialized-cases/case-01.hash +++ /dev/null @@ -1 +0,0 @@ -XAKQKISPS65FTJS7VEPSX3X4XZZ3KSJOEJ6DHLKOUUZY35CQGV4CSORAQDLA7JOJFWFQMIKGNIRQFLPXAVSOX2TAHML6QUZYE2YHDCI= \ No newline at end of file diff --git a/unison-src/transcripts-using-base/serialized-cases/case-01.ser b/unison-src/transcripts-using-base/serialized-cases/case-01.v3.ser similarity index 100% rename from unison-src/transcripts-using-base/serialized-cases/case-01.ser rename to unison-src/transcripts-using-base/serialized-cases/case-01.v3.ser diff --git a/unison-src/transcripts-using-base/serialized-cases/case-01.v4.hash b/unison-src/transcripts-using-base/serialized-cases/case-01.v4.hash new file mode 100644 index 0000000000..d576afd225 --- /dev/null +++ b/unison-src/transcripts-using-base/serialized-cases/case-01.v4.hash @@ -0,0 +1 @@ +F5QWFLMAWQDYCMOPDCCTYLWJ2HOBGUG2G5YLWHSAFGDXSHGYQIWDSN6PVWC2RJXIGB7ZBSZVIJ6OENKGWAEZIV3CLQ2AWL3WKITPDXA= \ No newline at end of file diff --git a/unison-src/transcripts-using-base/serialized-cases/case-01.v4.ser b/unison-src/transcripts-using-base/serialized-cases/case-01.v4.ser new file mode 100644 index 0000000000..f2185f1faa --- /dev/null +++ b/unison-src/transcripts-using-base/serialized-cases/case-01.v4.ser @@ -0,0 +1 @@ +AAAAABABAFABKYCFITJNTOQRE3BRWTYOOLZIFGNVKRU5GVLMBALLTNRPXH2ZPF4XNLZYXJVJEXKJWKPQNL7E3K7B2E3V4XY2ROGIXGCG4I3T5ZYZ6UAAAAAAAAAAAAAAAIBQCBABAFABKYCFITJNTOQRE3BRWTYOOLZIFGNVKRU5GVLMBALLTNRPXH2ZPF4XNLZYXJVJEXKJWKPQNL7E3K7B2E3V4XY2ROGIXGCG4I3T5ZYZ6UAAAAAAAAAAAAAAAIBQEAABEEAFG5MMPCUOP3IIQXASYKKG2MIJ2XJ3B7MGFL6E44DZUAQUNLQVKHIAAEAUAFLAIVCNFWN2CETMGG2PBZZPFAUZWVKGTU2VNQEBNONWF647LF4XS5VPHC5GVES5JGZJ6BVP4TNL4HITOXS7DKFYZC4YI3RDOPXHDH2QAAAAAAAAAAAAAABAGBQAAMAQCAIKAEAQYAIAAAAAAAAAAAAAGAIBEEAO7KOJ7HCZGJXDGV7GZE7OLVCVEIO5QE4Y6TLY67FZSQS6DUK2SVYAAQAQGAQAAEAUAABP6F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4Y6TGQEAAAAAAAAAAAAAAAA=== \ No newline at end of file diff --git a/unison-src/transcripts-using-base/serialized-cases/case-02.hash b/unison-src/transcripts-using-base/serialized-cases/case-02.hash deleted file mode 100644 index 1f11f7df60..0000000000 --- a/unison-src/transcripts-using-base/serialized-cases/case-02.hash +++ /dev/null @@ -1 +0,0 @@ -PFAASPLDLYPYXADYQZHKF7VZM2AWAZQIJI2B7FUHULOFF43EHQXZP3EJ7LOU5LZP52X4GKQS5T6MWNZLXL2HZINAFVNL3NRNG3V7DVY= \ No newline at end of file diff --git a/unison-src/transcripts-using-base/serialized-cases/case-02.ser b/unison-src/transcripts-using-base/serialized-cases/case-02.v3.ser similarity index 100% rename from unison-src/transcripts-using-base/serialized-cases/case-02.ser rename to unison-src/transcripts-using-base/serialized-cases/case-02.v3.ser diff --git a/unison-src/transcripts-using-base/serialized-cases/case-02.v4.hash b/unison-src/transcripts-using-base/serialized-cases/case-02.v4.hash new file mode 100644 index 0000000000..f7f6926bc2 --- /dev/null +++ b/unison-src/transcripts-using-base/serialized-cases/case-02.v4.hash @@ -0,0 +1 @@ +OKXJPQQY4QXSCGDHM2LSUTSIKWE7W5PS6CSYCKBOEOBTRKHOKWTH6QZP7HEVWPEJC5CWGWB54ZPI7YB36F37MXN7ISPCP5JGX26NRBQ= \ No newline at end of file diff --git a/unison-src/transcripts-using-base/serialized-cases/case-02.v4.ser b/unison-src/transcripts-using-base/serialized-cases/case-02.v4.ser new file mode 100644 index 0000000000..d6decec72e --- /dev/null +++ b/unison-src/transcripts-using-base/serialized-cases/case-02.v4.ser @@ -0,0 +1 @@ +AAAAABABAFABKYCFITJNTOQRE3BRWTYOOLZIFGNVKRU5GVLMBALLTNRPXH2ZPF4XNLZYXJVJEXKJWKPQNL7E3K7B2E3V4XY2ROGIXGCG4I3T5ZYZ6UAAAAAAAAAAAAAAAIBQCBIBAFABKYCFITJNTOQRE3BRWTYOOLZIFGNVKRU5GVLMBALLTNRPXH2ZPF4XNLZYXJVJEXK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NY74Q7LRMSAM6YKIY6LXDY4GMGUQNR5G27OEYPJPYTZR5GNAIAAAAAAAAAAAAAAAAAQCQAAF7YVGC2D6IIOTNGZZIG5OOL2ALDKSJNQ6QF4WEMYOP5M545JGY4OW4P6IPVYWJAGPMFEMPF3R4ODGDKIGY6TNPXCMHUX4J4Y6TGQEAAAAAAAAAAAAAAAA=== \ No newline at end of file diff --git a/unison-src/transcripts-using-base/serialized-cases/case-03.hash b/unison-src/transcripts-using-base/serialized-cases/case-03.hash deleted file mode 100644 index 4488b8d37e..0000000000 --- a/unison-src/transcripts-using-base/serialized-cases/case-03.hash +++ /dev/null @@ -1 +0,0 @@ -WAI4ZS4RURIMVNMLQ5AGP3ZY3UIILVQ6KKKAESKSWJ322D4ZSXCSMCHYPKLAISMTE3EUODHIED43L2UOXDXWPYNBNJFYAEMJLNLWVHI= \ No newline at end of file diff --git a/unison-src/transcripts-using-base/serialized-cases/case-03.ser b/unison-src/transcripts-using-base/serialized-cases/case-03.v3.ser similarity index 100% rename from unison-src/transcripts-using-base/serialized-cases/case-03.ser rename to unison-src/transcripts-using-base/serialized-cases/case-03.v3.ser diff --git a/unison-src/transcripts-using-base/serialized-cases/case-03.v4.hash b/unison-src/transcripts-using-base/serialized-cases/case-03.v4.hash new file mode 100644 index 0000000000..3b39c4aee9 --- /dev/null +++ b/unison-src/transcripts-using-base/serialized-cases/case-03.v4.hash @@ -0,0 +1 @@ +DLSO2TFPG5363MWC7FDSUW55VYA7P7CI4DBRFLWGPSUTF6YR45QPIPBSJPANZH44MGVYRSSMTPXODLDUFCO6JF43V3IPU4DRDU7JKII= \ No newline at end of file diff --git a/unison-src/transcripts-using-base/serialized-cases/case-03.v4.ser b/unison-src/transcripts-using-base/serialized-cases/case-03.v4.ser new file mode 100644 index 0000000000..bf2abbf676 --- /dev/null +++ b/unison-src/transcripts-using-base/serialized-cases/case-03.v4.ser @@ -0,0 +1 @@ +AAAAABABAFABKYCFITJNTOQRE3BRWTYOOLZIFGNVKRU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7YVGC2D6IIOTNGZZIG5OOL2ALDKSJNQ6QF4WEMYOP5M545JGY4OW4P6IPVYWJAGPMFEMPF3R4ODGDKIGY6TNPXCMHUX4J4Y6TGQEAAAAAAAAAAAAAAAAAQAAAAAAAAAAABQAAAAAAAAAAAAAEQQB35R3MAZIRTCRGGU4HI6TOOCFTFGUOEDPWUI6B7K4C4CIKQN46ITAAAAAAAAAAAAAAICAAAAAAAAAAAAQAAAAAAAAAAAAAASCABD4J3OKKBTZLPQBBAFHIQYPQADAQXNC3RHA5YKBV72ZGYDNKNQSIAAAAAAAAAAAAADAAAQCQAVMBCUJUWZXIISNQY3J4HHF4UCTG2VI2OTKVWAQFVZWYX3T5MXS6LWV44LU2USLVE3FHYGV7SNVPQ5CN26L4NIXDELTBDOENZ644M7KAAAAAAAAAAAAAAAEAIBIBC2QBCT3L53MCHVXWEQZRWJV5VDOEUYB3ETHSNMIWLVS4PAAE5LL6AS6I3ZDUF2EYELLZFBBI2O2PWY3VVDFBEGWSCGXJ6TU6LEX5K6AAAAAAAAAAAAAAABAMEC2AIBIAAC74KTBNB7EEHJWTM4UDOXHF5AFRVJEWYPIC6LCGMHH6WO6OUTMOHLOH7EH24LEQDHWCSGHS5Y6HBTBVEDMPJWX3RGD2L6E6MPJTICAAAAAAAAAAAAAAAAAEAUAABP6FJQWQ7SCDU3JWOKBXLTS6QCY2USLMHUBPFRDGDT7LHPHKJWHDVXD7SD5OFSIBT3BJDDZO4PDQZQ2SBWHU3L5YTB5F7CPGHUZUBAAAAAAAAAAAAAAAAACAKAAAX7CUYLIPZBB2NU3HFA3VZZPIBMNKJFWD2AXSYRTBZ7VTXTVE3DR23R7ZB6XCZEAZ5QURR4XOHRYMYNJA3D2NV64JQ6S7RHTD2M2AQAAAAAAAAAAAAAAAA= \ No newline at end of file diff --git a/unison-src/transcripts/builtins.output.md b/unison-src/transcripts/builtins.output.md index 498f1a22f2..ca5db7a44c 100644 --- a/unison-src/transcripts/builtins.output.md +++ b/unison-src/transcripts/builtins.output.md @@ -459,7 +459,7 @@ test> Universal.murmurHash.tests = checks [Universal.murmurHash [1,2,3] == Unive 1 | > Universal.murmurHash 1 ⧩ - 5006114823290027883 + 1208954131003843843 2 | test> Universal.murmurHash.tests = checks [Universal.murmurHash [1,2,3] == Universal.murmurHash [1,2,3]]