mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-05-04 09:00:33 +03:00
Fix typo
This commit is contained in:
parent
82c841534c
commit
044dd7bc9d
5 changed files with 11 additions and 11 deletions
|
@ -571,9 +571,9 @@ void DtoDeclareFunction(FuncDeclaration *fdecl) {
|
|||
declareRuntimeCompiledFunction(gIR, irFunc);
|
||||
}
|
||||
|
||||
if (irFunc->targetCpuOverriden ||
|
||||
irFunc->targetFeaturesOverriden) {
|
||||
gIR->targetCpuOrFeaturesOverriden.push_back(irFunc);
|
||||
if (irFunc->targetCpuOverridden ||
|
||||
irFunc->targetFeaturesOverridden) {
|
||||
gIR->targetCpuOrFeaturesOverridden.push_back(irFunc);
|
||||
}
|
||||
|
||||
// main
|
||||
|
|
|
@ -223,7 +223,7 @@ public:
|
|||
void replaceGlobals();
|
||||
|
||||
// List of functions with cpu or features attributes overriden by user
|
||||
std::vector<IrFunction *> targetCpuOrFeaturesOverriden;
|
||||
std::vector<IrFunction *> targetCpuOrFeaturesOverridden;
|
||||
|
||||
struct RtCompiledFuncDesc {
|
||||
llvm::GlobalVariable *thunkVar;
|
||||
|
|
|
@ -227,7 +227,7 @@ void removeFunctionsTargets(IRState *irs, llvm::Module &module) {
|
|||
assert(nullptr != irs);
|
||||
|
||||
std::unordered_map<std::string, IrFunction *> funcMap;
|
||||
for (auto &&fun : irs->targetCpuOrFeaturesOverriden) {
|
||||
for (auto &&fun : irs->targetCpuOrFeaturesOverridden) {
|
||||
assert(nullptr != fun);
|
||||
funcMap.insert({fun->getLLVMFunc()->getName(), fun});
|
||||
}
|
||||
|
@ -239,11 +239,11 @@ void removeFunctionsTargets(IRState *irs, llvm::Module &module) {
|
|||
auto it = funcMap.find(fun.getName());
|
||||
if (funcMap.end() != it) {
|
||||
auto irFunc = it->second;
|
||||
if (!irFunc->targetCpuOverriden) {
|
||||
if (!irFunc->targetCpuOverridden) {
|
||||
fun.removeFnAttr("target-cpu");
|
||||
}
|
||||
|
||||
if (!irFunc->targetFeaturesOverriden) {
|
||||
if (!irFunc->targetFeaturesOverridden) {
|
||||
fun.removeFnAttr("target-features");
|
||||
}
|
||||
} else {
|
||||
|
|
|
@ -328,7 +328,7 @@ void applyAttrTarget(StructLiteralExp *sle, llvm::Function *func, IrFunction *ir
|
|||
|
||||
if (!CPU.empty()) {
|
||||
func->addFnAttr("target-cpu", CPU);
|
||||
irFunc->targetCpuOverriden = true;
|
||||
irFunc->targetCpuOverridden = true;
|
||||
}
|
||||
|
||||
if (!features.empty()) {
|
||||
|
@ -338,7 +338,7 @@ void applyAttrTarget(StructLiteralExp *sle, llvm::Function *func, IrFunction *ir
|
|||
sort(features.begin(), features.end());
|
||||
func->addFnAttr("target-features",
|
||||
llvm::join(features.begin(), features.end(), ","));
|
||||
irFunc->targetFeaturesOverriden = true;
|
||||
irFunc->targetFeaturesOverridden = true;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -82,10 +82,10 @@ struct IrFunction {
|
|||
llvm::FastMathFlags FMF;
|
||||
|
||||
/// target CPU was overriden by attribute
|
||||
bool targetCpuOverriden = false;
|
||||
bool targetCpuOverridden = false;
|
||||
|
||||
/// target features was overriden by attributes
|
||||
bool targetFeaturesOverriden = false;
|
||||
bool targetFeaturesOverridden = false;
|
||||
|
||||
/// This functions was marked for dynamic compilation
|
||||
bool runtimeCompile = false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue