Fix warnings to everything can be compiled with -Wall; Redo model specific changes once again to speed things up
This commit is contained in:
parent
46c065ab31
commit
45525d8d6d
6 changed files with 352 additions and 804 deletions
|
@ -1,3 +1,22 @@
|
|||
Fri Nov 24 11:24:34 1995 Michael Meissner <meissner@tiktok.cygnus.com>
|
||||
|
||||
* debug.h (ITRACE): Make printf_filtered arguments type correct.
|
||||
* idecode_expression.h (CR0_COMPARE): Ditto.
|
||||
* psim.c (psim_read_register): Ditto.
|
||||
|
||||
* igen.c (lf_print_my_prefix): Use __attribute__((__unused__)) to
|
||||
silence compiler warnings about unused automatically generated
|
||||
variables.
|
||||
(lf_print_c_extraction): Ditto.
|
||||
* idecode_expression.h (FPSCR_BEGIN): Ditto.
|
||||
|
||||
* ppc-cache-rules: Define rules for making a bitmask for all
|
||||
registers.
|
||||
|
||||
* ppc-instructions: Rewrite model specific functions to use the
|
||||
bitmask of the register number, instead of using the register
|
||||
pointer to get the register number, and then making the bitmask.
|
||||
|
||||
Wed Nov 22 15:24:27 1995 Michael Meissner <meissner@tiktok.cygnus.com>
|
||||
|
||||
* ppc-instructions (model_branches): Add conditional argument to
|
||||
|
|
|
@ -51,6 +51,7 @@ typedef enum {
|
|||
trace_idecode,
|
||||
trace_alu,
|
||||
trace_load_store,
|
||||
trace_model,
|
||||
/**/
|
||||
trace_vm,
|
||||
trace_core,
|
||||
|
@ -58,6 +59,7 @@ typedef enum {
|
|||
trace_device_init,
|
||||
trace_cpu,
|
||||
trace_breakpoint,
|
||||
trace_opts,
|
||||
nr_trace_options
|
||||
} trace_options;
|
||||
|
||||
|
@ -77,7 +79,7 @@ do { \
|
|||
#define ITRACE(OBJECT, ARGS) \
|
||||
do { \
|
||||
if (ppc_trace[OBJECT]) { \
|
||||
printf_filtered("%s:%d:0x%x", my_prefix, cpu_nr(processor) + 1, cia); \
|
||||
printf_filtered("%s:%d:0x%lx", my_prefix, (int)(cpu_nr(processor) + 1), (unsigned long)cia); \
|
||||
printf_filtered ARGS; \
|
||||
} \
|
||||
} while (0)
|
||||
|
|
|
@ -1316,13 +1316,13 @@ lf_print_my_prefix(lf *file,
|
|||
table_entry *file_entry,
|
||||
int idecode)
|
||||
{
|
||||
lf_printf(file, "const char *const my_prefix = \n");
|
||||
lf_printf(file, "const char *const my_prefix __attribute__((__unused__)) = \n");
|
||||
lf_printf(file, " \"%s:%s:%s:%d\";\n",
|
||||
filter_filename (file_entry->file_name),
|
||||
(idecode ? "idecode" : "semantics"),
|
||||
file_entry->fields[insn_name],
|
||||
file_entry->line_nr);
|
||||
lf_printf(file, "const itable_index my_index = ");
|
||||
lf_printf(file, "const itable_index my_index __attribute__((__unused__)) = ");
|
||||
lf_print_function_name(file,
|
||||
file_entry->fields[insn_name],
|
||||
NULL,
|
||||
|
@ -1804,7 +1804,7 @@ lf_print_c_extraction(lf *file,
|
|||
ASSERT(bits->field == cur_field);
|
||||
ASSERT(field_type == NULL);
|
||||
table_entry_lf_c_line_nr(file, instruction->file_entry);
|
||||
lf_printf(file, "const unsigned %s = ",
|
||||
lf_printf(file, "const unsigned %s __attribute__((__unused__)) = ",
|
||||
field_name);
|
||||
if (bits->opcode->last < bits->field->last)
|
||||
lf_printf(file, "%d;\n",
|
||||
|
@ -1815,7 +1815,7 @@ lf_print_c_extraction(lf *file,
|
|||
else {
|
||||
/* put the field in the local variable */
|
||||
table_entry_lf_c_line_nr(file, instruction->file_entry);
|
||||
lf_printf(file, "%s const %s = ",
|
||||
lf_printf(file, "%s const %s __attribute__((__unused__)) = ",
|
||||
field_type == NULL ? "unsigned" : field_type,
|
||||
field_name);
|
||||
/* getting it from the cache */
|
||||
|
@ -1919,7 +1919,7 @@ lf_print_c_extractions(lf *file,
|
|||
if (strncmp(is_0_ptr - field_len, field_name, field_len) == 0
|
||||
&& !isalpha(is_0_ptr[ - field_len - 1])) {
|
||||
table_entry_lf_c_line_nr(file, instruction->file_entry);
|
||||
lf_printf(file, "const unsigned %s_is_0 = (", field_name);
|
||||
lf_printf(file, "const unsigned %s_is_0 __attribute__((__unused__)) = (", field_name);
|
||||
if (bits != NULL)
|
||||
lf_printf(file, "%d", bits->value);
|
||||
else
|
||||
|
|
|
@ -55,29 +55,44 @@
|
|||
#
|
||||
1:RA:RA::
|
||||
1:RA:rA:signed_word *:(cpu_registers(processor)->gpr + RA)
|
||||
1:RA:RA_BITMASK:unsigned32:(1 << RA)
|
||||
1:RT:RT::
|
||||
1:RT:rT:signed_word *:(cpu_registers(processor)->gpr + RT)
|
||||
1:RT:RT_BITMASK:unsigned32:(1 << RT)
|
||||
2:RS:RS::
|
||||
1:RS:rS:signed_word *:(cpu_registers(processor)->gpr + RS)
|
||||
1:RS:RS_BITMASK:unsigned32:(1 << RS)
|
||||
2:RB:RB::
|
||||
1:RB:rB:signed_word *:(cpu_registers(processor)->gpr + RB)
|
||||
1:RB:RB_BITMASK:unsigned32:(1 << RB)
|
||||
2:FRA:FRA::
|
||||
1:FRA:frA:unsigned64 *:(cpu_registers(processor)->fpr + FRA)
|
||||
1:FRA:FRA_BITMASK:unsigned32:(1 << FRA)
|
||||
2:FRB:FRB::
|
||||
1:FRB:frB:unsigned64 *:(cpu_registers(processor)->fpr + FRB)
|
||||
1:FRB:FRB_BITMASK:unsigned32:(1 << FRB)
|
||||
2:FRC:FRC::
|
||||
1:FRC:frC:unsigned64 *:(cpu_registers(processor)->fpr + FRC)
|
||||
1:FRC:FRC_BITMASK:unsigned32:(1 << FRC)
|
||||
2:FRS:FRS::
|
||||
1:FRS:frS:unsigned64 *:(cpu_registers(processor)->fpr + FRS)
|
||||
1:FRS:FRS_BITMASK:unsigned32:(1 << FRS)
|
||||
2:FRT:FRT::
|
||||
1:FRT:frT:unsigned64 *:(cpu_registers(processor)->fpr + FRT)
|
||||
1:FRT:FRT_BITMASK:unsigned32:(1 << FRT)
|
||||
1:SI:EXTS_SI:unsigned_word:((signed_word)(signed16)instruction)
|
||||
2:BI:BI::
|
||||
1:BI:BIT32_BI::BIT32(BI)
|
||||
1:BF:BF::
|
||||
1:BF:BF_BITMASK:unsigned32:(1 << BF)
|
||||
2:BA:BA::
|
||||
1:BA:BIT32_BA::BIT32(BA)
|
||||
1:BA:BA_BITMASK:unsigned32:(1 << BA)
|
||||
2:BB:BB::
|
||||
1:BB:BIT32_BB::BIT32(BB)
|
||||
1:BB:BB_BITMASK:unsigned32:(1 << BB)
|
||||
1:BT:BT::
|
||||
1:BT:BT_BITMASK:unsigned32:(1 << BT)
|
||||
1:BD:EXTS_BD_0b00:unsigned_word:(((signed_word)(signed16)instruction) & ~3)
|
||||
#1:BD:CIA_plus_EXTS_BD_0b00:unsigned_word:CIA + EXTS(BD_0b00)
|
||||
1:LI:EXTS_LI_0b00:unsigned_word:((((signed_word)(signed32)(instruction << 6)) >> 6) & ~0x3)
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -97,7 +97,6 @@ int current_host_byte_order;
|
|||
int current_environment;
|
||||
int current_alignment;
|
||||
int current_floating_point;
|
||||
ppc_model current_ppc_model = WITH_DEFAULT_PPC_MODEL;
|
||||
model_enum current_model = WITH_DEFAULT_MODEL;
|
||||
|
||||
|
||||
|
@ -850,8 +849,8 @@ psim_read_register(psim *system,
|
|||
break;
|
||||
|
||||
default:
|
||||
printf_filtered("psim_read_register(processor=0x%x,buf=0x%x,reg=%s) %s\n",
|
||||
processor, buf, reg,
|
||||
printf_filtered("psim_read_register(processor=0x%lx,buf=0x%lx,reg=%s) %s\n",
|
||||
(unsigned long)processor, (unsigned long)buf, reg,
|
||||
"read of this register unimplemented");
|
||||
break;
|
||||
|
||||
|
@ -877,7 +876,7 @@ psim_read_register(psim *system,
|
|||
}
|
||||
}
|
||||
else {
|
||||
bcopy(cooked_buf, buf, description.size);
|
||||
memcpy(buf/*dest*/, cooked_buf/*src*/, description.size);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -934,7 +933,7 @@ psim_write_register(psim *system,
|
|||
}
|
||||
}
|
||||
else {
|
||||
bcopy(buf, cooked_buf, description.size);
|
||||
memcpy(cooked_buf/*dest*/, buf/*src*/, description.size);
|
||||
}
|
||||
|
||||
/* put the cooked value into the register */
|
||||
|
@ -969,8 +968,8 @@ psim_write_register(psim *system,
|
|||
break;
|
||||
|
||||
default:
|
||||
printf_filtered("psim_write_register(processor=0x%x,cooked_buf=0x%x,reg=%s) %s\n",
|
||||
processor, cooked_buf, reg,
|
||||
printf_filtered("psim_write_register(processor=0x%lx,cooked_buf=0x%lx,reg=%s) %s\n",
|
||||
(unsigned long)processor, (unsigned long)cooked_buf, reg,
|
||||
"read of this register unimplemented");
|
||||
break;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue