-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sharing GenBcode backend between scalac and dotty #4136
Commits on Nov 14, 2014
-
1
Configuration menu - View commit details
-
Copy full SHA for 3d66b0d - Browse repository at this point
Copy the full SHA 3d66b0dView commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 7537cb6 - Browse repository at this point
Copy the full SHA 7537cb6View commit details -
1
Configuration menu - View commit details
-
Copy full SHA for f15d62a - Browse repository at this point
Copy the full SHA f15d62aView commit details -
1
Configuration menu - View commit details
-
Copy full SHA for e081724 - Browse repository at this point
Copy the full SHA e081724View commit details
Commits on Nov 17, 2014
-
1
Configuration menu - View commit details
-
Copy full SHA for 61fac46 - Browse repository at this point
Copy the full SHA 61fac46View commit details
Commits on Nov 18, 2014
-
1
Configuration menu - View commit details
-
Copy full SHA for 31e1c55 - Browse repository at this point
Copy the full SHA 31e1c55View commit details -
Make sure genIcode and genASM compile.
They are using primitives and opcodes that were extracted to objects.
1Configuration menu - View commit details
-
Copy full SHA for 78acb5a - Browse repository at this point
Copy the full SHA 78acb5aView commit details -
Use name-based pattern matching for deconstructors, using same instan…
…ces. Saves allocations but breaks thread-safety of BackendInterface.
1Configuration menu - View commit details
-
Copy full SHA for c93b3b4 - Browse repository at this point
Copy the full SHA c93b3b4View commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 7131476 - Browse repository at this point
Copy the full SHA 7131476View commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 284915c - Browse repository at this point
Copy the full SHA 284915cView commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 3c89b52 - Browse repository at this point
Copy the full SHA 3c89b52View commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 4c66397 - Browse repository at this point
Copy the full SHA 4c66397View commit details
Commits on Nov 19, 2014
-
1
Configuration menu - View commit details
-
Copy full SHA for 6783bec - Browse repository at this point
Copy the full SHA 6783becView commit details
Commits on Nov 20, 2014
-
Fixing bugs introduced while porting.
ArrayClass is magical. Several methods had recursive implementation. PatternMatching was shadowing parameter.
1Configuration menu - View commit details
-
Copy full SHA for de1efa9 - Browse repository at this point
Copy the full SHA de1efa9View commit details -
1
Configuration menu - View commit details
-
Copy full SHA for b1d096f - Browse repository at this point
Copy the full SHA b1d096fView commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 9986e7d - Browse repository at this point
Copy the full SHA 9986e7dView commit details -
5
Configuration menu - View commit details
-
Copy full SHA for d37adac - Browse repository at this point
Copy the full SHA d37adacView commit details
Commits on Nov 24, 2014
-
Move in shared implementation between dotty and scalac.
Those methods ended having same implementation in dotty and scalac. And even more they are implemented in terms of what is already part of exposed abstractions. Providing default implementations, that can be overridden in backends if ever needed.
1Configuration menu - View commit details
-
Copy full SHA for 82d137f - Browse repository at this point
Copy the full SHA 82d137fView commit details -
Workaround name-based pattern matching creating tuples for ValDefs.
1Configuration menu - View commit details
-
Copy full SHA for 9300268 - Browse repository at this point
Copy the full SHA 9300268View commit details
Commits on Nov 25, 2014
-
Fix error in BCodeBodyBuilder.
Found by just looking at the code. Interestingly enough none of the tests broke.
1Configuration menu - View commit details
-
Copy full SHA for 2d0104d - Browse repository at this point
Copy the full SHA 2d0104dView commit details
Commits on Nov 26, 2014
-
Get rid of most of allocations in ScalacBackendInterface
By reusing same decorator instances.
1Configuration menu - View commit details
-
Copy full SHA for 20b3c04 - Browse repository at this point
Copy the full SHA 20b3c04View commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 0b2e0c5 - Browse repository at this point
Copy the full SHA 0b2e0c5View commit details -
Make reading of source easier by giving a bit more structure.
Also gather in one place Product1s
1Configuration menu - View commit details
-
Copy full SHA for fa98eea - Browse repository at this point
Copy the full SHA fa98eeaView commit details
Commits on Nov 27, 2014
-
1
Configuration menu - View commit details
-
Copy full SHA for fa67f6c - Browse repository at this point
Copy the full SHA fa67f6cView commit details -
In Scalac any function call has Select as it function. In dotty it could be an Ident. Eg in Scalac you get Select(Preded$, println); while in dotty you get Ident(println) In order to get actual receiver need to either look at the type(which is TermRef) or at owner chain. First one is more systematic but is isn't exposed in the abstraction API, so using the second one.
1Configuration menu - View commit details
-
Copy full SHA for f9b3cf1 - Browse repository at this point
Copy the full SHA f9b3cf1View commit details -
TypeApply's are free to not have a Apply node around them in dotty.
1Configuration menu - View commit details
-
Copy full SHA for 0e1fec4 - Browse repository at this point
Copy the full SHA 0e1fec4View commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 084cc06 - Browse repository at this point
Copy the full SHA 084cc06View commit details
Commits on Dec 2, 2014
-
Minimal set of modifications to allow to support both dotty <label> D…
…efDefs and scalac LabelDefs DefDefs are assumed to be grouped in blocks that share same return address used to jump back.
1Configuration menu - View commit details
-
Copy full SHA for 5b1ef8c - Browse repository at this point
Copy the full SHA 5b1ef8cView commit details -
A bit more abstraction on what are primitives and operations on them.
Required to support arrays in dotty. Operations on those couldn't be decided based on symbol.
1Configuration menu - View commit details
-
Copy full SHA for b8d14a1 - Browse repository at this point
Copy the full SHA b8d14a1View commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 2d22839 - Browse repository at this point
Copy the full SHA 2d22839View commit details -
Handle Dotty Closures. Generate InvokeDynamic for them. Give a basis …
…to generate them for Scalac Based on https://github.com/retronym/scala/compare/topic/invoke-dynamic-lambda adapted to abstract from global.
1Configuration menu - View commit details
-
Copy full SHA for e6c183a - Browse repository at this point
Copy the full SHA e6c183aView commit details
Commits on Dec 3, 2014
-
1
Configuration menu - View commit details
-
Copy full SHA for 77f2fad - Browse repository at this point
Copy the full SHA 77f2fadView commit details -
1
Configuration menu - View commit details
-
Copy full SHA for d62f7bf - Browse repository at this point
Copy the full SHA d62f7bfView commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 0581a7c - Browse repository at this point
Copy the full SHA 0581a7cView commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 61fb9a5 - Browse repository at this point
Copy the full SHA 61fb9a5View commit details
Commits on Dec 4, 2014
-
1
Configuration menu - View commit details
-
Copy full SHA for 57274f8 - Browse repository at this point
Copy the full SHA 57274f8View commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 1439f45 - Browse repository at this point
Copy the full SHA 1439f45View commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 5215341 - Browse repository at this point
Copy the full SHA 5215341View commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 0bbab5c - Browse repository at this point
Copy the full SHA 0bbab5cView commit details
Commits on Dec 5, 2014
-
1
Configuration menu - View commit details
-
Copy full SHA for 8628f92 - Browse repository at this point
Copy the full SHA 8628f92View commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 2712a22 - Browse repository at this point
Copy the full SHA 2712a22View commit details -
1
Configuration menu - View commit details
-
Copy full SHA for 658e2f6 - Browse repository at this point
Copy the full SHA 658e2f6View commit details -
Handle dotty Idents by desugaring them into selects.
Handling Ident's in dotty requires analysing its type, Instead of exporting a lot of abstractions around types I'd better go with a single method that hides this.
Configuration menu - View commit details
-
Copy full SHA for 9392c81 - Browse repository at this point
Copy the full SHA 9392c81View commit details -
SI-9003 Eagerly capture more potentially mutable binders
This is a re-run of SI-5158 in two different contexts. As reported, the result of `unapply[Seq]` under name based pattern matching might not guarantee stability of results of calls to `_1`, `apply(i)`, etc, so we call these eagerly, and call them once only. I also found a case in regular pattern matching that we hadn't accounted for: extracting elements of sequences (either from a case class or from an `unapplySeq`) may also be unstable. This commit changes `ExtractorTreeMaker` to force storage of such binders, even under `-optimize`. This parallels the change to `ProductExtractorTreeMaker` in 8ebe8e3. I have added a special case for traditional `unapply` methods returning `Option`. This avoids a change for: ``` % cat test/files/run/t9003b.scala object Single { def unapply(a: Any) = Some("") } object Test { def main(args: Array[String]): Unit = { "" match { case Single(x) => (x, x) } } } % qscalac -optimize -Xprint:patmat test/files/run/t9003b.scala 2>&1 | grep --context=5 get case <synthetic> val x1: Any = ""; case5(){ <synthetic> val o7: Some[String] = Single.unapply(x1); if (o7.isEmpty.unary_!) matchEnd4({ scala.Tuple2.apply[String, String](o7.get, o7.get); () }) else case6() }; % scalac-hash v2.11.4 -optimize -Xprint:patmat test/files/run/t9003b.scala 2>&1 | grep --context=5 get case <synthetic> val x1: Any = ""; case5(){ <synthetic> val o7: Some[String] = Single.unapply(x1); if (o7.isEmpty.unary_!) matchEnd4({ scala.Tuple2.apply[String, String](o7.get, o7.get); () }) else case6() }; ```
Configuration menu - View commit details
-
Copy full SHA for 3ec6c6f - Browse repository at this point
Copy the full SHA 3ec6c6fView commit details -
Even more handling of primitives by trees.
needed to handle array_clone in dotty. Which doesn't have a symbol but isn't byte code primitive operation
1Configuration menu - View commit details
-
Copy full SHA for cdaf6dc - Browse repository at this point
Copy the full SHA cdaf6dcView commit details
Commits on Dec 12, 2014
-
1
Configuration menu - View commit details
-
Copy full SHA for beaa78b - Browse repository at this point
Copy the full SHA beaa78bView commit details