This is the mail archive of the
mailing list for the GCC project.
Re: Inserting function calls
- From: Zdenek Dvorak <rakdver at atrey dot karlin dot mff dot cuni dot cz>
- To: jean-christophe dot beyler at ulp dot u-strasbg dot fr
- Cc: gcc at gcc dot gnu dot org, dnovillo at redhat dot com
- Date: Thu, 31 Aug 2006 00:16:36 +0200
- Subject: Re: Inserting function calls
- References: <firstname.lastname@example.org>
> I have been trying to insert function calls during a new pass in the
> compiler but it does not seem to like my way of doing it. The basic
> idea is to insert a function call before any load in the program
> (later on I'll be selecting a few loads but for now I just want to do
> it for each and every one).
> This looks like the profiling pass but I can't seem to understand what
> is the matter...
> This is what the compiler says when I try to compile this test case :
> >hello.c:18: internal compiler error: tree check: expected ssa_name,
> >have symbol_memory_tag in verify_ssa, at tree-ssa.c:776
what you do seems basically OK to me. The problem is that you also need
to fix the ssa form for the virtual operands of the added calls
(i.e., you must call mark_new_vars_to_rename for each of the calls,
and update_ssa once at the end of tree_handle_loop).