}
/* Helper for md_assemble() to decide whether to prepare for a possible 2nd
- parsing pass. Instead of introducing a rarely use new insn attribute this
+ parsing pass. Instead of introducing a rarely used new insn attribute this
utilizes a common pattern between affected templates. It is deemed
acceptable that this will lead to unnecessary pass 2 preparations in a
limited set of cases. */
: (t->opcode_space == SPACE_0F
&& (t->base_opcode | 1) == 0xbf)
|| (t->opcode_space == SPACE_BASE
- && t->base_opcode == 0x63);
+ && t->base_opcode == 0x63)
+ || (intel_syntax /* shld / shrd may mean suffixed shl / shr. */
+ && t->opcode_space == SPACE_EVEXMAP4
+ && (t->base_opcode | 8) == 0x2c);
}
#if defined (OBJ_MAYBE_ELF) || defined (OBJ_ELF)
--- /dev/null
+#objdump: -dw
+#name: Intel syntax w/ suffixes
+
+.*: +file format .*
+
+Disassembly of section \.text:
+0+0 <.*>:
+[ ]*[a-f0-9]+: 0f a4 c8 01[ ]+shld \$0x1,%ecx,%eax
+[ ]*[a-f0-9]+: 0f a5 c8[ ]+shld %cl,%ecx,%eax
+[ ]*[a-f0-9]+: d1 e1[ ]+shl \$1,%ecx
+[ ]*[a-f0-9]+: d3 e1[ ]+shl %cl,%ecx
+[ ]*[a-f0-9]+: 62 f4 7c 18 d1 e1[ ]+shl \$1,%ecx,%eax
+[ ]*[a-f0-9]+: 62 f4 7c 18 d3 e1[ ]+shl %cl,%ecx,%eax
+[ ]*[a-f0-9]+: d1 e1[ ]+shl \$1,%ecx
+[ ]*[a-f0-9]+: d3 e1[ ]+shl %cl,%ecx
+[ ]*[a-f0-9]+: 62 f4 7c 18 d1 c1[ ]+rol \$1,%ecx,%eax
+[ ]*[a-f0-9]+: 62 f4 7c 18 d3 c1[ ]+rol %cl,%ecx,%eax
+[ ]*[a-f0-9]+: d1 c1[ ]+rol \$1,%ecx
+[ ]*[a-f0-9]+: d3 c1[ ]+rol %cl,%ecx
+
+0+[0-9a-f]+ <.*>:
+[ ]*[a-f0-9]+: 0f ac c8 01[ ]+shrd \$0x1,%ecx,%eax
+[ ]*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