This is the mail archive of the gcc-patches@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]

Re: movstrictqi/movstricthi fix for h8300



  In message <Pine.LNX.4.21.0009111304350.25281-100000@breve.cygnus.com>you wri
te:
  > 	The constraint modifiers for the destinations registers of these
  > patterns were specified as write-only.  This could cause the compiler to
  > generate a reload that clobbered data.  Setting these constraint modifiers
  > to read-write fixes the problem; moreover, the comment in reload.c
  > (push_reload) line 1045 indicates that this is the right thing to do.
  > 
  > 2000-09-11  Matthew Hiller  <hiller@redhat.com>
  > 
  > 	* config/h8300/h8300.md (movstrictqi): Changed constraint modifier
  > 	on operand 0 to '+'.
  > 	(movstricthi): Likewise.
Approved and installed.

For extra credit -- submit a testcase for the bug which led you to this
patch.

It also seems to me that this might be something we could have one of the
gen* programs check for since I believe every STRICT_LOW_PART is a 
read/write operand.  genoutput or genrecog would likely be the best
candidates.

jeff




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