bug-kawa
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-kawa] [bug #43131] Poor support for re-defining toplevel variables


From: Per Bothner
Subject: [Bug-kawa] [bug #43131] Poor support for re-defining toplevel variables
Date: Fri, 05 Sep 2014 07:00:35 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2062.94 Safari/537.36

Update of bug #43131 (project kawa):

                  Status:                    None => Confirmed              
             Assigned to:                    None => bothner                

    _______________________________________________________

Follow-up Comment #1:

Yes, this kind a re-definition works poorly.  One problem is the interaction
with inlining.

Using --no-inline doesn't help - in fact it makes it worse:
version 1: 1
version 2: 1
version 3: 1
version 4: 1
version 5: 1
That seems like a bug which should be investigated.

Because of type propagation etc it difficult for redefinition to work
"correctly" in general.  What I'd like to do is implement a "development" mode
where we keep the source (or S-expressions) for each function.  We also keep
track of dependencies between functions.  Then if f depends on g, and g is
redefined or re-compiled, then we also re-compile f.

We should also have a mode where a function can be redefined, as long as the
parameter and returns types are compatible.  This can be done without
automatic function-level recompilation, as long as we keep the necessary
indirection (without inlining).  There is some code for this, but it isn't
quite right.  That at least could be fixed moderately easily I think.

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?43131>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]