forked from OSchip/llvm-project
Fix r232466 by adding 'i' to the mappings for inline assembly memory constraints.
It's not completely clear why 'i' has historically been treated as a memory constraint. According to the documentation, it represents a constant immediate. llvm-svn: 232470
This commit is contained in:
parent
e11531f7ea
commit
914b947e9b
|
@ -240,6 +240,7 @@ public:
|
|||
// constraint codes for all targets.
|
||||
Constraint_Unknown = 0,
|
||||
Constraint_es,
|
||||
Constraint_i,
|
||||
Constraint_m,
|
||||
Constraint_o,
|
||||
Constraint_v, // Unused at the moment since Constraint_m is always used.
|
||||
|
|
|
@ -2627,7 +2627,9 @@ public:
|
|||
|
||||
virtual unsigned
|
||||
getInlineAsmMemConstraint(const std::string &ConstraintCode) const {
|
||||
if (ConstraintCode == "m")
|
||||
if (ConstraintCode == "i")
|
||||
return InlineAsm::Constraint_i;
|
||||
else if (ConstraintCode == "m")
|
||||
return InlineAsm::Constraint_m;
|
||||
return InlineAsm::Constraint_Unknown;
|
||||
}
|
||||
|
|
|
@ -194,6 +194,7 @@ namespace {
|
|||
errs() << "ConstraintID: " << ConstraintID << "\n";
|
||||
llvm_unreachable("Unexpected asm memory constraint");
|
||||
case InlineAsm::Constraint_es:
|
||||
case InlineAsm::Constraint_i:
|
||||
case InlineAsm::Constraint_m:
|
||||
case InlineAsm::Constraint_o:
|
||||
case InlineAsm::Constraint_Q:
|
||||
|
|
Loading…
Reference in New Issue