Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Open sidebar
Alex D
GHC
Commits
429397f2
Commit
429397f2
authored
Oct 04, 2013
by
Simon Peyton Jones
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Comments only
parent
30a046fb
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
1 deletion
+8
-1
compiler/codeGen/StgCmmArgRep.hs
compiler/codeGen/StgCmmArgRep.hs
+7
-1
compiler/ghci/ByteCodeGen.lhs
compiler/ghci/ByteCodeGen.lhs
+1
-0
No files found.
compiler/codeGen/StgCmmArgRep.hs
View file @
429397f2
...
...
@@ -122,9 +122,15 @@ idArgRep = toArgRep . idPrimRep
--
-- NSF 6 Mar 2013
-- These cases were found to cover about 99% of all slow calls:
slowCallPattern
::
[
ArgRep
]
->
(
FastString
,
RepArity
)
-- Returns the generic apply function and arity
--
-- The first batch of cases match (some) specialised entries
-- The last group deals exhaustively with the cases for the first argument
-- (and the zero-argument case)
--
-- In 99% of cases this function will match *all* the arguments in one batch
slowCallPattern
(
P
:
P
:
P
:
P
:
P
:
P
:
_
)
=
(
fsLit
"stg_ap_pppppp"
,
6
)
slowCallPattern
(
P
:
P
:
P
:
P
:
P
:
_
)
=
(
fsLit
"stg_ap_ppppp"
,
5
)
slowCallPattern
(
P
:
P
:
P
:
P
:
_
)
=
(
fsLit
"stg_ap_pppp"
,
4
)
...
...
compiler/ghci/ByteCodeGen.lhs
View file @
429397f2
...
...
@@ -1166,6 +1166,7 @@ maybe_getCCallReturnRep fn_ty
-- Compile code which expects an unboxed Int on the top of stack,
-- (call it i), and pushes the i'th closure in the supplied list
-- as a consequence.
-- The [Name] is a list of the constructors of this (enumeration) type
implement_tagToId :: [Name] -> BcM BCInstrList
implement_tagToId names
= ASSERT( notNull names )
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment