Commit 3748ba3a authored by Brian Wignall's avatar Brian Wignall Committed by Marge Bot

Fix typos, using Wikipedia list of common typos

parent 5f84b52a
Pipeline #13270 passed with stages
in 494 minutes and 53 seconds
...@@ -407,7 +407,7 @@ where 'BIND' binds the monomorphic Ids 'fm' and 'gm', means ...@@ -407,7 +407,7 @@ where 'BIND' binds the monomorphic Ids 'fm' and 'gm', means
gp = ...same again, with gm instead of fm gp = ...same again, with gm instead of fm
The 'fwrap' is an impedence-matcher that typically does nothing; see The 'fwrap' is an impedance-matcher that typically does nothing; see
Note [ABExport wrapper]. Note [ABExport wrapper].
This is a pretty bad translation, because it duplicates all the bindings. This is a pretty bad translation, because it duplicates all the bindings.
......
...@@ -947,7 +947,7 @@ Main functions are: ...@@ -947,7 +947,7 @@ Main functions are:
* pmCheck :: PatVec -> [PatVec] -> ValVec -> Delta -> DsM PartialResult * pmCheck :: PatVec -> [PatVec] -> ValVec -> Delta -> DsM PartialResult
This function implements functions `covered`, `uncovered` and This function implements functions `covered`, `uncovered` and
`divergent` from the paper at once. Calls out to the auxilary function `divergent` from the paper at once. Calls out to the auxiliary function
`pmCheckGuards` for handling (possibly multiple) guarded RHSs when the whole `pmCheckGuards` for handling (possibly multiple) guarded RHSs when the whole
clause is checked. Slightly different from the paper because it does not even clause is checked. Slightly different from the paper because it does not even
produce the covered and uncovered sets. Since we only care about whether a produce the covered and uncovered sets. Since we only care about whether a
......
...@@ -180,7 +180,7 @@ cgBind (StgRec pairs) ...@@ -180,7 +180,7 @@ cgBind (StgRec pairs)
3. emit all the inits, and then all the bodies 3. emit all the inits, and then all the bodies
We'd rather not have separate functions to do steps 1 and 2 for We'd rather not have separate functions to do steps 1 and 2 for
each binding, since in pratice they share a lot of code. So we each binding, since in practice they share a lot of code. So we
have just one function, cgRhs, that returns a pair of the CgIdInfo have just one function, cgRhs, that returns a pair of the CgIdInfo
for step 1, and a monadic computation to generate the code in step for step 1, and a monadic computation to generate the code in step
2. 2.
......
...@@ -328,14 +328,14 @@ ldvEnterClosure :: ClosureInfo -> CmmReg -> FCode () ...@@ -328,14 +328,14 @@ ldvEnterClosure :: ClosureInfo -> CmmReg -> FCode ()
ldvEnterClosure closure_info node_reg = do ldvEnterClosure closure_info node_reg = do
dflags <- getDynFlags dflags <- getDynFlags
let tag = funTag dflags closure_info let tag = funTag dflags closure_info
-- don't forget to substract node's tag -- don't forget to subtract node's tag
ldvEnter (cmmOffsetB dflags (CmmReg node_reg) (-tag)) ldvEnter (cmmOffsetB dflags (CmmReg node_reg) (-tag))
ldvEnter :: CmmExpr -> FCode () ldvEnter :: CmmExpr -> FCode ()
-- Argument is a closure pointer -- Argument is a closure pointer
ldvEnter cl_ptr = do ldvEnter cl_ptr = do
dflags <- getDynFlags dflags <- getDynFlags
let -- don't forget to substract node's tag let -- don't forget to subtract node's tag
ldv_wd = ldvWord dflags cl_ptr ldv_wd = ldvWord dflags cl_ptr
new_ldv_wd = cmmOrWord dflags (cmmAndWord dflags (CmmLoad ldv_wd (bWord dflags)) new_ldv_wd = cmmOrWord dflags (cmmAndWord dflags (CmmLoad ldv_wd (bWord dflags))
(CmmLit (mkWordCLit dflags (iLDV_CREATE_MASK dflags)))) (CmmLit (mkWordCLit dflags (iLDV_CREATE_MASK dflags))))
......
...@@ -1059,7 +1059,7 @@ cvt_tup es boxity = do { let cvtl_maybe Nothing = return missingTupArg ...@@ -1059,7 +1059,7 @@ cvt_tup es boxity = do { let cvtl_maybe Nothing = return missingTupArg
(map noLoc es') (map noLoc es')
boxity } boxity }
{- Note [Operator assocation] {- Note [Operator association]
We must be quite careful about adding parens: We must be quite careful about adding parens:
* Infix (UInfix ...) op arg Needs parens round the first arg * Infix (UInfix ...) op arg Needs parens round the first arg
* Infix (Infix ...) op arg Needs parens round the first arg * Infix (Infix ...) op arg Needs parens round the first arg
......
...@@ -618,7 +618,7 @@ useCount _ = Many ...@@ -618,7 +618,7 @@ useCount _ = Many
* * * *
************************************************************************ ************************************************************************
This domain differst from JointDemand in the sence that pure absence This domain differst from JointDemand in the sense that pure absence
is taken away, i.e., we deal *only* with non-absent demands. is taken away, i.e., we deal *only* with non-absent demands.
Note [Strict demands] Note [Strict demands]
......
...@@ -402,7 +402,7 @@ But we don't do that for instance declarations and so we just treat ...@@ -402,7 +402,7 @@ But we don't do that for instance declarations and so we just treat
them all uniformly. them all uniformly.
The EXCEPTION is PrimOpIds, which do have rules in their IdInfo. That is The EXCEPTION is PrimOpIds, which do have rules in their IdInfo. That is
jsut for convenience really. just for convenience really.
However, LocalIds may have non-empty RuleInfo. We treat them However, LocalIds may have non-empty RuleInfo. We treat them
differently because: differently because:
......
...@@ -180,7 +180,7 @@ They only get converted into real Core, ...@@ -180,7 +180,7 @@ They only get converted into real Core,
during the CorePrep phase, although TidyPgm looks ahead at what the during the CorePrep phase, although TidyPgm looks ahead at what the
core will be, so that it can see whether it involves CAFs. core will be, so that it can see whether it involves CAFs.
When we initally build an Integer literal, notably when When we initially build an Integer literal, notably when
deserialising it from an interface file (see the Binary instance deserialising it from an interface file (see the Binary instance
below), we don't have convenient access to the mkInteger Id. So we below), we don't have convenient access to the mkInteger Id. So we
just use an error thunk, and fill in the real Id when we do tcIfaceLit just use an error thunk, and fill in the real Id when we do tcIfaceLit
......
...@@ -348,7 +348,7 @@ data ForeignLabelSource ...@@ -348,7 +348,7 @@ data ForeignLabelSource
-- external packages. It is safe to treat the RTS package as "external". -- external packages. It is safe to treat the RTS package as "external".
| ForeignLabelInExternalPackage | ForeignLabelInExternalPackage
-- | Label is in the package currenly being compiled. -- | Label is in the package currently being compiled.
-- This is only used for creating hacky tmp labels during code generation. -- This is only used for creating hacky tmp labels during code generation.
-- Don't use it in any code that might be inlined across a package boundary -- Don't use it in any code that might be inlined across a package boundary
-- (ie, core code) else the information will be wrong relative to the -- (ie, core code) else the information will be wrong relative to the
......
...@@ -669,7 +669,7 @@ scopeUniques (SubScope u _) = [u] ...@@ -669,7 +669,7 @@ scopeUniques (SubScope u _) = [u]
scopeUniques (CombinedScope s1 s2) = scopeUniques s1 ++ scopeUniques s2 scopeUniques (CombinedScope s1 s2) = scopeUniques s1 ++ scopeUniques s2
-- Equality and order is based on the head uniques defined above. We -- Equality and order is based on the head uniques defined above. We
-- take care to short-cut the (extremly) common cases. -- take care to short-cut the (extremely) common cases.
instance Eq CmmTickScope where instance Eq CmmTickScope where
GlobalScope == GlobalScope = True GlobalScope == GlobalScope = True
GlobalScope == _ = False GlobalScope == _ = False
......
...@@ -574,7 +574,7 @@ importName ...@@ -574,7 +574,7 @@ importName
:: { (FastString, CLabel) } :: { (FastString, CLabel) }
-- A label imported without an explicit packageId. -- A label imported without an explicit packageId.
-- These are taken to come frome some foreign, unnamed package. -- These are taken to come from some foreign, unnamed package.
: NAME : NAME
{ ($1, mkForeignLabel $1 Nothing ForeignLabelInExternalPackage IsFunction) } { ($1, mkForeignLabel $1 Nothing ForeignLabelInExternalPackage IsFunction) }
......
...@@ -542,7 +542,7 @@ A program has the Let-Unfoldings property iff: ...@@ -542,7 +542,7 @@ A program has the Let-Unfoldings property iff:
- For every let-bound variable f, whether top-level or nested, whether - For every let-bound variable f, whether top-level or nested, whether
recursive or not: recursive or not:
- Both the binding Id of f, and every occurence Id of f, has an idUnfolding. - Both the binding Id of f, and every occurrence Id of f, has an idUnfolding.
- For non-INLINE things, that unfolding will be f's right hand sids - For non-INLINE things, that unfolding will be f's right hand sids
- For INLINE things (which have a "stable" unfolding) that unfolding is - For INLINE things (which have a "stable" unfolding) that unfolding is
semantically equivalent to f's RHS, but derived from the original RHS of f semantically equivalent to f's RHS, but derived from the original RHS of f
...@@ -1226,11 +1226,11 @@ Here we implement the "push rules" from FC papers: ...@@ -1226,11 +1226,11 @@ Here we implement the "push rules" from FC papers:
(fun |> co) arg (fun |> co) arg
and we want to transform it to and we want to transform it to
(fun arg') |> co' (fun arg') |> co'
for some suitable co' and tranformed arg'. for some suitable co' and transformed arg'.
* The PushK rule for data constructors. We have * The PushK rule for data constructors. We have
(K e1 .. en) |> co (K e1 .. en) |> co
and we want to tranform to and we want to transform to
(K e1' .. en') (K e1' .. en')
by pushing the coercion into the arguments by pushing the coercion into the arguments
-} -}
......
...@@ -1227,7 +1227,7 @@ notOrphan _ = False ...@@ -1227,7 +1227,7 @@ notOrphan _ = False
chooseOrphanAnchor :: NameSet -> IsOrphan chooseOrphanAnchor :: NameSet -> IsOrphan
-- Something (rule, instance) is relate to all the Names in this -- Something (rule, instance) is relate to all the Names in this
-- list. Choose one of them to be an "anchor" for the orphan. We make -- list. Choose one of them to be an "anchor" for the orphan. We make
-- the choice deterministic to avoid gratuitious changes in the ABI -- the choice deterministic to avoid gratuitous changes in the ABI
-- hash (#4012). Specifically, use lexicographic comparison of -- hash (#4012). Specifically, use lexicographic comparison of
-- OccName rather than comparing Uniques -- OccName rather than comparing Uniques
-- --
...@@ -1559,7 +1559,7 @@ data UnfoldingGuidance ...@@ -1559,7 +1559,7 @@ data UnfoldingGuidance
ug_size :: Int, -- The "size" of the unfolding. ug_size :: Int, -- The "size" of the unfolding.
ug_res :: Int -- Scrutinee discount: the discount to substract if the thing is in ug_res :: Int -- Scrutinee discount: the discount to subtract if the thing is in
} -- a context (case (thing args) of ...), } -- a context (case (thing args) of ...),
-- (where there are the right number of arguments.) -- (where there are the right number of arguments.)
......
...@@ -528,7 +528,7 @@ In the above example, suppose we had ...@@ -528,7 +528,7 @@ In the above example, suppose we had
{-# RULES "rule-for-g" forally. g [y] = ... #-} {-# RULES "rule-for-g" forally. g [y] = ... #-}
Then "rule-for-f" and "rule-for-g" would compete. Better to add phase Then "rule-for-f" and "rule-for-g" would compete. Better to add phase
control, so "rule-for-f" has a chance to fire before "rule-for-g" becomes control, so "rule-for-f" has a chance to fire before "rule-for-g" becomes
active; or perhpas after "rule-for-g" has become inactive. This is checked active; or perhaps after "rule-for-g" has become inactive. This is checked
by 'competesWith' by 'competesWith'
Class methods have a built-in RULE to select the method from the dictionary, Class methods have a built-in RULE to select the method from the dictionary,
......
...@@ -279,7 +279,7 @@ in repTyClD and repC. ...@@ -279,7 +279,7 @@ in repTyClD and repC.
Note [Don't quantify implicit type variables in quotes] Note [Don't quantify implicit type variables in quotes]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If you're not careful, it's suprisingly easy to take this quoted declaration: If you're not careful, it's surprisingly easy to take this quoted declaration:
[d| idProxy :: forall proxy (b :: k). proxy b -> proxy b [d| idProxy :: forall proxy (b :: k). proxy b -> proxy b
idProxy x = x idProxy x = x
...@@ -1404,7 +1404,7 @@ repE e@(HsTickPragma {}) = notHandled "Tick Pragma" (ppr e) ...@@ -1404,7 +1404,7 @@ repE e@(HsTickPragma {}) = notHandled "Tick Pragma" (ppr e)
repE e = notHandled "Expression form" (ppr e) repE e = notHandled "Expression form" (ppr e)
----------------------------------------------------------------------------- -----------------------------------------------------------------------------
-- Building representations of auxillary structures like Match, Clause, Stmt, -- Building representations of auxiliary structures like Match, Clause, Stmt,
repMatchTup :: LMatch GhcRn (LHsExpr GhcRn) -> DsM (Core TH.MatchQ) repMatchTup :: LMatch GhcRn (LHsExpr GhcRn) -> DsM (Core TH.MatchQ)
repMatchTup (dL->L _ (Match { m_pats = [p] repMatchTup (dL->L _ (Match { m_pats = [p]
...@@ -1481,7 +1481,7 @@ repUpdFields = repList fieldExpQTyConName rep_fld ...@@ -1481,7 +1481,7 @@ repUpdFields = repList fieldExpQTyConName rep_fld
-- shadow each other. Consider: [| do { x <- f 1; x <- f x; g x } |] -- shadow each other. Consider: [| do { x <- f 1; x <- f x; g x } |]
-- First gensym new names for every variable in any of the patterns. -- First gensym new names for every variable in any of the patterns.
-- both static (x'1 and x'2), and dynamic ((gensym "x") and (gensym "y")) -- both static (x'1 and x'2), and dynamic ((gensym "x") and (gensym "y"))
-- if variables didn't shaddow, the static gensym wouldn't be necessary -- if variables didn't shadow, the static gensym wouldn't be necessary
-- and we could reuse the original names (x and x). -- and we could reuse the original names (x and x).
-- --
-- do { x'1 <- gensym "x" -- do { x'1 <- gensym "x"
......
...@@ -530,7 +530,7 @@ dsExtendMetaEnv menv thing_inside ...@@ -530,7 +530,7 @@ dsExtendMetaEnv menv thing_inside
discardWarningsDs :: DsM a -> DsM a discardWarningsDs :: DsM a -> DsM a
-- Ignore warnings inside the thing inside; -- Ignore warnings inside the thing inside;
-- used to ignore inaccessable cases etc. inside generated code -- used to ignore inaccessible cases etc. inside generated code
discardWarningsDs thing_inside discardWarningsDs thing_inside
= do { env <- getGblEnv = do { env <- getGblEnv
; old_msgs <- readTcRef (ds_msgs env) ; old_msgs <- readTcRef (ds_msgs env)
......
...@@ -402,7 +402,7 @@ bar (x :: forall a. a -> a) = ... -- a is not in scope here ...@@ -402,7 +402,7 @@ bar (x :: forall a. a -> a) = ... -- a is not in scope here
bax (x :: a) = ... -- a is in scope here bax (x :: a) = ... -- a is in scope here
Because of HsWC and HsIB pass on their scope to their children Because of HsWC and HsIB pass on their scope to their children
we must wrap the LHsType in pattern signatures in a we must wrap the LHsType in pattern signatures in a
Shielded explictly, so that the HsWC/HsIB scope is not passed Shielded explicitly, so that the HsWC/HsIB scope is not passed
on the the LHsType on the the LHsType
-} -}
......
...@@ -117,7 +117,7 @@ writeHieFile hie_file_path hiefile = do ...@@ -117,7 +117,7 @@ writeHieFile hie_file_path hiefile = do
symtab_p_p <- tellBin bh0 symtab_p_p <- tellBin bh0
put_ bh0 symtab_p_p put_ bh0 symtab_p_p
-- Make some intial state -- Make some initial state
symtab_next <- newFastMutInt symtab_next <- newFastMutInt
writeFastMutInt symtab_next 0 writeFastMutInt symtab_next 0
symtab_map <- newIORef emptyUFM symtab_map <- newIORef emptyUFM
......
...@@ -885,7 +885,7 @@ ppr_ty ctxt_prec (IfaceCoercionTy co) ...@@ -885,7 +885,7 @@ ppr_ty ctxt_prec (IfaceCoercionTy co)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
RuntimeRep variables are considered by many (most?) users to be little RuntimeRep variables are considered by many (most?) users to be little
more than syntactic noise. When the notion was introduced there was a more than syntactic noise. When the notion was introduced there was a
signficant and understandable push-back from those with pedagogy in significant and understandable push-back from those with pedagogy in
mind, which argued that RuntimeRep variables would throw a wrench into mind, which argued that RuntimeRep variables would throw a wrench into
nearly any teach approach since they appear in even the lowly ($) nearly any teach approach since they appear in even the lowly ($)
function's type, function's type,
......
...@@ -549,7 +549,7 @@ But there is a HORRIBLE HACK here. ...@@ -549,7 +549,7 @@ But there is a HORRIBLE HACK here.
* And that means we end up loading M.hi-boot, because those * And that means we end up loading M.hi-boot, because those
data types are not yet in the type environment. data types are not yet in the type environment.
But in this wierd case, /all/ we need is the types. We don't need But in this weird case, /all/ we need is the types. We don't need
instances, rules etc. And if we put the instances in the EPS instances, rules etc. And if we put the instances in the EPS
we get "duplicate instance" warnings when we compile the "real" we get "duplicate instance" warnings when we compile the "real"
instance in M itself. Hence the strange business of just updateing instance in M itself. Hence the strange business of just updateing
......
...@@ -879,7 +879,7 @@ the whole thing with 'withTiming'. Instead we wrap the processing of each ...@@ -879,7 +879,7 @@ the whole thing with 'withTiming'. Instead we wrap the processing of each
individual stream element, all along the codegen pipeline, using the appropriate individual stream element, all along the codegen pipeline, using the appropriate
label for the pass to which this processing belongs. That generates a lot more label for the pass to which this processing belongs. That generates a lot more
data but allows us to get fine-grained timings about all the passes and we can data but allows us to get fine-grained timings about all the passes and we can
easily compute totals withh tools like ghc-events-analyze (see below). easily compute totals with tools like ghc-events-analyze (see below).
Producing an eventlog for GHC Producing an eventlog for GHC
......
...@@ -730,7 +730,7 @@ findPartiallyCompletedCycles modsDone theGraph ...@@ -730,7 +730,7 @@ findPartiallyCompletedCycles modsDone theGraph
-- --
-- | Unloading -- | Unloading
unload :: HscEnv -> [Linkable] -> IO () unload :: HscEnv -> [Linkable] -> IO ()
unload hsc_env stable_linkables -- Unload everthing *except* 'stable_linkables' unload hsc_env stable_linkables -- Unload everything *except* 'stable_linkables'
= case ghcLink (hsc_dflags hsc_env) of = case ghcLink (hsc_dflags hsc_env) of
LinkInMemory -> Linker.unload hsc_env stable_linkables LinkInMemory -> Linker.unload hsc_env stable_linkables
_other -> return () _other -> return ()
......
...@@ -2135,7 +2135,7 @@ isDllName dflags this_mod name ...@@ -2135,7 +2135,7 @@ isDllName dflags this_mod name
-- On Windows the hack for #8696 makes it unlinkable. -- On Windows the hack for #8696 makes it unlinkable.
-- As the entire setup of the code from Cmm down to the RTS expects -- As the entire setup of the code from Cmm down to the RTS expects
-- the use of trampolines for the imported functions only when -- the use of trampolines for the imported functions only when
-- doing intra-package linking, e.g. refering to a symbol defined in the same -- doing intra-package linking, e.g. referring to a symbol defined in the same
-- package should not use a trampoline. -- package should not use a trampoline.
-- I much rather have dynamic TH not supported than the entire Dynamic linking -- I much rather have dynamic TH not supported than the entire Dynamic linking
-- not due to a hack. -- not due to a hack.
......
...@@ -1280,7 +1280,7 @@ So we have to *predict* the result here, which is revolting. ...@@ -1280,7 +1280,7 @@ So we have to *predict* the result here, which is revolting.
In particular CorePrep expands Integer and Natural literals. So in the In particular CorePrep expands Integer and Natural literals. So in the
prediction code here we resort to applying the same expansion (cvt_literal). prediction code here we resort to applying the same expansion (cvt_literal).
There are also numberous other ways in which we can introduce inconsistencies There are also numerous other ways in which we can introduce inconsistencies
between CorePrep and TidyPgm. See Note [CAFfyness inconsistencies due to eta between CorePrep and TidyPgm. See Note [CAFfyness inconsistencies due to eta
expansion in TidyPgm] for one such example. expansion in TidyPgm] for one such example.
......
...@@ -9,7 +9,7 @@ import Fingerprint ...@@ -9,7 +9,7 @@ import Fingerprint
-- | Settings for other executables GHC calls. -- | Settings for other executables GHC calls.
-- --
-- Probably should futher split down by phase, or split between -- Probably should further split down by phase, or split between
-- platform-specific and platform-agnostic. -- platform-specific and platform-agnostic.
data ToolSettings = ToolSettings data ToolSettings = ToolSettings
{ toolSettings_ldSupportsCompactUnwind :: Bool { toolSettings_ldSupportsCompactUnwind :: Bool
......
...@@ -79,7 +79,7 @@ import Control.Monad (foldM) ...@@ -79,7 +79,7 @@ import Control.Monad (foldM)
Edge weights not only represent likelyhood of control transfer between blocks Edge weights not only represent likelyhood of control transfer between blocks
but also how much a block would benefit from being placed sequentially after but also how much a block would benefit from being placed sequentially after
it's predecessor. it's predecessor.
For example blocks which are preceeded by an info table are more likely to end For example blocks which are preceded by an info table are more likely to end
up in a different cache line than their predecessor and we can't eliminate the jump up in a different cache line than their predecessor and we can't eliminate the jump
so there is less benefit to placing them sequentially. so there is less benefit to placing them sequentially.
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
-- --
-- TODO: Signed vs unsigned? -- TODO: Signed vs unsigned?
-- --
-- TODO: This module is currenly shared by all architectures because -- TODO: This module is currently shared by all architectures because
-- NCGMonad need to know about it to make a VReg. It would be better -- NCGMonad need to know about it to make a VReg. It would be better
-- to have architecture specific formats, and do the overloading -- to have architecture specific formats, and do the overloading
-- properly. eg SPARC doesn't care about FF80. -- properly. eg SPARC doesn't care about FF80.
......
...@@ -420,7 +420,7 @@ picRelative dflags arch OSDarwin lbl ...@@ -420,7 +420,7 @@ picRelative dflags arch OSDarwin lbl
-- On AIX we use an indirect local TOC anchored by 'gotLabel'. -- On AIX we use an indirect local TOC anchored by 'gotLabel'.
-- This way we use up only one global TOC entry per compilation-unit -- This way we use up only one global TOC entry per compilation-unit
-- (this is quite similiar to GCC's @-mminimal-toc@ compilation mode) -- (this is quite similar to GCC's @-mminimal-toc@ compilation mode)
picRelative dflags _ OSAIX lbl picRelative dflags _ OSAIX lbl
= CmmLabelDiffOff lbl gotLabel 0 (wordWidth dflags) = CmmLabelDiffOff lbl gotLabel 0 (wordWidth dflags)
...@@ -623,7 +623,7 @@ pprImportedSymbol _ (Platform { platformMini = PlatformMini { platformMini_os = ...@@ -623,7 +623,7 @@ pprImportedSymbol _ (Platform { platformMini = PlatformMini { platformMini_os =
-- XCOFF / AIX -- XCOFF / AIX
-- --
-- Similiar to PPC64 ELF v1, there's dedicated TOC register (r2). To -- Similar to PPC64 ELF v1, there's dedicated TOC register (r2). To
-- workaround the limitation of a global TOC we use an indirect TOC -- workaround the limitation of a global TOC we use an indirect TOC
-- with the label `ghc_toc_table`. -- with the label `ghc_toc_table`.
-- --
......
...@@ -1690,7 +1690,7 @@ genCCall' dflags gcp target dest_regs args ...@@ -1690,7 +1690,7 @@ genCCall' dflags gcp target dest_regs args
`appOL` codeAfter) `appOL` codeAfter)
GCPAIX -> return ( dynCode GCPAIX -> return ( dynCode
-- AIX/XCOFF follows the PowerOPEN ABI -- AIX/XCOFF follows the PowerOPEN ABI
-- which is quite similiar to LinuxPPC64/ELFv1 -- which is quite similar to LinuxPPC64/ELFv1
`appOL` codeBefore `appOL` codeBefore
`snocOL` ST spFormat toc (AddrRegImm sp (ImmInt 20)) `snocOL` ST spFormat toc (AddrRegImm sp (ImmInt 20))
`snocOL` LD II32 r11 (AddrRegImm dynReg (ImmInt 0)) `snocOL` LD II32 r11 (AddrRegImm dynReg (ImmInt 0))
......
...@@ -297,7 +297,7 @@ patchInstr ...@@ -297,7 +297,7 @@ patchInstr
patchInstr reg instr patchInstr reg instr
= do nUnique <- newUnique = do nUnique <- newUnique
-- The register we're rewriting is suppoed to be virtual. -- The register we're rewriting is supposed to be virtual.
-- If it's not then something has gone horribly wrong. -- If it's not then something has gone horribly wrong.
let nReg let nReg
= case reg of = case reg of
......
...@@ -297,7 +297,7 @@ nodeDegree classOfVirtualReg graph reg ...@@ -297,7 +297,7 @@ nodeDegree classOfVirtualReg graph reg
-- | Show a spill cost record, including the degree from the graph -- | Show a spill cost record, including the degree from the graph
-- and final calulated spill cost. -- and final calculated spill cost.
pprSpillCostRecord pprSpillCostRecord
:: (VirtualReg -> RegClass) :: (VirtualReg -> RegClass)
-> (Reg -> SDoc) -> (Reg -> SDoc)
......
...@@ -12,7 +12,7 @@ import Unique ...@@ -12,7 +12,7 @@ import Unique
-- | The class of a register. -- | The class of a register.
-- Used in the register allocator. -- Used in the register allocator.
-- We treat all registers in a class as being interchangable. -- We treat all registers in a class as being interchangeable.
-- --
data RegClass data RegClass
= RcInteger = RcInteger
......
...@@ -51,7 +51,7 @@ expandBlockInstrs (ii:is) ...@@ -51,7 +51,7 @@ expandBlockInstrs (ii:is)
-- | In the SPARC instruction set the FP register pairs that are used -- | In the SPARC instruction set the FP register pairs that are used
-- to hold 64 bit floats are refered to by just the first reg -- to hold 64 bit floats are referred to by just the first reg
-- of the pair. Remap our internal reg pairs to the appropriate reg. -- of the pair. Remap our internal reg pairs to the appropriate reg.
-- --
-- For example: -- For example:
......
...@@ -816,7 +816,7 @@ x86_mkJumpInstr id ...@@ -816,7 +816,7 @@ x86_mkJumpInstr id
-- | | -- | |
-- +-------------------+ -- +-------------------+
-- --
-- In essense each allocation larger than a page size needs to be chunked and -- In essence each allocation larger than a page size needs to be chunked and
-- a probe emitted after each page allocation. You have to hit the guard -- a probe emitted after each page allocation. You have to hit the guard
-- page so the kernel can map in the next page, otherwise you'll segfault. -- page so the kernel can map in the next page, otherwise you'll segfault.
-- --
......
...@@ -2247,7 +2247,7 @@ with constructor names (see Note [Parsing data constructors is hard]). ...@@ -2247,7 +2247,7 @@ with constructor names (see Note [Parsing data constructors is hard]).
Due to simplified syntax, GADT constructor names (left-hand side of '::') Due to simplified syntax, GADT constructor names (left-hand side of '::')
use simpler grammar production than usual data constructor names. As a use simpler grammar production than usual data constructor names. As a
consequence, GADT constructor names are resticted (names like '(*)' are consequence, GADT constructor names are restricted (names like '(*)' are
allowed in usual data constructors, but not in GADTs). allowed in usual data constructors, but not in GADTs).
-} -}
......
...@@ -564,7 +564,7 @@ declarations and types as a reversed list of TyEl: ...@@ -564,7 +564,7 @@ declarations and types as a reversed list of TyEl:
| TyElOpd (HsType GhcPs) | TyElOpd (HsType GhcPs)
| ... | ...
For example, both occurences of (C ! D) in the following example are parsed For example, both occurrences of (C ! D) in the following example are parsed
into equal lists of TyEl: into equal lists of TyEl:
data T = C ! D => C ! D results in [ TyElOpd (HsTyVar "D") data T = C ! D => C ! D results in [ TyElOpd (HsTyVar "D")
...@@ -2878,7 +2878,7 @@ failOpNotEnabledImportQualifiedPost loc = addError loc msg ...@@ -2878,7 +2878,7 @@ failOpNotEnabledImportQualifiedPost loc = addError loc msg
failOpImportQualifiedTwice :: SrcSpan -> P () failOpImportQualifiedTwice :: SrcSpan -> P ()
failOpImportQualifiedTwice loc = addError loc msg failOpImportQualifiedTwice loc = addError loc msg
where where
msg = text "Multiple occurences of 'qualified'" msg = text "Multiple occurrences of 'qualified'"
warnStarIsType :: SrcSpan -> P () warnStarIsType :: SrcSpan -> P ()
warnStarIsType span = addWarning Opt_WarnStarIsType span msg warnStarIsType span = addWarning Opt_WarnStarIsType span msg
......
...@@ -734,7 +734,7 @@ There are two cases: ...@@ -734,7 +734,7 @@ There are two cases:
and match_Integer_shift_op. and match_Integer_shift_op.
Here we could in principle shift by any amount, but we arbitary Here we could in principle shift by any amount, but we arbitary
limit the shift to 4 bits; in particualr we do not want shift by a limit the shift to 4 bits; in particular we do not want shift by a
huge amount, which can happen in code like that above. huge amount, which can happen in code like that above.
The two cases are more different in their code paths that is comfortable, The two cases are more different in their code paths that is comfortable,
......
...@@ -2057,7 +2057,7 @@ primop FetchAddByteArrayOp_Int "fetchAddIntArray#" GenPrimOp ...@@ -2057,7 +2057,7 @@ primop FetchAddByteArrayOp_Int "fetchAddIntArray#" GenPrimOp
primop FetchSubByteArrayOp_Int "fetchSubIntArray#" GenPrimOp primop FetchSubByteArrayOp_Int "fetchSubIntArray#" GenPrimOp
MutableByteArray# s -> Int# -> Int# -> State# s -> (# State# s, Int# #) MutableByteArray# s -> Int# -> Int# -> State# s -> (# State# s, Int# #)
{Given an array, and offset in machine words, and a value to subtract, {Given an array, and offset in machine words, and a value to subtract,
atomically substract the value to the element. Returns the value of atomically subtract the value to the element. Returns the value of
the element before the operation. Implies a full memory barrier.} the element before the operation. Implies a full memory barrier.}
with has_side_effects = True with has_side_effects = True
can_fail = True can_fail = True
......
...@@ -1137,7 +1137,7 @@ constructor namespace before looking in the data constructor namespace to ...@@ -1137,7 +1137,7 @@ constructor namespace before looking in the data constructor namespace to
deal with `DataKinds`. deal with `DataKinds`.
There is however, as always, one exception to this scheme. If we find There is however, as always, one exception to this scheme. If we find
an ambiguous occurence of a record selector and DuplicateRecordFields an ambiguous occurrence of a record selector and DuplicateRecordFields
is enabled then we defer the selection until the typechecker. is enabled then we defer the selection until the typechecker.
-} -}
......
...@@ -686,7 +686,7 @@ rnFamInstEqn doc atfi rhs_kvars ...@@ -686,7 +686,7 @@ rnFamInstEqn doc atfi rhs_kvars
; tycon' <- lookupFamInstName mb_cls tycon ; tycon' <- lookupFamInstName mb_cls tycon
; let pat_kity_vars_with_dups = extractHsTyArgRdrKiTyVarsDup pats ; let pat_kity_vars_with_dups = extractHsTyArgRdrKiTyVarsDup pats
-- Use the "...Dups" form because it's needed -- Use the "...Dups" form because it's needed
-- below to report unsed binder on the LHS -- below to report unused binder on the LHS
-- Implicitly bound variables, empty if we have an explicit 'forall' according -- Implicitly bound variables, empty if we have an explicit 'forall' according
-- to the "forall-or-nothing" rule. -- to the "forall-or-nothing" rule.
......
...@@ -1653,7 +1653,7 @@ extractHsTysRdrTyVarsDups :: [LHsType GhcPs] -> FreeKiTyVarsWithDups ...@@ -1653,7 +1653,7 @@ extractHsTysRdrTyVarsDups :: [LHsType GhcPs] -> FreeKiTyVarsWithDups
extractHsTysRdrTyVarsDups tys extractHsTysRdrTyVarsDups tys
= extract_ltys tys [] = extract_ltys tys []
-- Returns the free kind variables of any explictly-kinded binders, returning -- Returns the free kind variables of any explicitly-kinded binders, returning
-- variable occurrences in l