summaryrefslogtreecommitdiffstats
path: root/gcc/go
Commit message (Collapse)AuthorAgeFilesLines
...
* compiler: Build import tables as needed for imported interfaces.ian2012-05-031-0/+3
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@187111 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Fix order of initialization bug with global var a, b = f().ian2012-05-034-18/+85
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@187103 138bc75d-0d04-0410-961f-82ee72b054a4
* * cgraph.c (ld_plugin_symbol_resolution_names): Move to symtab.chubicka2012-04-302-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (cgraph_asm_nodes, cgraph_asm_last_node): Move to cgraphunit.c (cgraph_add_to_same_comdat_group): Remove. (cgraph_add_asm_node): Move to cgraphunit.c. (cgraph_make_decl_local): Move to symtab.c (cgraph_make_node_local_1): Update. (cgraph_can_remove_if_no_direct_calls_and): Update. (used_from_object_file_p): Update. (resolution_used_from_other_file_p): Move to symtab.c (cgraph_used_from_object_file_p): move to symtab.c (verify_cgraph_node): Verify same comdat groups. * cgraph.h (cgraph_asm_node): Rename to ... (asm_node): ... this one. (cgraph_asm_nodes): Rename to ... (asm_nodes): ... this one. (symtab_add_to_same_comdat_group): New function. (symtab_dissolve_same_comdat_group_list): New function. (symtab_used_from_object_file_p): Declare. (symtab_make_decl_local): Declare. (cgraph_add_to_same_comdat_group): Remove. (cgraph_add_asm_node): Remove. (cgraph_used_from_object_file_p, varpool_used_from_object_file_p): Remove. (cgraph_finalize_compilation_unit): Rename to ... (finalize_compilation_unit): ... this one. (cgraph_optimize): Rename to .... (compile): ... this one. (add_asm_node): Declare. (fixup_same_cpp_alias_visibility): Declare. (cgraph_make_decl_local): Remove. (varpool_assemble_pending_decls): Rename to ... (varpool_output_variables): ... this one. (varpool_remove_unreferenced_decls): Remove. * ipa-inline-transform.c (clone_inlined_nodes): Dissolve comdat groups. (preserve_function_body_p): Make static. * toplev.c (compile_file): Update comments; update. * cgraphunit.c: Update comments. (cgraph_expand_all_functions): Rename to ... (expand_all_functions): ... this one; update. (cgraph_mark_functions_to_output): Rename to ... (mark_functions_to_output): ... this one; cleanup. (cgraph_output_pending_asms): Remove prototype. (asm_nodes, asm_last_node): New static vars. (cgraph_process_new_functions): Update. (cgraph_reset_node): Cleanup; add comment. (cgraph_add_new_function): Update. (cgraph_output_pending_asms): Rename to ... (output_asm_statements): ... this one. (add_asm_node): New function. (fixup_same_cpp_alias_visibility): New function based on code in cgraph_analyze_function. (cgraph_analyze_function): Use it. (cgraph_order_sort): Update. (cgraph_output_in_order): Update. (cgraph_function_versioning): Update. (cgraph_optimize): Rename to ... (compile): ... this one; initialize streamer hooks here. (cgraph_finalize_compilation_unit): Rename to ... (finalize_compilation_unit): ... this one; do not initialize streamer hook here. * lto-streamer-out.c (lto_output_toplevel_asms): Update. * dwarf2out.c: Update ocmment. * optimize.c (maybe_clone_body): Use symtab_add_to_same_comdat_group. * method.c (use_thunk): Likewise. * semantics.c (maybe_add_lambda_conv_op): Likewise. * decl2.c (maybe_emit_vtables): Likewise. (cp_write_global_declarations): Use finalize_compilation_unit. * parser.c (cp_parser_asm_definition): Use add_asm_node. * lto-streamer-in.c (lto_input_toplevel_asms): Use add_asm_node * c-decl.c (c_write_global_declarations): Use finalize_compilation_unit. * langhooks.c (write_global_declarations): Update. * ipa.c (cgraph_externally_visible_p): Update. (dissolve_same_comdat_group_list): Remove. (function_and_variable_visibility): Update. * symtab.c: Inlcude lto-streamer.h and rtl.h (ld_plugin_symbol_resolution_names): New. (symtab_add_to_same_comdat_group): New. (symtab_dissolve_same_comdat_group_list): New. (resolution_used_from_other_file_p): Move here from cgraph.c (symtab_used_from_object_file_p): New. (symtab_make_decl_local): New. * passes.c (register_pass): Update comments. * c-parser.c (c_parser_asm_definition): Update. * varpool.c (varpool_analyze_node): Use fixup_same_cpp_alias_visibility. (varpool_remove_unreferenced_decls): Make static. (varpool_assemble_pending_decls): Rename to ... (varpool_output_variables): ... this one; call varpool_remove_unreferenced_decls. (varpool_used_from_object_file_p): Remove. * gogo-tree.cc (Gogo::write_globals): Use finalize_compilation_unit. * gcc-interface/utils.c (rest_of_subprog_body_compilation): Update comment. (gnat_write_global_declarations): Use finalize_compilation_unit. * f95-lang.c (gfc_finish): Update comments. * lto.c (lto_main): Use compile (). * lto-partition.c (partition_cgraph_node_p): Use symtab_used_from_object_file_p. (partition_varpool_node_p): Likewise. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186998 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Fix some crashes on invalid code.ian2012-04-282-2/+11
| | | | | | | Fixes issue 7. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186929 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Use less memory for array/slice literals.ian2012-04-281-97/+177
| | | | | | | Fixes issue 8 in gofrontend issues list. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186926 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Fix order of evalation for m[0] = len(m) when m is a map.ian2012-04-241-6/+12
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186772 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Reject invalid composite literals.ian2012-04-241-1/+10
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186766 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Error for invalid use of ... in call.ian2012-04-241-2/+22
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186739 138bc75d-0d04-0410-961f-82ee72b054a4
* * go-lang.c (go_langhook_init): Set MPFR precision to 256.ian2012-04-232-1/+5
| | | | | | | time: Adjust float expression so that it first integer context. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186727 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Correct handling of negative zero floating constant.ian2012-04-231-1/+7
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186722 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Don't call cgraph_mark_needed_node.ian2012-04-201-1/+0
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186644 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler, runtime: Add explicit checks for zero and overflow division.ian2012-04-205-29/+153
| | | | | | | | | * lang.opt: Add -fgo-check-divide-zero and -fgo-check-divide-overflow. * gccgo.texi (Invoking gccgo): Document new options. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186637 138bc75d-0d04-0410-961f-82ee72b054a4
* gcc/steven2012-04-182-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | * targhooks.c (default_case_values_threshold): Fix code style nit. * stmt.c (add_case_node, expand_case): Move logic to remove/reduce case range and type folding from here... * gimplify.c (gimplify_switch_expr): ... to here. Expect NULL_TREE type, as documented in tree.def fortran/ * trans-decl.c (gfc_trans_entry_master_switch): Build SWITCH_EXPR with NULL_TREE type instead of void_type_node. * trans-io.c (io_result): Likewise. * trans-stmt.c (gfc_trans_integer_select, gfc_trans_character_select): Likewise. go/ * go-gcc.cc (Gcc_backend::switch_statement): Build SWITCH_EXPR with NULL_TREE type instead of void_type_node. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186579 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: fix infinite recursion in string constant evaluation.ian2012-04-161-2/+16
| | | | | | | | | | | | | Fixes compilation of incorrect code: const f, g = g, f func S() []byte { return []byte(f) } The problem was already handled for numerical constants. Part of issue 3186 (go). git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186511 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Fix order of evaluation of struct composite literals.ian2012-03-302-7/+47
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@185990 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler, libgo: unsafe.{Sizeof,Alignof,Offsetof} return uintptr.ian2012-03-292-9/+13
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@185946 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: fix null-dereference on invalid len() arg.ian2012-03-281-2/+2
| | | | | | | | | | | | This patch fixes an ICE caused by syntax errors in arguments to unary built-in functions like len(). Updates issue 7. From Rémy Oudompheng. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@185935 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: avoid an ICE on bound interface methods used as values.ian2012-03-281-1/+2
| | | | | | | Updates issue 7. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@185933 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: fix method finalization of unnamed structs.ian2012-03-281-1/+5
| | | | | | | | | | Used to trigger an ICE on var v struct{I}; type I interface{} Updates issue 7. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@185931 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: fix crashes.ian2012-03-282-1/+3
| | | | | | | | | | | | | The compiler would crash on: if true || x, y := 1, 2 {} and var s string s = append(s, "hello") Reported in issue 3186. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@185928 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Rewrite handling of untyped numeric constants.ian2012-03-285-2054/+1667
| | | | | | | | Fixes various bugs when, e.g., using float or complex constants in integer contexts. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@185925 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Be more careful to follow GENERIC type rules.ian2012-03-093-6/+38
| | | | | | | | * go-gcc.cc (Gcc_backend::assignment_statement): Convert the rhs to the lhs type if necessary. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@185128 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Correct handling of sink receiver.ian2012-03-091-3/+2
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@185127 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Don't initialize zero sized variables.ian2012-03-085-5/+99
| | | | | | | | | | | | | | * go-gcc.cc (Gcc_backend::init_statement): Don't initialize a zero-sized variable. (go_non_zero_struct): New global variable. (Gcc_backend::non_zero_size_type): New function. (Gcc_backend::global_variable): Don't build an assignment for a zero-sized value. * go-c.h (go_non_zero_struct): Declare. * config-lang.in (gtfiles): Add go-c.h. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@185115 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Don't crash on array assignment.ian2012-03-081-2/+4
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@185092 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Don't crash if writing type functions too late due to error.ian2012-03-072-0/+11
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@185080 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Fix struct inheriting interface with varargs method.ian2012-03-071-2/+6
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@185060 138bc75d-0d04-0410-961f-82ee72b054a4
* libgo: Update to weekly.2012-02-14 release.ian2012-03-021-54/+0
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184798 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Reliably give errors on misuse of multiple value call.ian2012-03-011-13/+16
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184755 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Fix varargs functions that call recover.ian2012-03-012-1/+8
| | | | | | | Also fix a couple of crashes on invalid code. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184751 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Fix handling of indirection of circular types.ian2012-03-011-18/+22
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184686 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Avoid some compiler crashes on invalid code.ian2012-03-014-4/+15
| | | | | | | | | * go-gcc.cc (class Gcc_tree): Add set_tree method. (set_placeholder_pointer_type): When setting to a pointer to error, set to error_mark_node. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184684 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Fix unary ^ applied to typed signed integer constant.ian2012-03-011-3/+22
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184681 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Avoid various crashes on error conditions.ian2012-02-292-14/+34
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184675 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Fix handling of invalid types within invalid types.ian2012-02-292-20/+7
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184674 138bc75d-0d04-0410-961f-82ee72b054a4
* 2012-02-23 Richard Guenther <rguenther@suse.de>rguenth2012-02-232-1/+6
| | | | | | | | * go-gcc.cc (Gcc_backend::placeholder_pointer_type): Use build_distinct_type_copy. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184507 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Permit an empty interface to be embedded multiple times.ian2012-02-181-1/+1
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184363 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Permit (_) on left hand side of =.ian2012-02-171-1/+1
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184356 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: List imported packages in export information.ian2012-02-176-4/+74
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184355 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Add parameter names to export information.ian2012-02-179-46/+100
| | | | | | | * Make-lang.in (go/import.o): Add dependency on $(GO_LEX_H). git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184353 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Don't lower binary expressions with mismatched types.ian2012-02-171-0/+3
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184352 138bc75d-0d04-0410-961f-82ee72b054a4
* * gospec.c (lang_specific_driver): If linking, and no -o optionian2012-02-172-22/+41
| | | | | | | was used, add one. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184351 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Fix backend representation for interface methods.ian2012-02-171-2/+29
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184348 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Check for initialization loop in constant initializer.ian2012-02-171-2/+9
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184347 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Don't crash on erroneous unnamed integer type descriptor.ian2012-02-161-3/+3
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184318 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Lower constant string comparisons.ian2012-02-161-4/+35
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184316 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Fix crash: type T1 struct { F *[1]T2 } where T2 is a struct.ian2012-02-164-81/+352
| | | | | | | This will become bug417.go. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184299 138bc75d-0d04-0410-961f-82ee72b054a4
* compiler: Avoid crashes on erroneous input.ian2012-02-153-4/+15
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184274 138bc75d-0d04-0410-961f-82ee72b054a4
* PR go/48411ian2012-02-142-7/+25
| | | | | | | | | | | * Make-lang.in (gccgo-cross$(exeext)): New target. (go.all.cross): Depend on gccgo-cross$(exeext) instead of gccgo$(exeext). (go.install-common): Only install GCCGO_TARGET_INSTALL_NAME if gccgo-cross$(exeext) does not exist. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184221 138bc75d-0d04-0410-961f-82ee72b054a4
* math: Compile with -mfancy-math-387 -funsafe-optimizations on x86.ian2012-02-081-1/+2
| | | | git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184015 138bc75d-0d04-0410-961f-82ee72b054a4
OpenPOWER on IntegriCloud