mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-05-02 16:11:08 +03:00
Fixed choosing default target machine without needing to link in targets.
This commit is contained in:
parent
88f9ca75ad
commit
f411df11e3
3 changed files with 13 additions and 30 deletions
|
@ -1483,23 +1483,6 @@ LLConstant* DtoTypeInfoOf(Type* type, bool base)
|
|||
|
||||
//////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
void findDefaultTarget()
|
||||
{
|
||||
std::string err_str;
|
||||
const llvm::TargetMachineRegistry::entry* e = llvm::TargetMachineRegistry::getClosestTargetForJIT(err_str);
|
||||
if (e == 0)
|
||||
{
|
||||
error("Failed to find a default target machine: %s", err_str.c_str());
|
||||
fatal();
|
||||
}
|
||||
else
|
||||
{
|
||||
global.params.llvmArch = const_cast<char*>(e->Name);
|
||||
}
|
||||
}
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
LLValue* DtoBoolean(Loc& loc, DValue* dval)
|
||||
{
|
||||
Type* dtype = dval->getType()->toBasetype();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue