Hu Jiangping <hujiangp...@cn.fujitsu.com> writes:
> Thanks, Richard!
>
> I think your suggestion is very good, so I made a new patch.
>
> v2: at a high level handles -falign-foo=0 like -falign-foo
> v1: at the target level overides the -falign-foo=0 option values
>
> Obviously, v2 is better than v1. In addition, anthor option
> to reject 0 that discussed in the email and PR96247
> is not as good as the current patch either, I think.
>
> I tested this patch on x86_64, it works well. OK for trunk?

In addition to Segher's comments, I wonder if it would be better
to pass &opts->x_flag_align_foo and &opts->x_str_align_jumps to
check_alignment_argument and do the check there instead.
The condition for whether to do this would then be:

  align_result.length () == 1 && align_result[0] == 0

The reason for suggesting that is that it makes the parsing code
more self-consistent, rather than using atoi for this case only.

Looks good otherwise, thanks.

Richard

Reply via email to