Richard Kenner [Wed, 27 Dec 1995 20:21:02 +0000 (15:21 -0500)]
(regno_pointer_align): New variable.
(gen_reg_rtx): Extend regno_pointer_align table.
Allocate tables in saveable obstack.
(mark_reg_pointer): New arg, ALIGN.
(gen_inline_header): New args for reg info.
(set_new_first_and_last_insn): Set cur_insn_uid.
({save,restore}_emit_status): Save and restore regno_pointer_align.
(restore_reg_data{,_1}): Deleted.
(init_emit): Allocate register tables in saveable obstack.
Set REGNO_POINTER_ALIGN for regs pointing into frame.
Jeff Law [Mon, 25 Dec 1995 05:46:32 +0000 (22:46 -0700)]
pa.c (output_function_epilogue): Use assemble_integer rather than calling ASM_OUTPUT_INT directly.
* pa.c (output_function_epilogue): Use assemble_integer rather
than calling ASM_OUTPUT_INT directly.
* pa.h (ASM_OUTPUT_INT): Use plabels for everything in the
exception table section.
* pa.c (print_operand): Don't call fprintf to output a register
name. Use fputs instead.
Richard Kenner [Sun, 24 Dec 1995 22:43:00 +0000 (17:43 -0500)]
(FUNCTION_BLOCK_PROFILER, BLOCK_PROFILER): Extension for -ax option (profile_block_flag == 2).
(FUNCTION_BLOCK_PROFILER, BLOCK_PROFILER): Extension for -ax
option (profile_block_flag == 2).
(MACHINE_STATE_SAVE,MACHINE_STATE_RESTORE): New macros.
(FUNCTION_BLOCK_PROFILER_EXIT): New macro.
Richard Kenner [Sun, 24 Dec 1995 22:42:24 +0000 (17:42 -0500)]
(struct bb): Add flags field.
(HAVE_POPEN): Test new define.
(struct __bb, struct bb_{edge,func}): New structs.
(__bb_init_{prg,file},__bb_{init,exit}_trace_func,__bb_trace_ret,
(__bb_trace_func{,_ret},gopen,gclose): New functions.
Richard Kenner [Sun, 24 Dec 1995 11:37:15 +0000 (06:37 -0500)]
(struct clear_by_pieces): New structure.
(clear_by_pieces{,_1}, {is,mostly}_zeros_p): New functions.
(clrstr_optab): New optab.
(clear_storage): Rework to try to use clear_by_pieces, then
new clrstr insn, then library call.
(store_constructor): Track if target is already cleared.
Clear target first if CONSTRUCTOR is mostly zeros.
Don't write zeros if target has been cleared.
Add new arg to clear_storage call.
(expand_expr, case CONSTRUCTOR): Don't put static constructor
in memory if mostly zero.
Jim Wilson [Tue, 19 Dec 1995 02:01:45 +0000 (18:01 -0800)]
(emit_block_move): When call emit_libary_call for bcopy,
pass arguments using correct types and modes.
(emit_push_insn, expand_assignment): Likewise.
(clear_storage, store_expr): Likewise for memset and bzero.
(store_constructor): Likewise for memset.
Mike Stump [Mon, 18 Dec 1995 17:42:56 +0000 (17:42 +0000)]
libgcc2.c (__empty): An empty function used by the C++ frontend for defaulting cleanup actions.
* libgcc2.c (__empty): An empty function used by the C++ frontend for
defaulting cleanup actions.
* tree.c (save_tree_status, restore_tree_status): Save and restore
temporary_firstobj, so that in progress objects that live on the
temporary obstack are not reallocated, if we save and restore the
tree status in their lifetime.
Jeff Law [Mon, 18 Dec 1995 01:31:12 +0000 (18:31 -0700)]
sched.c (canon_rtx): Recursively look for equivalences; look for expressions equivalent to MEMs.
* sched.c (canon_rtx): Recursively look for equivalences;
look for expressions equivalent to MEMs.
(true_dependence): Canonicalize inputs before operating
on their values.
(anti_dependence, output_dependence): Likewise.
* jump.c (follow_jumps): Don't follow an unconditional jump
that is not a simple_jump.
(expand_expr, case MULT_EXPR): Generalize code for widening
multiply to handle signed widening multiply when only unsigned optab
is defined, and vice versa.
Richard Kenner [Sun, 17 Dec 1995 11:56:42 +0000 (06:56 -0500)]
Try harder not to open or stat the same include file twice.
Simplify include file names so that they are more likely to match.
E.g. simplify "./a//b" to "a/b". Represent directories with simplified
prefixes, e.g. replace "./a//b" with "a/b/", and "." with "".
(absolute_filename): New function.
(do_include): Use it.
(read_name_map): Likewise; this makes things more consistent for DOS.
(main, do_include, open_include_file): -M output now contains operands
of -imacros and -include.
(skip_to_end_of_comment): When copying a // comment, don't try to
change it to a /* comment.
(rescan, skip_if_group, skip_to_end_of_comment, macarg1): Tune.
(rescan, skip_if_group, skip_to_end_of_comment, macarg1):
If warn_comments is nonzero, warn if backslash-newline appears
in a // comment. Simplify method for finding /* /* */ comment.
(skip_if_group): Optionally warn if /* /* */ appears between # and
a directive inside a skipped if group.
(macarg): Optionally warn if /* /* */ appears in a macro argument.
(strncat, VMS_strncat, vms_ino_t, ino_t): Remove.
(INCLUDE_LEN_FUDGE): Add 2 if VMS, for trailing ".h".
(INO_T_EQ, INO_T_HASH): New macros.
(struct file_buf): New member `inc'.
(expand_to_temp_buffer): Initialize it.
(struct file_name_list): New member `inc'.
(struct file_name_list): New member `st'.
c_system_include_path is now 1 if not 0.
fname is now an array, not a pointer.
(struct include_file): New members `next_ino', `deps_output', `st'.
Remove members `inode' and `dev'; they are now in `st'.
(INCLUDE_HASHSIZE): Rename from INCLUDE_HASH_SIZE.
(include_hashtab): Rename from include_hash_table.
(include_ino_hashtab): New variable.
(main): Store file status in struct stat, not in long and int pieces.
Use base_name to strip prefixes from file names.
When printing directory prefixes, omit trailing / and print "" as ".".
Fatal error if the input file is a directory.
(main, path_include): Regularize operands of -include, -imacros,
-isystem, -iwithprefix, and -iwithprefixbefore.
Regularize default include directories.
(do_include):
Allocate dsp with alloca, since fname is now dynamically allocated.
Use -3 to represent a never-opened file descriptor.
Make copy of file name, and simplify the copy.
Use base_name to identify the end of fname's directory.
Do not prepend dir for "..." if it matches the search list's first dir.
open_include_file now subsumes redundant_include_p and lookup_import.
Use bypass_slot to remember when to skip directories when including
a file that has already been seen.
Instead of using 0 to represent the working directory, and ""
to represent a directory to be ignored, use "" for the former,
and assume the latter has been removed before we get here.
Assume the directory prefixes have already been simplified.
Report as errors all open failures other than ENOENT.
Fatal error if fstat fails.
Use new deps_output member to avoid printing dependencies twice.
(bypass_hashtab): New variable.
(do_include, open_control_file, record_control_macro): New convention:
control_macro is "" if the file was imported or had #pragma once.
(pragma_once_marker): Remove.
(redundant_include_p, include_hash, lookup_include, lookup_import,
add_import, file_size_and_mode): Remove; subsumed by open_include_file.
(skip_redundant_dir_prefix): Remove; subsumed by simplify_filename.
(is_system_include, read_name_map, remap_include_file):
Assume arg is a directory prefix.
(base_name, simplify_filename, remap_include_file,
lookup_ino_include, new_include_prefix): New functions.
(open_include_file): New arguments `importing' and `pinc'.
Move filename mapping into new remap_include_file function.
First try to find file by name in include_hashtab;
if that doesn't work, open and fstat it and try to find it
by inode and dev in include_ino_hashtab.
(finclude): Get file status from inc->st instead of invoking fstat.
Store inc into fp->inc so that record_control_macro doesn't
need to do a table lookup.
(finclude, record_control_macro): Accept struct include_file *
instead of char * to identify include file. All callers changed.
(check_precompiled): Get file status from new argument `st'.
(do_pragma): Output at most one warning about #pragma implementation.
Always return 0 instead of returning garbage sometimes.
(do_pragma, hack_vms_include_specification):
Use base_name for consistency, and remove redundant code.
From Per Bothner:
Unify the 3 separate mechanisms for avoiding processing
of redundant include files: #import, #pragma once, and
redundant_include_p to use a single more efficient data structure.
(struct file_name_list): Remove no-longer needed field control_macro.
(dont_repeat_files, all_include_files): Remove, no longer used.
(struct import_file): Renmed to struct include_file, moved earlier
in file, renamed field name to fname, and added control_macro field.
(pragma_once_marker): New constant.
(import_hash_table): Renamed to include_hash_table.
(import_hash): Renamed to include_hash.
(IMPORT_HASH_SIZE): Renamed to INCLUDE_HASH_SIZE.
(main, path_include): Don't clear removed control_macro field.
(lookup_include): New function - look up fname in include_hash_table.
(redundant_include_p): Re-write to use lookup_include.
(lookup_import, record_control_macro): Likewise.
(add_import): Defer fstat to caller. Combine two xmallocs into one.
(do_once): Use pragma_once_marker in include_hash_table.
(do_pragma): Re-implement to scan include_hash_table.
(do_include): Use new lookup_include and add_import.