diff options
Diffstat (limited to 'gas')
-rw-r--r-- | gas/config/tc-i386.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/gas/config/tc-i386.c b/gas/config/tc-i386.c index 10eb0a3..83975c3 100644 --- a/gas/config/tc-i386.c +++ b/gas/config/tc-i386.c @@ -2375,13 +2375,15 @@ operand_type_register_match (i386_operand_type g0, && g0.bitfield.zmmword == g1.bitfield.zmmword) return 1; - if (!(t0.bitfield.byte & t1.bitfield.byte) - && !(t0.bitfield.word & t1.bitfield.word) - && !(t0.bitfield.dword & t1.bitfield.dword) - && !(t0.bitfield.qword & t1.bitfield.qword) - && !(t0.bitfield.xmmword & t1.bitfield.xmmword) - && !(t0.bitfield.ymmword & t1.bitfield.ymmword) - && !(t0.bitfield.zmmword & t1.bitfield.zmmword)) + /* If expectations overlap in no more than a single size, all is fine. */ + g0 = operand_type_and (t0, t1); + if (g0.bitfield.byte + + g0.bitfield.word + + g0.bitfield.dword + + g0.bitfield.qword + + g0.bitfield.xmmword + + g0.bitfield.ymmword + + g0.bitfield.zmmword <= 1) return 1; i.error = register_type_mismatch; |