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

HPC-GAP: Tweak NEW_TYPE cache #1326

Merged
merged 3 commits into from
May 31, 2017
Merged

Conversation

fingolfin
Copy link
Member

@fingolfin fingolfin commented May 9, 2017

This PR resumes work on issue #125. As there, let

stat:=function() return [NEW_TYPE_CACHE_HIT,NEW_TYPE_CACHE_MISS,NEW_TYPE_NEXT_ID]; end;;

Then before this PR, I get this:
Results for GAP:

gap> old:=stat();; g:=WreathProduct(MathieuGroup(9),Group((1,2)));; ConjugacyClassesSubgroups(g);; time; stat() - old;
3218
[ 218079, 997, 2532 ]
gap> old:=stat();; g:=WreathProduct(MathieuGroup(9),Group((1,2)));; ConjugacyClassesSubgroups(g);; time; stat() - old;
3151
[ 216761, 812, 864 ]

Results for HPC-GAP:

gap> old:=stat();; g:=WreathProduct(MathieuGroup(9),Group((1,2)));; ConjugacyClassesSubgroups(g);; time; stat() - old;
6579
[ 182171, 36834, 38436 ]
gap> old:=stat();; g:=WreathProduct(MathieuGroup(9),Group((1,2)));; ConjugacyClassesSubgroups(g);; time; stat() - old;
6412
[ 181780, 35794, 35870 ]

With this PR, I get this:

Results for GAP:

gap> old:=stat();; g:=WreathProduct(MathieuGroup(9),Group((1,2)));; ConjugacyClassesSubgroups(g);; time; stat() - old;
3312
[ 218052, 1023, 2559 ]
gap> old:=stat();; g:=WreathProduct(MathieuGroup(9),Group((1,2)));; ConjugacyClassesSubgroups(g);; time; stat() - old;
3192
[ 216760, 813, 865 ]

Results for HPC-GAP:

gap> old:=stat();; g:=WreathProduct(MathieuGroup(9),Group((1,2)));; ConjugacyClassesSubgroups(g);; time; stat() - old;
6446
[ 216463, 2584, 4144 ]
gap> old:=stat();; g:=WreathProduct(MathieuGroup(9),Group((1,2)));; ConjugacyClassesSubgroups(g);; time; stat() - old;
6369
[ 216691, 890, 959 ]

So the number of cache misses shrinks dramatically for HPC-GAP; on the second run, it's basically comparable to GAP. Unfortunately, the timing does not really change, so we still have a performance bottleneck in there :-/.

By the way, I really wonder what causes all those type objects for which LEN_POSOBJ return 6, yet only 4 entries in them are bound...

@fingolfin fingolfin added kind: enhancement Label for issues suggesting enhancements; and for pull requests implementing enhancements topic: HPC-GAP Issues and PRs related to HPC-GAP topic: performance bugs or enhancements related to performance (improvements or regressions) labels May 9, 2017
@codecov
Copy link

codecov bot commented May 10, 2017

Codecov Report

Merging #1326 into master will increase coverage by 0.01%.
The diff coverage is 87.41%.

@@            Coverage Diff             @@
##           master    #1326      +/-   ##
==========================================
+ Coverage   61.47%   61.48%   +0.01%     
==========================================
  Files        1049     1049              
  Lines      365607   365686      +79     
  Branches    15170    15181      +11     
==========================================
+ Hits       224752   224842      +90     
+ Misses     136833   136810      -23     
- Partials     4022     4034      +12
Impacted Files Coverage Δ
src/c_type1.c 75.02% <83.61%> (+0.87%) ⬆️
hpcgap/src/c_type1.c 65.48% <94.37%> (+0.21%) ⬆️
src/funcs.c 63.97% <0%> (-0.28%) ⬇️
src/stringobj.c 76.45% <0%> (-0.13%) ⬇️
src/compiler.c 60.94% <0%> (-0.1%) ⬇️
src/hpc/threadapi.c 30.45% <0%> (+0.18%) ⬆️
src/objset.c 39.88% <0%> (+0.56%) ⬆️
src/hpc/tls.h 67.5% <0%> (+2.5%) ⬆️

@fingolfin
Copy link
Member Author

So... OK to merge this then?

fi;
# so there is a parent type; make sure the any extra data in it
# if there is a parent type, make sure the any extra data in it
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"the" -> "that"

@markuspf markuspf merged commit de7f9b6 into gap-system:master May 31, 2017
@stevelinton
Copy link
Contributor

stevelinton commented Jun 1, 2017 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind: enhancement Label for issues suggesting enhancements; and for pull requests implementing enhancements topic: HPC-GAP Issues and PRs related to HPC-GAP topic: performance bugs or enhancements related to performance (improvements or regressions)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants