Skip to content
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

Replace PackageOrganizerCache by RPackage #414

Closed
seandenigris opened this issue Aug 3, 2015 · 12 comments
Closed

Replace PackageOrganizerCache by RPackage #414

seandenigris opened this issue Aug 3, 2015 · 12 comments

Comments

@seandenigris
Copy link
Contributor

Originally reported on Google Code with ID 414

We have to check that RPackage and POC have exactly the same spec, but it should be
ok.

anyway, RPackage is significantly faster than POC and it would be a good way to stress
it before mainstream usage in Pharo.

Reported by simon.denier on 2010-06-11 13:32:58

@seandenigris
Copy link
Contributor Author

I started to replace PackageOrganizerCache by RPackage. What I did is:
-> first Look at all references to PackageOrganizerCache
-> replace those refererences by a corresponding use of RPackage
-> run tests and fix them one by one

I'm in a state where all tests seem to be green.
Now I don't know how we want to integrate that.  With stephane we talked about having
a kind of 'transition state': we would have the possibility to use either the PackageOrganizerCache
or either RPackage, so that if something's wrong, we can quickly return to a working
version of moose.
Or maybe it would be better to integrate that directly ?

I guess that there is also some test to make about the performance. By comparing quickly
with old result registered in MooseScripts, RPackage seems to be a bit slower than
POC.But I should make a more precise comparison using the same machine and vm for both.

To load the version using RPackage, in a moose image evaluate:

Gofer new
    squeaksource: 'PharoTaskForces';
    package: 'ConfigurationOfRPackage';
    load.

(Smalltalk globals at: #ConfigurationOfRPackage) loadDefault.

Gofer new
    squeaksource: 'DelaunayTmpStuffs';
    package: 'Moose-SmalltalkImporter';
    merge.

Gofer new
    squeaksource: 'DelaunayTmpStuffs';
    package: 'Moose-Tests-SmalltalkImporter-Core';
    merge.

Gofer new
    squeaksource: 'DelaunayTmpStuffs';
    package: 'Moose-Tests-SmalltalkImporter-KGB';
    merge.




Reported by cy.delaunay on 2010-11-04 10:10:03

@seandenigris
Copy link
Contributor Author

I implemented a class that run some benchmarks and then compare the twoversions of Moose
(the one using packageCache and the one using RPackage):

  Gofer new
     url: 'www.squeaksource.com/DelaunayTmpStuffs';
      package: 'BenchmarksMooseWithRPackage';
    load.

So in a fresh mooseImage:
  => first remove the method BogusInfo class >> package (which is in conflict with
'package method from RPackage')
  => evaluate 'BenchmarksMooseWithRPackage new runBenchmarks'

Here is the kind of result I have :


                                              PackageCache               RPackage

createModelForMorphic                         14652          12771          
createModelForPharo                           155803         153476         
createModelForMoose                           91940          125190         
createModelForNetwork                         3322           4463           
createModelForLAN                             24             2188           

So the two versions seem to have the same order of performances

Reported by cy.delaunay on 2010-11-09 15:10:44

@seandenigris
Copy link
Contributor Author

We should make the switch, especially given that in the future Pharo will adopt RPackage
:)

Reported by tudor.girba on 2011-01-23 00:23:04

@seandenigris
Copy link
Contributor Author

In fact to have your moose image working, better try with that:

Gofer new
        squeaksource: 'DelaunayTmpStuffs';
        package: 'Moose-SmalltalkImporter';
        version: 'Moose-SmalltalkImporter-cyrille_delaunay.102';
        merge.

    Gofer new
        squeaksource: 'DelaunayTmpStuffs';
        package: 'Moose-Tests-SmalltalkImporter-Core';
        version: 'Moose-Tests-SmalltalkImporter-Core-cyrille_delaunay.9';
        merge.

    Gofer new
        squeaksource: 'DelaunayTmpStuffs';
        package: 'Moose-Tests-SmalltalkImporter-KGB';
        version: 'Moose-Tests-SmalltalkImporter-KGB-cyrille_delaunay.3';
        merge.

    Gofer new
        squeaksource: 'DelaunayTmpStuffs';
        package: 'Moose-Core';
        version: 'Moose-Core-cyrille_delaunay.284';
        merge.

Reported by cy.delaunay on 2011-01-28 13:55:27

@seandenigris
Copy link
Contributor Author

To make the switch, what should I do? That is what I think:

  => save each modified package (the four that are mentioned above) in the moose repository.
  => add RPackage to the default configuration

Reported by cy.delaunay on 2011-01-28 14:06:47

@seandenigris
Copy link
Contributor Author

Reported by cy.delaunay on 2011-01-28 14:09:13

@seandenigris
Copy link
Contributor Author

we should also remove the existing package cache and make sure the tests are still green.
Can you try removing the package cache and then running the tests?

Reported by tudor.girba on 2011-01-28 14:12:24

@seandenigris
Copy link
Contributor Author

Gofer new
        squeaksource: 'PharoTaskForces';
        package: 'ConfigurationOfRPackage';
        load.
(Smalltalk at: #ConfigurationOfRPackage) perform: #loadDefault.

Gofer new
        squeaksource: 'DelaunayTmpStuffs';
        version: 'Moose-SmalltalkImporter-cyrille_delaunay.102';
        version: 'Moose-Tests-SmalltalkImporter-Core-cyrille_delaunay.9';
        version: 'Moose-Tests-SmalltalkImporter-KGB-cyrille_delaunay.3';
        version: 'Moose-Core-cyrille_delaunay.284';
        merge.

Reported by jannik.laval on 2011-01-28 14:33:59

@seandenigris
Copy link
Contributor Author

For me it works. The only tests that failed was the PackageOrganizerCacheTest, what
seems normal ;) So I remove this class also, and integrate that 

Reported by cy.delaunay on 2011-01-28 14:47:28

@seandenigris
Copy link
Contributor Author

Ok. Give it a try. Please also update the configuration of moose. When you are done,
I start another build.

Reported by tudor.girba on 2011-01-28 14:51:00

  • Labels added: Milestone-4.3

@seandenigris
Copy link
Contributor Author

This is done

Reported by cy.delaunay on 2011-01-28 15:17:48

@seandenigris
Copy link
Contributor Author

Reported by jannik.laval on 2011-01-28 20:06:23

  • Status changed: Fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant