FIX_REGISTER_CHECK

Jim Wilson wilson@cygnus.com
Mon Oct 12 13:10:00 GMT 1998


	While I agree that users should understand the features they are using,
	I don't agree that an internal error/abort, is an constructive way to
	tell them they done something wrong.  

I agree.  compiler aborts and core dumps should always be fixed.  However,
this is the first time you mentioned that there was such a problem.  You did
not mention this when you submitted the patch.  I thought you were just
trying to add a helpful but not strictly necessary error message.  Now I
see that you are trying to fix a serious problem.

The abort is being called because of a -fcall-saved-$fp option.  This
confuses the caller-save code, and we hit the regno_save_mem abort in
insert_save_restore.  I'd suspect the problem is specific to the FP,
because reload does stuff with FP that would conflict with -fcall-saved-$fp,
but this is not true for most other registers.

I already mentioned that fp and sp are invalid for all targets, so you could
add machine independent code to give an error for these two registers.  This
avoids the abort without requiring a new macro.

Jim



More information about the Gcc-patches mailing list