diff options
author | Jim Wilson <wilson@tuliptree.org> | 1991-07-10 13:18:07 +0000 |
---|---|---|
committer | Jim Wilson <wilson@tuliptree.org> | 1991-07-10 13:18:07 +0000 |
commit | 116a34785af00cec25f3db9427b5abb84e8e408e (patch) | |
tree | 6279aabc38fc8f3c1620e0e07c5e66ccc195f151 /gas | |
parent | ea361b4ab5929e901a6ba87d5800907f6bfbc595 (diff) | |
download | gdb-116a34785af00cec25f3db9427b5abb84e8e408e.zip gdb-116a34785af00cec25f3db9427b5abb84e8e408e.tar.gz gdb-116a34785af00cec25f3db9427b5abb84e8e408e.tar.bz2 |
Ifdef out bogus `relocation overflow' tests.
Diffstat (limited to 'gas')
-rw-r--r-- | gas/config/tc-sparc.c | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/gas/config/tc-sparc.c b/gas/config/tc-sparc.c index 88165e2..47fdbd2 100644 --- a/gas/config/tc-sparc.c +++ b/gas/config/tc-sparc.c @@ -1208,18 +1208,28 @@ long val; /* start-sanitize-v9 */ #ifndef NO_V9 case RELOC_11: - if (val & 0x7ff) { - as_bad("relocation overflow"); +#if 0 + /* ??? Bogus overflow test. This is a signed value, so + the upper bits can be set if the sign bit is set. */ + if (val & ~0x7ff) { + as_bad("relocation overflow."); } /* on overflow */ +#endif buf[2] = (val >> 8) & 0x7; buf[3] = val & 0xff; break; case RELOC_WDISP2_14: +#if 0 + /* ??? Bogus overflow test. This is a signed value, so + the upper bits can be set if the sign bit is set. */ + /* ??? This tests the wrong 16 bits also, should test + ~0x3fffc0. */ if (val & ~0xffff) { as_bad("relocation overflow."); } /* on overflow */ +#endif val = (val >>= 2) + 1; buf[1] |= ((val >> 14) & 0x3) << 3; @@ -1228,9 +1238,15 @@ long val; break; case RELOC_WDISP19: +#if 0 + /* ??? Bogus overflow test. This is a signed value, so + the upper bits can be set if the sign bit is set. */ + /* ??? This tests the wrong 19 bits also, should test + ~0x1ffffc0. */ if (val & ~0x7ffff) { as_bad("relocation overflow."); } /* on overflow */ +#endif val = (val >>= 2) + 1; buf[1] |= (val >> 16) & 0x7; |