History

inline asm: Accept 'R' constraint

This is like 'r' but only accepts the eight legacy regs. Currently that's the same as 'r' because we don't support the high ones.

Michael Matz committed 10 years ago

Commit 75e8df11 parent f6c1eb11 file · +2 −0Browse files

Unified · Split

i386-asm.c+2−0
@@ -1011,6 +1011,7 @@ static inline int constraint_priority(const char *str) · 1010 unmodified lines
1011 pr = 2;1011 pr = 2;
1012 break;1012 break;
1013 case 'r':1013 case 'r':
1014 case 'R':
1014 case 'p':1015 case 'p':
1015 pr = 3;1016 pr = 3;
1016 break;1017 break;
@@ -1181,6 +1182,7 @@ ST_FUNC void asm_compute_constraints(ASMOperand *operands, · 164 unmodified lines
1181 }1182 }
1182 goto try_next;1183 goto try_next;
1183 case 'r':1184 case 'r':
1185 case 'R':
1184 case 'p': /* A general address, for x86(64) any register is acceptable*/1186 case 'p': /* A general address, for x86(64) any register is acceptable*/
1185 /* any general register */1187 /* any general register */
1186 for(reg = 0; reg < 8; reg++) {1188 for(reg = 0; reg < 8; reg++) {

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t