This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH] Fix sethi sparc64 patterns
- To: "David S. Miller" <davem at redhat dot com>
- Subject: [PATCH] Fix sethi sparc64 patterns
- From: Jakub Jelinek <jakub at redhat dot com>
- Date: Tue, 7 Dec 1999 13:27:41 +0100
- Cc: gcc-patches at egcs dot cygnus dot com
Hi!
In contract with what the comment in sparc.md sais about sethi
medlow/embmedany patterns, the clobber registers are never generated from
the C code and thus never matched.
This patch fixes compiling sparc64 code in medlow and embmedany memory
models.
Cheers,
Jakub
___________________________________________________________________
Jakub Jelinek | jakub@redhat.com | http://sunsite.mff.cuni.cz/~jj
Linux version 2.3.18 on a sparc64 machine (1343.49 BogoMips)
___________________________________________________________________
1999-12-07 Jakub Jelinek <jakub@redhat.com>
* config/sparc/sparc.md (sethi_di_medlow_embmedany_pic): Fix pattern
so that it is actually matched.
(sethi_di_medlow): Likewise.
--- gcc/config/sparc/sparc.md.jj Wed Dec 1 09:04:37 1999
+++ gcc/config/sparc/sparc.md Wed Dec 1 09:17:50 1999
@@ -2444,9 +2516,7 @@
(define_insn "*sethi_di_medlow_embmedany_pic"
[(set (match_operand:DI 0 "register_operand" "=r")
- (high:DI (match_operand:DI 1 "sp64_medium_pic_operand" "")))
- ;; The clobber is here because emit_move_sequence assumes the worst case.
- (clobber (reg:DI 1))]
+ (high:DI (match_operand:DI 1 "sp64_medium_pic_operand" "")))]
"(TARGET_CM_MEDLOW || TARGET_CM_EMBMEDANY) && check_pic (1)"
"sethi\\t%%hi(%a1), %0"
[(set_attr "type" "move")
@@ -2454,9 +2524,7 @@
(define_insn "*sethi_di_medlow"
[(set (match_operand:DI 0 "register_operand" "=r")
- (high:DI (match_operand:DI 1 "symbolic_operand" "")))
- ;; The clobber is here because emit_move_sequence assumes the worst case.
- (clobber (reg:DI 1))]
+ (high:DI (match_operand:DI 1 "symbolic_operand" "")))]
"TARGET_CM_MEDLOW && check_pic (1)"
"sethi\\t%%hi(%a1), %0"
[(set_attr "type" "move")