- /* This is a case we can optimize as well. The expression was
- not reduced, so we can not finish the optimization until the
- end of the assembly. We set up a variant frag which we
- handle later. */
- frag_var (rs_cfa, 4, 0, d->cie_info.code_alignment << 3,
- make_expr_symbol (&exp->X_add_symbol->sy_value),
- d->loc4_fix, (char *) d->loc4_frag);
- return 1;
+ expressionS *symval;
+
+ symval = symbol_get_value_expression (exp->X_add_symbol);
+ if (symval->X_op == O_subtract)
+ {
+ /* This is a case we can optimize as well. The
+ expression was not reduced, so we can not finish
+ the optimization until the end of the assembly.
+ We set up a variant frag which we handle later. */
+ frag_var (rs_cfa, 4, 0, d->cie_info.code_alignment << 3,
+ make_expr_symbol (symval),
+ d->loc4_fix, (char *) d->loc4_frag);
+ return 1;
+ }