diff options
author | Walter Lee <walt@tilera.com> | 2012-02-25 22:40:48 +0000 |
---|---|---|
committer | Walter Lee <walt@tilera.com> | 2012-02-25 22:40:48 +0000 |
commit | 481fe810e480dc19f9950511a1aebb37d39aa051 (patch) | |
tree | 68ec595923e458e6605c1703fa8451734db795c9 /gas/config/tc-tilepro.c | |
parent | 6f7be9592d58646e9ff66e125068691f1e830cc0 (diff) | |
download | gdb-481fe810e480dc19f9950511a1aebb37d39aa051.zip gdb-481fe810e480dc19f9950511a1aebb37d39aa051.tar.gz gdb-481fe810e480dc19f9950511a1aebb37d39aa051.tar.bz2 |
Fix regression from change
http://sourceware.org/ml/binutils-cvs/2012-01/msg00049.html . The
code needs to check that the symbol is not a local symbol before
accessing a non-local-symbol field.
* tc-tilepro.c (emit_tilepro_instruction): Check if symbol is
non-local before checking sy_value.
* tc-tilegx.c (emit_tilegx_instruction): Ditto.
Diffstat (limited to 'gas/config/tc-tilepro.c')
-rw-r--r-- | gas/config/tc-tilepro.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gas/config/tc-tilepro.c b/gas/config/tc-tilepro.c index 0b378c2..733a628 100644 --- a/gas/config/tc-tilepro.c +++ b/gas/config/tc-tilepro.c @@ -631,7 +631,8 @@ emit_tilepro_instruction (tilepro_bundle_bits bits, /* Now that we've changed the reloc, change ha16(x) into x, etc. */ - if (operand_exp->X_add_symbol->sy_value.X_md) + if (!operand_exp->X_add_symbol->sy_flags.sy_local_symbol + && operand_exp->X_add_symbol->sy_value.X_md) { /* HACK: We used X_md to mark this symbol as a fake wrapper around a real expression. To unwrap it, we just grab its |