--
You received this message because you are subscribed to the Google Groups "bazel-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bazel-discus...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/bazel-discuss/079389c8-730d-4877-82ea-c121c979efdf%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Thanks for the reply Damien.
In reverse order: scala needs the scala signature since the scala type system is larger than java. Extra aspects of the type system live in the signature, so you can't accurately compile scala without the signature.
Next: could we currently implement what we want using the proposed code from existing sbt incremental compiler to produce a key? I don't see how. The rules can't have any state about the previous run currently. So we have no way of knowing even if we compute the exact API whether or not we should run. The branch inside the rules to maybe not run the compile action, I don't see what we can compare to: if (apiSignature != what?)...
On Mon, Mar 6, 2017 at 5:24 PM P. Oscar Boykin <oscar....@gmail.com> wrote:Thanks for the reply Damien.
In reverse order: scala needs the scala signature since the scala type system is larger than java. Extra aspects of the type system live in the signature, so you can't accurately compile scala without the signature.Humm how is that preventing to get the signature in the ijar? Or do you mean the signature includes too much?
Next: could we currently implement what we want using the proposed code from existing sbt incremental compiler to produce a key? I don't see how. The rules can't have any state about the previous run currently. So we have no way of knowing even if we compute the exact API whether or not we should run. The branch inside the rules to maybe not run the compile action, I don't see what we can compare to: if (apiSignature != what?)...Well using worker that is technically possible but probably not desirable, especially having action that depends on the state of the compiler is terrible.
I don't really like the approach of providing a hash back to bazel because it is going to mess so much with assumptions of Bazel. Unfortunately I don't have a better idea on how to support that use case :(
To view this discussion on the web visit https://groups.google.com/d/msgid/bazel-discuss/CAE6AC94VpqLeN9EYDwzTWmbvzamTJnQvJUr5kpvMg83XT0vaOQ%40mail.gmail.com.
Ulf, Dmitry: friendly ping?
To unsubscribe from this group and stop receiving emails from it, send an email to bazel-discuss+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/bazel-discuss/079389c8-730d-4877-82ea-c121c979efdf%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "bazel-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bazel-discuss+unsubscribe@googlegroups.com.
Ulf, Dmitry: friendly ping?
To unsubscribe from this group and stop receiving emails from it, send an email to bazel-discus...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/bazel-discuss/079389c8-730d-4877-82ea-c121c979efdf%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "bazel-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bazel-discus...@googlegroups.com.
You received this message because you are subscribed to a topic in the Google Groups "bazel-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/bazel-discuss/MWE_CC_wg6o/unsubscribe.
To unsubscribe from this group and all its topics, send an email to bazel-discus...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/bazel-discuss/4363fffe-ac14-4e9a-b2c5-4a09752404b3%40googlegroups.com.
I'm still thinking you'd create a valid jar to compile against.
My question is "How hard is it to create Scala ijar?". I.e. a tool that produces a jar keeping enough information for scalac, but removing the rest.
If we already have a hashing algorithm that tells us only what is relevant, could we use that to create a canonicalizing algorithm that keeps only what is relevant?
Zinc hash algorithm: https://github.com/sbt/zinc/blob/5df5062c555d3acd9f9fb925f8206d606e51badd/internal/zinc-apiinfo/src/main/scala/xsbt/api/HashAPI.scala
If it were feasible, it would have two advantages
(1) Works with Bazel as it exists.
(2) If the algorithm was ever wrong, it would be fail deterministically, i.e. regardless of cache state.
> Well using worker that is technically possible but probably not desirable, especially having action that depends on the state of the compiler is terrible.
FYI, I like this as a solution to fast compile times ( https://groups.google.com/forum/#!topic/bazel-discuss/3iUy5jxS3S0 ). But only as a dev solution, where seconds make a big difference.
> The thing about an ijar is that you can compile against it. Making zinc able to compile without the jar but with just the interface file it extracts would be cool but I've been told by one sbt hacker that it would be fairly non-trivial.
I'm still thinking you'd create a valid jar to compile against.
My question is "How hard is it to create Scala ijar?". I.e. a tool that produces a jar keeping enough information for scalac, but removing the rest.
If we already have a hashing algorithm that tells us only what is relevant, could we use that to create a canonicalizing algorithm that keeps only what is relevant?
Zinc hash algorithm: https://github.com/sbt/zinc/blob/5df5062c555d3acd9f9fb925f8206d606e51badd/internal/zinc-apiinfo/src/main/scala/xsbt/api/HashAPI.scala
If it were feasible, it would have two advantages
(1) Works with Bazel as it exists.
(2) If the algorithm was ever wrong, it would be fail deterministically, i.e. regardless of cache state.
--
You received this message because you are subscribed to a topic in the Google Groups "bazel-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/bazel-discuss/MWE_CC_wg6o/unsubscribe.
To unsubscribe from this group and all its topics, send an email to bazel-discus...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/bazel-discuss/CALS-RZLQ%3Dd7nyOhqmG0Azq5DSVE%2BOtK2B1YUpdo-mcOP%2BmekSQ%40mail.gmail.com.