+TraceTruffleCompilation: More detailed infos on optimization
    Gero Leinemann 
    gero.leinemann at oracle.com
       
    Wed Oct  1 13:22:51 UTC 2014
    
    
  
Hi Andreas,
first of all: Sorry if I my mail was a bit confusing. My question was 
solely about the logging output.
> I'd argue a function is best identified by its source location and it's
> useful to capture the name at function assignment as an identifier (at
> parse time), which is not a property of the call site. If I understand
> you correctly, then for this piece of code:
> name = function() { bla }; other = name; other();
> you would identify "other" as the function name rather than "name"?
Of course the concrete link "call site -> call target" is a language 
specific one, and I'm aware that there are several (mostly hacky) ways I 
could modify "rootNode.toString()" as language implementor to modify the 
output. Right.
> I'm not convinced it is useful to refer to the call site that triggered the compile(). There can be any number of call sites per call target and which one triggers may depend on compilation policy.
In theory: yes, the information is redundant, and may be misleading for 
beginners.
If one's aware of the fact that compilation might be triggered from 
different call sites (and it's non-deterministic) this is no problem, 
but from the user point of view a very helpful (esp. time-saving) 
additional bit of information while skimming stdout for compiled functions.
Basically my question is if you know a clean way to add the 
SourceSection of the CallNode to the "opt done" output in Truffle (maybe 
sth. like "TriggerHint: fun(a, b, c)").
If not, or an implementation does not make sense from the framework 
implementor point of view (unwanted changes to dependencies, API, etc.), 
I'll happily think about a FastR-specific solution.
Best Regards,
Gero
    
    
More information about the graal-dev
mailing list