projects
/
mate.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
codegen: approx. initial codebuffer size according to codesize @ bytecode
[mate.git]
/
Mate
/
MethodPool.hs
diff --git
a/Mate/MethodPool.hs
b/Mate/MethodPool.hs
index c8cb0848499f9ab74c4b1b828397c218b7037107..5a0f70e73605fa0e256cfcea9b925cbddd2d1520 100644
(file)
--- a/
Mate/MethodPool.hs
+++ b/
Mate/MethodPool.hs
@@
-136,7
+136,8
@@
compileBB rawmethod methodinfo = do
cls <- getClassFile (methClassName methodinfo)
let ebb = emitFromBB cls rawmethod
cls <- getClassFile (methClassName methodinfo)
let ebb = emitFromBB cls rawmethod
- (_, Right right) <- runCodeGen ebb () ()
+ let cgconfig = defaultCodeGenConfig { codeBufferSize = fromIntegral $ (rawCodeLength rawmethod) * 32 }
+ (_, Right right) <- runCodeGenWithConfig ebb () () cgconfig
let ((entry, _, _, new_tmap), _) = right
setTrapMap $ tmap `M.union` new_tmap -- prefers elements in tmap
let ((entry, _, _, new_tmap), _) = right
setTrapMap $ tmap `M.union` new_tmap -- prefers elements in tmap