This is the mail archive of the binutils@sourceware.org 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 to put i386_insn into header file.


On Mon, Sep 28, 2009 at 4:01 PM, Martin Thuresson <martint@google.com> wrote:
> On Mon, Sep 28, 2009 at 3:40 PM, H.J. Lu <hjl.tools@gmail.com> wrote:
>> On Mon, Sep 28, 2009 at 3:13 PM, Martin Thuresson <martint@google.com> wrote:
>>> On Sat, Sep 26, 2009 at 6:56 AM, H.J. Lu <hjl.tools@gmail.com> wrote:
>>>> On Fri, Sep 25, 2009 at 10:13 PM, Martin Thuresson <martint@google.com> wrote:
>>>>> This patch moves the definition of i386_insn (and other related
>>>>> types) to tc-i386.h in order to make it possible to reuse in
>>>>> other files.
>>>>>
>>>>
>>>> Please tell us how you plan to use them in other files.
>>>
>>> Sorry for not describing why.
>>>
>>> I am using the instruction parsing from binutils for a project, and want
>>> to use reuse the type i386_insn in my sources for local variables. This
>>> changes puts the relevant types in the header file, so I can include it.
>>>
>>> Hopefully other people can benefit from this as well, and feed back
>>> any improvements into the binutils code.
>>>
>>
>> Which parts of tc-i386.c do you use?
>
> For now, ?tc-i386.c is locally modified and callbacks are inserted
> to pass parsed instructions to the main code. If things work out
> well I hope to be able to add a clean interface instead of this
> using this hack.

The part of tc-i386.c your patch changes is very dynamic for
future new instruction support. Since you still need a locally
modified tc-i386.c with your proposed change, you should
keep all of your changes locally until you are ready to propose
a reasonable interface instead of checking in a "hack" now.

Thanks.


-- 
H.J.


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