--- gcc/match.pd.jj	2023-09-04 09:45:33.553058301 +0200
+++ gcc/match.pd	2023-09-05 08:45:53.258078971 +0200
@@ -6631,7 +6631,9 @@ (define_operator_list SYNC_FETCH_AND_AND
    (with {
      auto prec = TYPE_PRECISION (type);
      auto unsign = TYPE_UNSIGNED (type);
-     tree inttype = build_nonstandard_integer_type (prec, unsign);
+     tree inttype = type;
+     if (TREE_CODE (type) != INTEGER_TYPE && TREE_CODE (type) != BITINT_TYPE)
+       inttype = build_nonstandard_integer_type (prec, unsign);
     }
     (convert (bit_xor (negate (convert:inttype @0)) (convert:inttype @2)))))))
 #endif
