"TARGET_APX_EGPR && !TARGET_AVX ? GENERAL_GPR16 : GENERAL_REGS")
(define_memory_constraint "je"
- "@internal Memory operand for APX NDD ADD."
- (match_operand 0 "apx_ndd_add_memory_operand"))
+ "@internal Memory operand for APX EVEX-encoded ADD (i.e. APX NDD/NF)."
+ (match_operand 0 "apx_evex_add_memory_operand"))
(define_memory_constraint "jM"
- "@internal Memory operand, with APX NDD check."
- (match_operand 0 "apx_ndd_memory_operand"))
+ "@internal Memory operand, with APX EVEX-encoded (i.e. APX NDD/NF) check."
+ (match_operand 0 "apx_evex_memory_operand"))
(define_memory_constraint "jO"
- "@internal Offsettable memory operand, with APX NDD check."
- (and (match_operand 0 "apx_ndd_memory_operand")
+ "@internal Offsettable memory operand, with APX EVEX-encoded
+ (i.e. APX NDD/NF) check."
+ (and (match_operand 0 "apx_evex_memory_operand")
(match_test "offsettable_nonstrict_memref_p (op)")))
})
;; Return true if OP is a memory operand that can be also used in APX
-;; NDD patterns with immediate operand. With non-default address space,
-;; segment register or address size prefix, APX NDD instruction length
-;; can exceed the 15 byte size limit.
-(define_predicate "apx_ndd_memory_operand"
+;; EVEX-encoded patterns (i.e. APX NDD/NF) with immediate operand. With
+;; non-default address space, segment register or address size prefix,
+;; APX EVEX-encoded instruction length can exceed the 15 byte size limit.
+(define_predicate "apx_evex_memory_operand"
(match_operand 0 "memory_operand")
{
/* OK if immediate operand size < 4 bytes. */
return true;
})
-;; Return true if OP is a memory operand which can be used in APX NDD
-;; ADD with register source operand. UNSPEC_GOTNTPOFF memory operand
-;; is allowed with APX NDD ADD only if R_X86_64_CODE_6_GOTTPOFF works.
-(define_predicate "apx_ndd_add_memory_operand"
+;; Return true if OP is a memory operand which can be used in APX EVEX-encoded
+;; ADD patterns (i.e. APX NDD/NF) for with register source operand.
+;; UNSPEC_GOTNTPOFF memory operand is allowed with APX EVEX-encoded ADD only if
+;; R_X86_64_CODE_6_GOTTPOFF works.
+(define_predicate "apx_evex_add_memory_operand"
(match_operand 0 "memory_operand")
{
- /* OK if "add %reg1, name@gottpoff(%rip), %reg2" is supported. */
+ /* OK if "add %reg1, name@gottpoff(%rip), %reg2" or
+ "{nf} add name@gottpoff(%rip), %reg1" are supported. */
if (HAVE_AS_R_X86_64_CODE_6_GOTTPOFF)
return true;
op = XEXP (op, 0);
- /* Disallow APX NDD ADD with UNSPEC_GOTNTPOFF. */
+ /* Disallow APX EVEX-encoded ADD with UNSPEC_GOTNTPOFF. */
if (GET_CODE (op) == CONST
&& GET_CODE (XEXP (op, 0)) == UNSPEC
&& XINT (XEXP (op, 0), 1) == UNSPEC_GOTNTPOFF)