-#if defined (__hppa) && W_TYPE_SIZE == 64 && ! defined (_LONG_LONG_LIMB)
+#if defined (__hppa) && W_TYPE_SIZE == 64 && ! defined
(_LONG_LONG_LIMB) \
+ && defined (_PA_RISC2_0) && (ULONGMAX_MAX == UINT64_MAX)
+/* Note the _PA_RISC2_0 above is to exclude this code from GCC with
+ default -march options which doesn't support these instructions.
+ Also the width check for 'long' is to avoid ilp32 runtimes where
+ GNU/Linux and narrow HP-UX kernels are known to have issues with
+ clobbering of context between the add and add,dc instructions. */