diff options
author | Matthias Benkard <mulk@minimulk.mst-plus> | 2008-09-28 17:26:35 +0200 |
---|---|---|
committer | Matthias Benkard <mulk@minimulk.mst-plus> | 2008-09-28 17:26:35 +0200 |
commit | ef2536760d6e144f7d903f9f488d3350c2bd2221 (patch) | |
tree | a5413ed01d984573992c8793cd76928eb934a805 /MLKLLVMCompiler.mm | |
parent | 095213f5a96bdb8b1c5a3233f62bb4a6674d4257 (diff) |
LLVM compiler: Add various disabled debugging statements.
Diffstat (limited to 'MLKLLVMCompiler.mm')
-rw-r--r-- | MLKLLVMCompiler.mm | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/MLKLLVMCompiler.mm b/MLKLLVMCompiler.mm index b3a47d3..39741ff 100644 --- a/MLKLLVMCompiler.mm +++ b/MLKLLVMCompiler.mm @@ -164,7 +164,7 @@ static Constant //module->dump(); //NSLog (@"%p", fn); - [pool release]; + LRELEASE (pool); //NSLog (@"Code compiled."); #if 1 @@ -537,6 +537,9 @@ static Constant closureDataCell = builder.Insert ([_context closureDataPointerValueForSymbol:_head]); closureDataPtr = builder.CreateLoad (closureDataCell); + //[_compiler insertTrace:[NSString stringWithFormat:@"Call: %@", MLKPrintToString(_head)]]; + //[_compiler insertPointerTrace:functionPtr]; + args.push_back (closureDataPtr); NSEnumerator *e = [_argumentForms objectEnumerator]; @@ -556,7 +559,11 @@ static Constant PointerTy); args.push_back (endmarker); - //[_compiler insertTrace:[NSString stringWithFormat:@"Function call: %@.", MLKPrintToString(_head)]]; + // If the pointer output here is different from the one above, + // there's some stack smashing going on. + //[_compiler insertTrace:[NSString stringWithFormat:@"Now calling: %@.", MLKPrintToString(_head)]]; + //[_compiler insertPointerTrace:functionPtr]; + CallInst *call = builder.CreateCall (functionPtr, args.begin(), args.end(), |