ldc/gen/modules.h
David Nadlinger d47bdb234a gen: Use single ldc.register_dso function for both module ctor/dtor
This reduces the size of a statically linked Phobos-based
Hello World by 11 kB on Linux x86_64.

Also creates a header file for gen/module.cpp, which has been
renamed to "modules" such as not to conflict with the frontend
header file.
2016-08-18 16:28:41 +02:00

20 lines
755 B
C++
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

//===-- gen/modules.h - Entry points for D module codegen -------*- C++ -*-===//
//
// LDC the LLVM D compiler
//
// This file is distributed under the BSD-style LDC license. See the LICENSE
// file for details.
//
//===----------------------------------------------------------------------===//
struct IRState;
class Module;
/// Sets the m->*file members to the output file names, as derived from platform
/// and command line switches, making sure that they are valid paths and don't
/// conflict with the source file.
void buildTargetFiles(Module *m, bool singleObj, bool library);
/// Generates code for the contents of module m into the LLVM module associated
/// with irs.
void codegenModule(IRState *irs, Module *m);