rfc: clobber all call-saved registers
Richard Henderson
rth@redhat.com
Tue Jan 8 16:45:00 GMT 2002
On two instances in the last week, I've created reduced test
cases in which it was necessary to convince reload that it
could not put a particular value into a hard register in order
to elicit the problem. In both instances I had to create a
platform-specific test that used an asm to clobber all the
registers in question.
I hate creating platform specific tests for potentially generic
problems, since the problem is bound to show up somewhere else
as well. So what to do? I can think of two options:
(1) A header file somewhere in the testsuite that has a whole
whale-load of ifdefs and chooses the correct asm statement,
(2) A compiler builtin that generates the correct asm statement
based on the contents of call_used[].
Thoughts?
r~
More information about the Gcc
mailing list