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]

are splits reliable?


Hi
The i386 instruction set is much better designed for SF and DF mode addresses
than XF mode (load/store instructions are faster, store is not limited and
can be used directly in arithmetic operations).
GCC tends to use constants in same type as operation is. This is not optimal
and GCC should attempt always to shorten constant as much as possible
and then use extended memory references.

My first attempt to implement this was by changing mov?f expands to use
expand?f patterns when possible and hacked mov?f conditions to refuse
moves that can be shortened.
This solution has lots of problems, because gcc still attempts to translate
expands to movs and is surprised by the fact, that mov can not be generated.

Other solution that comes into mind is to allow incorrect memory references
to constant pool in those patterns and use splitters to add necesary
extends.
Problem is that in case splitting is not done, this will result in incorrect
instructions. I believe splitting is done unconditionally now after reload,
but I am not sure if this will not change in future.

Do you think this is correct approach to handle this?
Honza
-- 
                       OK. Lets make a signature file.
+-------------------------------------------------------------------------+
|        Jan Hubicka (Jan Hubi\v{c}ka in TeX) hubicka@freesoft.cz         |
|         Czech free software foundation: http://www.freesoft.cz          |
|AA project - the new way for computer graphics - http://www.ta.jcu.cz/aa |
|  homepage: http://www.paru.cas.cz/~hubicka/, games koules, Xonix, fast  |
|  fractal zoomer XaoS, index of Czech GNU/Linux/UN*X documentation etc.  | 
+-------------------------------------------------------------------------+


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