aboutsummaryrefslogtreecommitdiff
path: root/gcc/varasm.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/varasm.c')
-rw-r--r--gcc/varasm.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gcc/varasm.c b/gcc/varasm.c
index 6019b5a..aaf9e53 100644
--- a/gcc/varasm.c
+++ b/gcc/varasm.c
@@ -2026,8 +2026,9 @@ default_assemble_integer (rtx x ATTRIBUTE_UNUSED,
int aligned_p ATTRIBUTE_UNUSED)
{
const char *op = integer_asm_op (size, aligned_p);
- /* Avoid GAS bugs for values > word size. */
- if (size > UNITS_PER_WORD)
+ /* Avoid GAS bugs for large values. Specifically negative values whose
+ absolute value fits in a bfd_vma, but not in a bfd_signed_vma. */
+ if (size > UNITS_PER_WORD && size > POINTER_SIZE / BITS_PER_UNIT)
return false;
return op && (assemble_integer_with_op (op, x), true);
}