This is the mail archive of the mailing list for the binutils project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] gas: xtensa: limit size of auto litpools

On Tue, Feb 20, 2018 at 11:19 AM,
<> wrote:
> On Sun, Feb 11, 2018 at 4:18 PM, Max Filippov <> wrote:
>> Literal movement code may grow auto litpool so big that it won't be
>> possible to jump around it. Limit the size of auto litpools by 1/2 of
>> the jump range.
>> gas/
>> 2018-02-08  Max Filippov  <>
>>         * config/tc-xtensa.c (struct litpool_frag): Add new field
>>         literal_count.
>>         (MAX_POOL_LITERALS): New macro definitions.
>>         (auto_litpool_limit): Initialize to 0.
>>         (md_parse_option): Set auto_litpool_limit in the presence of
>>         --auto-litpools option.
>>         (xtensa_maybe_create_literal_pool_frag): Zero-initialize
>>         literal_count field.
>>         (xg_find_litpool): New function. Make sure that found literal
>>         pool size is within the limit.
>>         (xtensa_move_literals): Extract literal pool search code into
>>         the new function.
>>         * testsuite/gas/xtensa/all.exp: Add auto-litpools-2 test.
>>         * testsuite/gas/xtensa/auto-litpools-2.d: New file.
>>         * testsuite/gas/xtensa/auto-litpools-2.s: New file.
>>         * testsuite/gas/xtensa/auto-litpools.d: Fix up changed
>>         addresses.
>>         * testsuite/gas/xtensa/auto-litpools.s: Change literal value so
>>         that objdump doesn't get out of sync.
> This is OK for binutils.

Thanks, applied to master.

-- Max

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]