+2008-06-05 Richard Sandiford <rdsandiford@googlemail.com>
+
+ * config/mips/mips.c (mips_emit_loadgp): Emit a blockage if
+ current_function_profile.
+ * config/mips/mips.md (loadgp_blockage): Use SI rather than DI.
+
2008-05-29 Eric Botcazou <ebotcazou@adacore.com>
* tree-nested.c (check_for_nested_with_variably_modified): Fix typo.
offset = mips_unspec_address (addr, SYMBOL_GOTOFF_LOADGP);
incoming_address = gen_rtx_REG (Pmode, PIC_FUNCTION_ADDR_REGNUM);
emit_insn (gen_loadgp (offset, incoming_address));
- if (!TARGET_EXPLICIT_RELOCS)
+ if (!TARGET_EXPLICIT_RELOCS || current_function_profile)
emit_insn (gen_loadgp_blockage ());
}
}
}
[(set_attr "length" "12")])
-;; The use of gp is hidden when not using explicit relocations.
;; This blockage instruction prevents the gp load from being
;; scheduled after an implicit use of gp. It also prevents
;; the load from being deleted as dead.
(define_insn "loadgp_blockage"
- [(unspec_volatile [(reg:DI 28)] UNSPEC_BLOCKAGE)]
+ [(unspec_volatile [(reg:SI 28)] UNSPEC_BLOCKAGE)]
""
""
[(set_attr "type" "unknown")