This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC 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: "error: unable to generate reloads for...", any hints?


Thanks. But what does it mean by saying:
"Sometimes an insn can match more than one instruction pattern. Then
the pattern that appears first in the machine description is the one
used."
in section 14.10 of  gcc internal p259?
08 Feb 2007 00:09:21 -0800, Ian Lance Taylor <iant@google.com>:
"吴曦" <wu.andrew.xi@gmail.com> writes:

> I observe that there is a ld instruction in 3rd alternative, so I add
> a new define_insn before it in the hope that it will be matched
> firstly.

It doesn't work that way.  Your new instruction will wind up matching
all move instructions.  Reload will crash because the constraints
don't work.

Instead just change the existing movqi_internal insn.  Don't try to
write a new one.  Change the existing insn to use C code which checks
which_alternative instead of the @ list it uses now.

Ian


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