|
@@ -2233,56 +2233,6 @@ $core.addClass("InliningError", $globals.SemanticError, [], "Compiler-Inlining")
|
|
|
$globals.InliningError.comment="Instances of InliningError are signaled when using an `InliningCodeGenerator`in a `Compiler`.";
|
|
|
|
|
|
|
|
|
-
|
|
|
-$core.addClass("InliningSemanticAnalyzer", $globals.SemanticAnalyzer, [], "Compiler-Inlining");
|
|
|
-$core.addMethod(
|
|
|
-$core.method({
|
|
|
-selector: "visitSendNode:",
|
|
|
-protocol: "visiting",
|
|
|
-fn: function (aNode){
|
|
|
-var self=this,$self=this;
|
|
|
-
|
|
|
-return $core.withContext(function($ctx1) {
|
|
|
-
|
|
|
-var $1,$2,$3,$receiver;
|
|
|
-$1=$recv(aNode)._superSend();
|
|
|
-if(!$core.assert($1)){
|
|
|
-$2=$recv($recv($globals.IRSendInliner)._inlinedSelectors())._includes_($recv(aNode)._selector());
|
|
|
-if($core.assert($2)){
|
|
|
-$recv(aNode)._shouldBeInlined_(true);
|
|
|
-$3=$recv(aNode)._receiver();
|
|
|
-if(($receiver = $3) == null || $receiver.a$nil){
|
|
|
-$3;
|
|
|
-} else {
|
|
|
-var receiver;
|
|
|
-receiver=$receiver;
|
|
|
-$recv(receiver)._shouldBeAliased_(true);
|
|
|
-}
|
|
|
-}
|
|
|
-}
|
|
|
-(
|
|
|
-
|
|
|
-$ctx1.supercall = true,
|
|
|
-
|
|
|
-($globals.InliningSemanticAnalyzer.superclass||$boot.nilAsClass).fn.prototype._visitSendNode_.apply($self, [aNode]));
|
|
|
-
|
|
|
-$ctx1.supercall = false;
|
|
|
-
|
|
|
-return self;
|
|
|
-
|
|
|
-}, function($ctx1) {$ctx1.fill(self,"visitSendNode:",{aNode:aNode},$globals.InliningSemanticAnalyzer)});
|
|
|
-
|
|
|
-},
|
|
|
-
|
|
|
-args: ["aNode"],
|
|
|
-source: "visitSendNode: aNode\x0a\x0a\x09aNode superSend ifFalse: [ \x0a\x09\x09(IRSendInliner inlinedSelectors includes: aNode selector) ifTrue: [\x0a\x09\x09\x09aNode shouldBeInlined: true.\x0a\x09\x09\x09aNode receiver ifNotNil: [ :receiver |\x0a\x09\x09\x09\x09receiver shouldBeAliased: true ] ] ].\x0a\x0a\x09super visitSendNode: aNode",
|
|
|
-referencedClasses: ["IRSendInliner"],
|
|
|
-
|
|
|
-messageSends: ["ifFalse:", "superSend", "ifTrue:", "includes:", "inlinedSelectors", "selector", "shouldBeInlined:", "ifNotNil:", "receiver", "shouldBeAliased:", "visitSendNode:"]
|
|
|
-}),
|
|
|
-$globals.InliningSemanticAnalyzer);
|
|
|
-
|
|
|
-
|
|
|
$core.addMethod(
|
|
|
$core.method({
|
|
|
selector: "asInlinedBlockResult",
|