Commit a12162ea authored by simonm's avatar simonm
Browse files

[project @ 1997-09-24 11:08:42 by simonm]

test updates
parent 432766df
TOP = .
include $(TOP)/mk/boilerplate.mk
SUBDIRS = ccall deriving deSugar printing reader rename simplCore typecheck
SUBDIRS =
ccall \
codeGen \
deSugar \
deriving \
io \
printing \
reader \
rename \
simplCore \
stranal \
typecheck
#programs
......
......@@ -7,12 +7,12 @@ HC_OPTS += -dcore-lint -fglasgow-exts
# Note that these tests are still in a state of flux... don't believe errors
# they report. In fact, these aren't really very good tests at all...
cc001_HC_OPTS = -noC -ddump-tc -ddump-ds
cc002_HC_OPTS = -noC -ddump-tc -ddump-ds
cc003_HC_OPTS = -noC -ddump-tc -ddump-ds
cc004_HC_OPTS = -noC -ddump-tc -ddump-ds
cc005_HC_OPTS = -fvia-C -ddump-stg -ddump-flatC
cc006_HC_OPTS = -fvia-C -ddump-stg -ddump-flatC
cc007_HC_OPTS = -fvia-C -ddump-stg -ddump-flatC
cc001_HC_OPTS = -noC
cc002_HC_OPTS = -noC
cc003_HC_OPTS = -noC
cc004_HC_OPTS = -noC
cc005_HC_OPTS = -fvia-C
cc006_HC_OPTS = -fvia-C
cc007_HC_OPTS = -fvia-C
include $(TOP)/mk/target.mk
================================================================================
Typechecked:
AbsBinds [] [] [([], c{-r5,x-}, c_aZc)]
c_aZc x1_r4l x2_r4m x3_r4n x4_r4o
= STBase.ST{-5G,w-}{i}
[GHC.RealWorld{-3s,W-}, PrelBase.Float{-3c,W-}] _ccall_ c
x1_r4l x2_r4m x3_r4n x4_r4o
AbsBinds [] [] [([], b{-r3,x-}, b_aZE)]
b_aZE x_r4j
= STBase.ST{-5G,w-}{i}
[GHC.RealWorld{-3s,W-}, PrelBase.Int{-3g,W-}] _ccall_ b x_r4j
AbsBinds [] [] [([], a{-r1,x-}, a_aZR)]
a_aZR
= STBase.ST{-5G,w-}{i}
[GHC.RealWorld{-3s,W-}, PrelBase.Int{-3g,W-}] _ccall_ a
AbsBinds [] [] [([], d{-r7,x-}, d_aZY)]
d_aZY
= STBase.thenPrimIO{-r4t,p-}
[PrelBase.Int{-3g,W-}, PrelBase.Float{-3c,W-}]
a{-r1,x-}
(\ x_r4q
-> STBase.thenPrimIO{-r4t,p-}
[PrelBase.Int{-3g,W-}, PrelBase.Float{-3c,W-}]
(b{-r3,x-} x_r4q)
(\ y_r4s -> c{-r5,x-} y_r4s 'f' lit_a10r lit_a10t))
d.Fractional_a10l = PrelNum.$d23{-rsg,p-}
fromRational_a10q =
PrelNum.fromRational{-8T,p-} PrelBase.Float{-3c,W-}
d.Fractional_a10l
lit_a10r = fromRational_a10q 1.0000000000000000
d.Fractional_a10p = PrelNum.$d14{-rs6,p-}
fromRational_a10s =
PrelNum.fromRational{-8T,p-} PrelBase.Double{-3a,W-}
d.Fractional_a10p
lit_a10t = fromRational_a10s 2.0000000000000000
================================================================================
Desugared:
Rec {
c_aZc :: PrelBase.Int{-3g,W-}
-> PrelBase.Char{-38,W-}
-> PrelBase.Float{-3c,W-}
-> PrelBase.Double{-3a,W-}
-> STBase.PrimIO{-3P,W-} PrelBase.Float{-3c,W-}
{-# L #-}
c_aZc =
\ x1_r4l :: PrelBase.Int{-3g,W-}
{-# L #-}
x1_r4l x2_r4m :: PrelBase.Char{-38,W-}
{-# L #-}
x2_r4m x3_r4n :: PrelBase.Float{-3c,W-}
{-# L #-}
x3_r4n x4_r4o :: PrelBase.Double{-3a,W-}
{-# L #-}
x4_r4o ->
let {
ds_d17v :: STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
-> (PrelBase.Float{-3c,W-}, STBase.State{-3M,W-} GHC.RealWorld{-3s,W-})
{-# L #-}
ds_d17v =
\ ds_d17B :: STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
{-# L #-}
ds_d17B ->
case ds_d17B of { STBase.S#{-5D,w-}{i} ds_d18A ->
case x1_r4l of { PrelBase.I#{-5b,w-}{i} ds_d18J ->
case x2_r4m of { PrelBase.C#{-54,w-}{i} ds_d18S ->
case x3_r4n of { PrelBase.F#{-59,w-}{i} ds_d191 ->
case x4_r4o of { PrelBase.D#{-56,w-}{i} ds_d19o ->
case
_ccall_ c [(STBase.StateAndFloat#{-3C,W-} GHC.RealWorld{-3s,W-}) (GHC.State#{-3L,W-} GHC.RealWorld{-3s,W-}) GHC.Int#{-3f,W-} GHC.Char#{-37,W-} GHC.Float#{-3b,W-} GHC.Double#{-39,W-}]!
ds_d18A ds_d18J ds_d18S ds_d191 ds_d19o
of {
STBase.StateAndFloat#{-5u,w-}{i} ds_d19R ds_d19P ->
let {
ds_d19G :: PrelBase.Float{-3c,W-}
{-# L #-}
ds_d19G =
PrelBase.F#{-59,w-}{i} {ds_d19P} } in
let {
ds_d19K :: STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
{-# L #-}
ds_d19K =
STBase.S#{-5D,w-}{i} {_@_ GHC.RealWorld{-3s,W-} ds_d19R}
} in
PrelTup.(,){-62,w-}{i}
{_@_ PrelBase.Float{-3c,W-}
_@_ (STBase.State{-3M,W-} GHC.RealWorld{-3s,W-})
ds_d19G
ds_d19K};};};};};};}
} in
STBase.ST{-5G,w-}{i}
_@_ GHC.RealWorld{-3s,W-} _@_ PrelBase.Float{-3c,W-} ds_d17v
c{-r5,x-} :: PrelBase.Int{-3g,W-}
-> PrelBase.Char{-38,W-}
-> PrelBase.Float{-3c,W-}
-> PrelBase.Double{-3a,W-}
-> STBase.PrimIO{-3P,W-} PrelBase.Float{-3c,W-}
{-# L #-}
c{-r5,x-} =
c_aZc
b_aZE :: PrelBase.Int{-3g,W-}
-> STBase.PrimIO{-3P,W-} PrelBase.Int{-3g,W-}
{-# L #-}
b_aZE =
\ x_r4j :: PrelBase.Int{-3g,W-}
{-# L #-}
x_r4j ->
let {
ds_d1ab :: STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
-> (PrelBase.Int{-3g,W-}, STBase.State{-3M,W-} GHC.RealWorld{-3s,W-})
{-# L #-}
ds_d1ab =
\ ds_d1ah :: STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
{-# L #-}
ds_d1ah ->
case ds_d1ah of { STBase.S#{-5D,w-}{i} ds_d1aq ->
case x_r4j of { PrelBase.I#{-5b,w-}{i} ds_d1aE ->
case
_ccall_ b [(STBase.StateAndInt#{-3D,W-} GHC.RealWorld{-3s,W-}) (GHC.State#{-3L,W-} GHC.RealWorld{-3s,W-}) GHC.Int#{-3f,W-}]!
ds_d1aq ds_d1aE
of {
STBase.StateAndInt#{-5v,w-}{i} ds_d1b7 ds_d1b5 ->
let {
ds_d1aW :: PrelBase.Int{-3g,W-}
{-# L #-}
ds_d1aW =
PrelBase.I#{-5b,w-}{i} {ds_d1b5} } in
let {
ds_d1b0 :: STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
{-# L #-}
ds_d1b0 =
STBase.S#{-5D,w-}{i} {_@_ GHC.RealWorld{-3s,W-} ds_d1b7}
} in
PrelTup.(,){-62,w-}{i}
{_@_ PrelBase.Int{-3g,W-}
_@_ (STBase.State{-3M,W-} GHC.RealWorld{-3s,W-})
ds_d1aW
ds_d1b0};};};}
} in
STBase.ST{-5G,w-}{i}
_@_ GHC.RealWorld{-3s,W-} _@_ PrelBase.Int{-3g,W-} ds_d1ab
b{-r3,x-} :: PrelBase.Int{-3g,W-}
-> STBase.PrimIO{-3P,W-} PrelBase.Int{-3g,W-}
{-# L #-}
b{-r3,x-} =
b_aZE
a_aZR :: STBase.PrimIO{-3P,W-} PrelBase.Int{-3g,W-}
{-# L #-}
a_aZR =
let {
ds_d1bq :: STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
-> (PrelBase.Int{-3g,W-}, STBase.State{-3M,W-} GHC.RealWorld{-3s,W-})
{-# L #-}
ds_d1bq =
\ ds_d1bw :: STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
{-# L #-}
ds_d1bw ->
case ds_d1bw of { STBase.S#{-5D,w-}{i} ds_d1bH ->
case
_ccall_ a [(STBase.StateAndInt#{-3D,W-} GHC.RealWorld{-3s,W-}) (GHC.State#{-3L,W-} GHC.RealWorld{-3s,W-})]!
ds_d1bH
of {
STBase.StateAndInt#{-5v,w-}{i} ds_d1ca ds_d1c8 ->
let {
ds_d1bZ :: PrelBase.Int{-3g,W-}
{-# L #-}
ds_d1bZ =
PrelBase.I#{-5b,w-}{i} {ds_d1c8} } in
let {
ds_d1c3 :: STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
{-# L #-}
ds_d1c3 =
STBase.S#{-5D,w-}{i} {_@_ GHC.RealWorld{-3s,W-} ds_d1ca}
} in
PrelTup.(,){-62,w-}{i}
{_@_ PrelBase.Int{-3g,W-}
_@_ (STBase.State{-3M,W-} GHC.RealWorld{-3s,W-})
ds_d1bZ
ds_d1c3};};}
} in
STBase.ST{-5G,w-}{i}
_@_ GHC.RealWorld{-3s,W-} _@_ PrelBase.Int{-3g,W-} ds_d1bq
a{-r1,x-} :: STBase.PrimIO{-3P,W-} PrelBase.Int{-3g,W-}
{-# L #-}
a{-r1,x-} =
a_aZR
d_aZY :: STBase.PrimIO{-3P,W-} PrelBase.Float{-3c,W-}
{-# L #-}
d_aZY =
let {
ds_d1cw :: PrelBase.Int{-3g,W-}
-> STBase.PrimIO{-3P,W-} PrelBase.Float{-3c,W-}
{-# L #-}
ds_d1cw =
\ x_r4q :: PrelBase.Int{-3g,W-}
{-# L #-}
x_r4q ->
let {
ds_d1cL :: STBase.PrimIO{-3P,W-} PrelBase.Int{-3g,W-}
{-# L #-}
ds_d1cL =
b{-r3,x-} x_r4q } in
let {
ds_d1cP :: PrelBase.Int{-3g,W-}
-> STBase.PrimIO{-3P,W-} PrelBase.Float{-3c,W-}
{-# L #-}
ds_d1cP =
\ y_r4s :: PrelBase.Int{-3g,W-}
{-# L #-}
y_r4s ->
(let {
ds_d1df :: PrelBase.Char{-38,W-}
{-# L #-}
ds_d1df =
PrelBase.C#{-54,w-}{i} {'f'}
} in c{-r5,x-} y_r4s ds_d1df)
lit_a10r lit_a10t
} in
STBase.thenPrimIO{-r4t,p-}
_@_ PrelBase.Int{-3g,W-} _@_ PrelBase.Float{-3c,W-} ds_d1cL ds_d1cP
} in
STBase.thenPrimIO{-r4t,p-}
_@_ PrelBase.Int{-3g,W-}
_@_ PrelBase.Float{-3c,W-}
a{-r1,x-}
ds_d1cw
d{-r7,x-} :: STBase.PrimIO{-3P,W-} PrelBase.Float{-3c,W-}
{-# L #-}
d{-r7,x-} =
d_aZY
d.Fractional_a10l :: {PrelNum.Fractional{-26,p-} PrelBase.Float{-3c,W-}}
{-# L #-}
d.Fractional_a10l =
PrelNum.$d23{-rsg,p-}
fromRational_a10q :: PrelNum.Rational{-3r,p-}
-> PrelBase.Float{-3c,W-}
{-# L #-}
fromRational_a10q =
PrelNum.fromRational{-8T,p-}
_@_ PrelBase.Float{-3c,W-} d.Fractional_a10l
lit_a10r :: PrelBase.Float{-3c,W-}
{-# L #-}
lit_a10r =
fromRational_a10q _rational_ 1 1
d.Fractional_a10p :: {PrelNum.Fractional{-26,p-} PrelBase.Double{-3a,W-}}
{-# L #-}
d.Fractional_a10p =
PrelNum.$d14{-rs6,p-}
fromRational_a10s :: PrelNum.Rational{-3r,p-}
-> PrelBase.Double{-3a,W-}
{-# L #-}
fromRational_a10s =
PrelNum.fromRational{-8T,p-}
_@_ PrelBase.Double{-3a,W-} d.Fractional_a10p
lit_a10t :: PrelBase.Double{-3a,W-}
{-# L #-}
lit_a10t =
fromRational_a10s _rational_ 2 1
end Rec }
================================================================================
Typechecked:
AbsBinds [] [] [([], fubar{-r1,x-}, fubar_aTQ)]
fubar_aTQ
= STBase.seqPrimIO{-r46,p-}
[PrelBase.(){-40,W-}, PrelBase.Int{-3g,W-}]
(STBase.ST{-5G,w-}{i}
[GHC.RealWorld{-3s,W-}, PrelBase.(){-40,W-}] _ccall_ f)
(STBase.ST{-5G,w-}{i}
[GHC.RealWorld{-3s,W-}, PrelBase.Int{-3g,W-}] _ccall_ b)
================================================================================
Desugared:
Rec {
fubar_aTQ :: STBase.PrimIO{-3P,W-} PrelBase.Int{-3g,W-}
{-# L #-}
fubar_aTQ =
let { ds_dVM :: STBase.PrimIO{-3P,W-} PrelBase.(){-40,W-}
{-# L #-}
ds_dVM =
let {
ds_dW2 :: STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
-> (PrelBase.(){-40,W-}, STBase.State{-3M,W-} GHC.RealWorld{-3s,W-})
{-# L #-}
ds_dW2 =
\ ds_dW8 :: STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
{-# L #-}
ds_dW8 ->
case ds_dW8 of { STBase.S#{-5D,w-}{i} ds_dWn ->
case
_ccall_ f [(STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}) (GHC.State#{-3L,W-} GHC.RealWorld{-3s,W-})]!
ds_dWn
of {
STBase.S#{-5D,w-}{i} ds_dWN ->
let {
ds_dWG :: STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
{-# L #-}
ds_dWG =
STBase.S#{-5D,w-}{i} {_@_ GHC.RealWorld{-3s,W-} ds_dWN}
} in
PrelTup.(,){-62,w-}{i}
{_@_ PrelBase.(){-40,W-}
_@_ (STBase.State{-3M,W-} GHC.RealWorld{-3s,W-})
PrelBase.(){-60,w-}{i}
ds_dWG};};}
} in
STBase.ST{-5G,w-}{i}
_@_ GHC.RealWorld{-3s,W-} _@_ PrelBase.(){-40,W-} ds_dW2
} in
let { ds_dVQ :: STBase.PrimIO{-3P,W-} PrelBase.Int{-3g,W-}
{-# L #-}
ds_dVQ =
let {
ds_dX0 :: STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
-> (PrelBase.Int{-3g,W-}, STBase.State{-3M,W-} GHC.RealWorld{-3s,W-})
{-# L #-}
ds_dX0 =
\ ds_dX6 :: STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
{-# L #-}
ds_dX6 ->
case ds_dX6 of { STBase.S#{-5D,w-}{i} ds_dXh ->
case
_ccall_ b [(STBase.StateAndInt#{-3D,W-} GHC.RealWorld{-3s,W-}) (GHC.State#{-3L,W-} GHC.RealWorld{-3s,W-})]!
ds_dXh
of {
STBase.StateAndInt#{-5v,w-}{i} ds_dXK ds_dXI ->
let {
ds_dXz :: PrelBase.Int{-3g,W-}
{-# L #-}
ds_dXz =
PrelBase.I#{-5b,w-}{i} {ds_dXI} } in
let {
ds_dXD :: STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
{-# L #-}
ds_dXD =
STBase.S#{-5D,w-}{i} {_@_ GHC.RealWorld{-3s,W-} ds_dXK}
} in
PrelTup.(,){-62,w-}{i}
{_@_ PrelBase.Int{-3g,W-}
_@_ (STBase.State{-3M,W-} GHC.RealWorld{-3s,W-})
ds_dXz
ds_dXD};};}
} in
STBase.ST{-5G,w-}{i}
_@_ GHC.RealWorld{-3s,W-} _@_ PrelBase.Int{-3g,W-} ds_dX0
} in
STBase.seqPrimIO{-r46,p-}
_@_ PrelBase.(){-40,W-} _@_ PrelBase.Int{-3g,W-} ds_dVM ds_dVQ
fubar{-r1,x-} :: STBase.PrimIO{-3P,W-} PrelBase.Int{-3g,W-}
{-# L #-}
fubar{-r1,x-} =
fubar_aTQ
end Rec }
This diff is collapsed.
================================================================================
STG syntax:
a{-r5u,x-} =
[] \r [$x0_s1iK]
case $x0_s1iK ::STBase.State{-3M,W-} GHC.RealWorld{-3s,W-} of {
-- lvs: [$x0_s1iK]; rhs lvs: []; uniq: c1pz
STBase.S#{-5D,w-}{i} $x1_s1jb ->
case
_ccall_ a [(STBase.StateAndInt#{-3D,W-} GHC.RealWorld{-3s,W-}) (GHC.State#{-3L,W-} GHC.RealWorld{-3s,W-})]# [$x1_s1jb] ::STBase.StateAndInt#{-3D,W-} GHC.RealWorld{-3s,W-}
of {
-- lvs: [$x1_s1jb]; rhs lvs: []; uniq: c1pA
STBase.StateAndInt#{-5v,w-}{i} $x2_s1jl $x3_s1ja ->
let { $x4_s1jL = PrelBase.I#{-5b,w-}{i}! [$x3_s1ja]; } in
let { $x5_s1jK = STBase.S#{-5D,w-}{i}! [$x2_s1jl];
} in PrelTup.(,){-62,w-}{i}! [$x4_s1jL $x5_s1jK];
};
};
b{-r5v,x-} =
[] \r [$x0_s1jJ]
case $x0_s1jJ ::STBase.State{-3M,W-} GHC.RealWorld{-3s,W-} of {
-- lvs: [$x0_s1jJ]; rhs lvs: []; uniq: c1pB
STBase.S#{-5D,w-}{i} $x1_s1kc ->
case
_ccall_ b [(Foreign.StateAndStablePtr#{-3J,W-} GHC.RealWorld{-3s,W-} PrelBase.Int{-3g,W-}) (GHC.State#{-3L,W-} GHC.RealWorld{-3s,W-})]# [$x1_s1kc] ::Foreign.StateAndStablePtr#{-3J,W-} GHC.RealWorld{-3s,W-} PrelBase.Int{-3g,W-}
of {
-- lvs: [$x1_s1kc]; rhs lvs: []; uniq: c1pC
Foreign.StateAndStablePtr#{-5B,w-}{i} $x2_s1km $x3_s1kb ->
let { $x4_s1kO = Foreign.StablePtr{-5o,w-}{i}! [$x3_s1kb]; } in
let { $x5_s1kN = STBase.S#{-5D,w-}{i}! [$x2_s1km];
} in PrelTup.(,){-62,w-}{i}! [$x4_s1kO $x5_s1kN];
};
};
c{-r5w,x-} =
[] \r [$x0_s1kX]
let {
stg_c1oM =
(False, True, False, False, True) [$x0_s1kX] \r [$x1_s1kM]
case
$x1_s1kM{-lvs:$x0_s1kX-} ::STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
of {
-- lvs: [$x1_s1kM $x0_s1kX]; rhs lvs: [$x0_s1kX]; uniq: c1pD
STBase.S#{-5D,w-}{i} $x2_s1kY ->
case $x0_s1kX{-lvs:$x2_s1kY-} ::Foreign.ForeignObj{-3l,W-} of {
-- lvs: [$x0_s1kX $x2_s1kY]; rhs lvs: [$x2_s1kY]; uniq: c1pE
Foreign.ForeignObj{-5f,w-}{i} $x3_s1lo ->
case
_ccall_ c [(STBase.StateAndInt#{-3D,W-} GHC.RealWorld{-3s,W-}) (GHC.State#{-3L,W-} GHC.RealWorld{-3s,W-}) GHC.ForeignObj#{-3k,W-}]# [$x2_s1kY $x3_s1lo] ::STBase.StateAndInt#{-3D,W-} GHC.RealWorld{-3s,W-}
of {
-- lvs: [$x2_s1kY $x3_s1lo]; rhs lvs: []; uniq: c1pF
STBase.StateAndInt#{-5v,w-}{i} $x4_s1lz $x5_s1lp ->
let { $x6_s1m3 = PrelBase.I#{-5b,w-}{i}! [$x5_s1lp]; } in
let { $x7_s1m2 = STBase.S#{-5D,w-}{i}! [$x4_s1lz];
} in PrelTup.(,){-62,w-}{i}! [$x6_s1m3 $x7_s1m2];
};
};
};
} in stg_c1oM;
d{-r5x,x-} =
[] \r [$x0_s1mc]
let {
stg_c1oc =
(False, True, False, False, True) [$x0_s1mc] \r [$x1_s1m1]
case
$x1_s1m1{-lvs:$x0_s1mc-} ::STBase.State{-3M,W-} GHC.RealWorld{-3s,W-}
of {
-- lvs: [$x1_s1m1 $x0_s1mc]; rhs lvs: [$x0_s1mc]; uniq: c1pG
STBase.S#{-5D,w-}{i} $x2_s1md ->
case
$x0_s1mc{-lvs:$x2_s1md-} ::Foreign.StablePtr{-3w,W-} PrelBase.Int{-3g,W-}
of {
-- lvs: [$x0_s1mc $x2_s1md]; rhs lvs: [$x2_s1md]; uniq: c1pH
Foreign.StablePtr{-5o,w-}{i} $x3_s1mD ->
case
_ccall_ d [(STBase.StateAndInt#{-3D,W-} GHC.RealWorld{-3s,W-}) (GHC.State#{-3L,W-} GHC.RealWorld{-3s,W-}) (GHC.StablePtr#{-3v,W-} PrelBase.Int{-3g,W-})]# [$x2_s1md $x3_s1mD] ::STBase.StateAndInt#{-3D,W-} GHC.RealWorld{-3s,W-}
of {
-- lvs: [$x2_s1md $x3_s1mD]; rhs lvs: []; uniq: c1pI
STBase.StateAndInt#{-5v,w-}{i} $x4_s1mO $x5_s1mE ->
let { $x6_s1n5 = PrelBase.I#{-5b,w-}{i}! [$x5_s1mE]; } in
let { $x7_s1n6 = STBase.S#{-5D,w-}{i}! [$x4_s1mO];
} in PrelTup.(,){-62,w-}{i}! [$x6_s1n5 $x7_s1n6];
};
};
};
} in stg_c1oc;
================================================================================
Flat Abstract C:
IFN_(ret_c1pz) {
ED_RO_(PrelBase_IZh_con_info);
ED_(STBase_SZh_static_closure);
ED_RO_(PrelTup_Z40Z44Z41_inregs_info);
I_ s1ja_;
FB_
HEAP_CHK(0,(_FHS+1),0);
{
I_ _ccall_result;
CALLER_SAVE_Base
CALLER_SAVE_SpA
CALLER_SAVE_SuA
CALLER_SAVE_SpB
CALLER_SAVE_SuB
CALLER_SAVE_Ret
CALLER_SAVE_Hp
CALLER_SAVE_HpLim
_ccall_result = (a());
CALLER_RESTORE_Base
CALLER_RESTORE_SpA
CALLER_RESTORE_SuA
CALLER_RESTORE_SpB
CALLER_RESTORE_SuB
CALLER_RESTORE_Ret
CALLER_RESTORE_Hp
CALLER_RESTORE_HpLim
CALLER_RESTORE_StdUpdRetVec
CALLER_RESTORE_StkStub
s1ja_=_ccall_result;
}
SET_SPEC_HDR(Hp-_FHS,PrelBase_IZh_con_info,0,1,0);
*Hp=(W_)(s1ja_);
R4.p=STBase_SZh_static_closure;
R3.p=Hp-_FHS;
SpB=SpB-1;
R2.d=PrelTup_Z40Z44Z41_inregs_info;
GRAN_EXEC(10,2,21,22,0);
JMP_(DIRECT((StgRetAddr)(SpB[1])));
FE_
}
UNVECTBL(static,vtbl_c1pz,ret_c1pz)
STATIC_ITBL(Test_a_info,Test_a_entry,StdErrorCode,1,-1,STATIC_VHS,0,const,EF_,0,0,0);
FN_(Test_a_entry) {
ED_(Test_a_closure);
EF_(Test_a_fast1);
FB_
ARGS_CHK_A_LOAD_NODE(1,Test_a_closure);
R1.p=*SpA;
SpA=SpA+1;
GRAN_EXEC(5,2,1,0,0);
JMP_(Test_a_fast1);
FE_
}
FN_(Test_a_fast1) {
FB_
STK_CHK(1,0,1,0,0,0,0);
SpB[1]=(W_)(RetReg);
RetReg=(StgRetAddr)UNVEC(ret_c1pz,vtbl_c1pz);
SpB=SpB+1;
ENT_VIA_NODE();
GRAN_EXEC(3,1,1,1,0);
JMP_((P_)(ENTRY_CODE((D_)(INFO_PTR(R1.p)))));
FE_
}
SET_STATIC_HDR(Test_a_closure,Test_a_info,0,,ED_RO_)
};
IFN_(ret_c1pB) {
ED_RO_(Foreign_StablePtr_con_info);
ED_(STBase_SZh_static_closure);
ED_RO_(PrelTup_Z40Z44Z41_inregs_info);
StgStablePtr s1kb_;
FB_
HEAP_CHK(0,(_FHS+1),0);
{
StgStablePtr _ccall_result;
CALLER_SAVE_Base
CALLER_SAVE_SpA
CALLER_SAVE_SuA
CALLER_SAVE_SpB
CALLER_SAVE_SuB
CALLER_SAVE_Ret
CALLER_SAVE_Hp
CALLER_SAVE_HpLim
_ccall_result = (b());
CALLER_RESTORE_Base
CALLER_RESTORE_SpA
CALLER_RESTORE_SuA
CALLER_RESTORE_SpB
CALLER_RESTORE_SuB
CALLER_RESTORE_Ret
CALLER_RESTORE_Hp
CALLER_RESTORE_HpLim
CALLER_RESTORE_StdUpdRetVec
CALLER_RESTORE_StkStub
s1kb_=_ccall_result;
}
SET_SPEC_HDR(Hp-_FHS,Foreign_StablePtr_con_info,0,1,0);
*Hp=(W_)(s1kb_);
R4.p=STBase_SZh_static_closure;
R3.p=Hp-_FHS;
SpB=SpB-1;
R2.d=PrelTup_Z40Z44Z41_inregs_info;
GRAN_EXEC(10,2,21,22,0);
JMP_(DIRECT((StgRetAddr)(SpB[1])));
FE_
}
UNVECTBL(static,vtbl_c1pB,ret_c1pB)
STATIC_ITBL(Test_b_info,Test_b_entry,StdErrorCode,1,-1,STATIC_VHS,0,const,EF_,0,0,0);
FN_(Test_b_entry) {
ED_(Test_b_closure);
EF_(Test_b_fast1);
FB_
ARGS_CHK_A_LOAD_NODE(1,Test_b_closure);
R1.p=*SpA;
SpA=SpA+1;
GRAN_EXEC(5,2,1,0,0);
JMP_(Test_b_fast1);
FE_
}
FN_(Test_b_fast1) {
FB_
STK_CHK(1,0,1,0,0,0,0);
SpB[1]=(W_)(RetReg);
RetReg=(StgRetAddr)UNVEC(ret_c1pB,vtbl_c1pB);
SpB=SpB+1;
ENT_VIA_NODE();
GRAN_EXEC(3,1,1,1,0);
JMP_((P_)(ENTRY_CODE((D_)(INFO_PTR(R1.p)))));
FE_
}
SET_STATIC_HDR(Test_b_closure,Test_b_info,0,,ED_RO_)
};
IFN_(ret_c1pE) {
ED_RO_(PrelBase_IZh_con_info);
ED_(STBase_SZh_static_closure);
ED_RO_(PrelTup_Z40Z44Z41_inregs_info);
I_ s1lp_;
FB_
HEAP_CHK(4,(_FHS+1),0);
{
I_ _ccall_result;
StgForeignObj _ccall_arg1=ForeignObj_CLOSURE_DATA(R3.p);