rje 2003/03/18 15:24:20 PST
Modified files: (Branch: speceval_2)
ghc/compiler/absCSyn AbsCSyn.lhs AbsCUtils.lhs PprAbsC.lhs
ghc/compiler/codeGen CgBindery.lhs CgCase.lhs CgClosure.lhs
CgCon.lhs CgExpr.lhs CgMonad.lhs
CgRetConv.lhs CgTailCall.lhs
ghc/compiler/main Constants.lhs
ghc/compiler/nativeGen AbsCStixGen.lhs StixPrim.lhs
Log:
This commit adds bitwise semitagging to the speculative branch.
The low order bits of a closure address are used as follows:
00 - Unknown. May be unevaluated.
01 - Evaluated, and is of constructor 1
02 - Evaluated, and is of constructor 2
03 - Evaluated, and is of constructor 3
If we have more than 3 constructors, then bitwise semitagging is not
currently used.
When we scrutinise a bitwise semitagged value, we look at the address
to see if the value needs to be entered, and to see what constructor it is.
This allows us to avoid thunk entries in some cases.
Semitagging doesn't buy much with normal lazy evaluation, as much
closures are either thunks or indirections. However, experience with
my previous implementation suggests that it buys quite a lot when one
is using speculative evaluation.
This hasn't been tested yet (still waiting for the libs to build), so it is
probably broken in many ways.
Revision Changes Path
1.51.2.4 +10 -2 fptools/ghc/compiler/absCSyn/AbsCSyn.lhs
1.54.2.3 +3 -3 fptools/ghc/compiler/absCSyn/AbsCUtils.lhs
1.95.2.6 +14 -7 fptools/ghc/compiler/absCSyn/PprAbsC.lhs
1.48.2.5 +11 -8 fptools/ghc/compiler/codeGen/CgBindery.lhs
1.61.2.6 +53 -9 fptools/ghc/compiler/codeGen/CgCase.lhs
1.59.2.1 +3 -2 fptools/ghc/compiler/codeGen/CgClosure.lhs
1.38.2.1 +13 -5 fptools/ghc/compiler/codeGen/CgCon.lhs
1.52.2.11 +2 -2 fptools/ghc/compiler/codeGen/CgExpr.lhs
1.37.2.6 +2 -3 fptools/ghc/compiler/codeGen/CgMonad.lhs
1.33.6.1 +20 -3 fptools/ghc/compiler/codeGen/CgRetConv.lhs
1.36.2.6 +107 -5 fptools/ghc/compiler/codeGen/CgTailCall.lhs
1.32.2.1 +5 -0 fptools/ghc/compiler/main/Constants.lhs
1.54.2.3 +3 -0 fptools/ghc/compiler/nativeGen/AbsCStixGen.lhs
1.85.2.1 +5 -2 fptools/ghc/compiler/nativeGen/StixPrim.lhs
_______________________________________________
Cvs-ghc mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/cvs-ghc