Mercurial > projects > ldc
comparison gen/asmstmt.cpp @ 622:26fce59fe80a
Wrapped all the most potentially expensive logging calls in a conditional to only do work when actually requested.
Commented some logging calls that could potentially write out many megabytes of type dumps.
author | Tomas Lindquist Olsen <tomas.l.olsen@gmail.com> |
---|---|
date | Wed, 01 Oct 2008 18:32:31 +0200 |
parents | c7d7e2282ba3 |
children | a58784e0f035 |
comparison
equal
deleted
inserted
replaced
619:722630261d62 | 622:26fce59fe80a |
---|---|
622 | 622 |
623 std::vector<const LLType*> types; | 623 std::vector<const LLType*> types; |
624 types.insert(types.end(), outtypes.begin(), outtypes.end()); | 624 types.insert(types.end(), outtypes.begin(), outtypes.end()); |
625 types.insert(types.end(), intypes.begin(), intypes.end()); | 625 types.insert(types.end(), intypes.begin(), intypes.end()); |
626 llvm::FunctionType* fty = llvm::FunctionType::get(llvm::Type::VoidTy, types, false); | 626 llvm::FunctionType* fty = llvm::FunctionType::get(llvm::Type::VoidTy, types, false); |
627 Logger::cout() << "function type = " << *fty << '\n'; | 627 if (Logger::enabled()) |
628 Logger::cout() << "function type = " << *fty << '\n'; | |
628 llvm::InlineAsm* ia = llvm::InlineAsm::get(fty, code, out_c, true); | 629 llvm::InlineAsm* ia = llvm::InlineAsm::get(fty, code, out_c, true); |
629 | 630 |
630 std::vector<LLValue*> args; | 631 std::vector<LLValue*> args; |
631 args.insert(args.end(), outargs.begin(), outargs.end()); | 632 args.insert(args.end(), outargs.begin(), outargs.end()); |
632 args.insert(args.end(), inargs.begin(), inargs.end()); | 633 args.insert(args.end(), inargs.begin(), inargs.end()); |