Commit 6a73009d by Jeff Law

pa.md (call expanders): For indirect calls, load %r22 with the function's address.

	* pa.md (call expanders): For indirect calls, load %r22 with the
	function's address.
	(indirect call patterns): No need to copy the call address into
	%r22 anymore.

	* pa.c (output_cbranch): Fix buglet in length handling of
	backwards branches with unfilled delay slots.
	(output_bb, output_bvb, output_dbra, output_movb): Likewise.

	* pa.md: Fix off-by-one error in length computations for all
	conditional branch patterns.

	* pa.h (output_bvb): Declare.
	* pa.c (output_bvb): New function to output branch on variable
	bit insns.
	* pa.md (branch-on-variable-bit): New patterns.

	* pa.h (TARGET_MILLICODE_LONG_CALLS): Delete swtich and all
	references.
	(output_millicode_call): Declare new function
	* pa.md (millicode calls): Update length computation to handle
	variable length millicode calls.
	(call pattners): Likewise.
	(indirect call patterns): Update length compuations and output
	templates to handle variable length millicode calls.
	(plabel_dereference): Likewise.
	* pa.c (override_options): Give warnings when incompatable
	options are used.
	(output_mul_insn): Call output_millicode_call instead of
	output_call, eliminate last argument to output_millicode_call.
	(output_div_insn): Likewise.
	(output_mod_insn): Likewise.
	(output_call): Rewrite long call code to handle variable length
	millicode calls.  Eliminate support for calling mul, div and mod
	millicode routines.
	(output_millicode_call): New function for calling mul, div and mod
	millicode routines.

From-SVN: r10610
parent 68944452
......@@ -70,25 +70,14 @@ extern int target_flags;
never cross a space boundary. Such assumptions are generally safe for
building kernels and statically linked executables. Code compiled with
this option will fail miserably if the executable is dynamically linked
or uses nested functions! */
#define TARGET_FAST_INDIRECT_CALLS (target_flags & 4)
or uses nested functions!
This is also used to trigger agressive unscaled index addressing. */
#define TARGET_NO_SPACE_REGS (target_flags & 4)
/* Allow unconditional jumps in the delay slots of call instructions. */
#define TARGET_JUMP_IN_DELAY (target_flags & 8)
/* In rare cases, a millicode call via "bl" can not be turned into
a millicode call using "ble" (when SHLIB_INFO subspace is very large).
This option forces just millicode calls to use inline long-calls
This is far more efficient than the old long-call option which forced
every function to be called indirectly (as is still the case for
TARGET_PORTABLE_RUNTIME).
??? What about simple jumps, they can suffer from the same problem.
Would require significant surgery in pa.md. */
#define TARGET_MILLICODE_LONG_CALLS (target_flags & 16)
/* Disable indexed addressing modes. */
#define TARGET_DISABLE_INDEXING (target_flags & 32)
......@@ -125,16 +114,14 @@ extern int target_flags;
{"pa-risc-1-1", 1}, \
{"disable-fpregs", 2}, \
{"no-disable-fpregs", -2}, \
{"fast-indirect-calls", 4}, \
{"no-fast-indirect-calls", -4},\
{"no-space-regs", 4}, \
{"space-regs", -4},\
{"jump-in-delay", 8}, \
{"no-jump-in-delay", -8}, \
{"millicode-long-calls", 16},\
{"no-millicode-long-calls", -16},\
{"disable-indexing", 32}, \
{"no-disable-indexing", -32},\
{"portable-runtime", 64+16},\
{"no-portable-runtime", -(64+16)},\
{"portable-runtime", 64}, \
{"no-portable-runtime", -64},\
{"gas", 128}, \
{"no-gas", -128}, \
{"soft-float", 256}, \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment