-
Notifications
You must be signed in to change notification settings - Fork 161
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
Introduce -N switch to not use hidden implications #2246
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
############################################################################## | ||
## operdebug.g Frank Lübeck | ||
## | ||
## Non-documented utilities to write out infos about all methods of all | ||
## operations with location and rank, and to write out all filters by name | ||
## and their rank. These can be useful to debug larger changes that influence | ||
## the ranking of filters and methods. | ||
## | ||
|
||
# prints lines of format | ||
# name of operation;nr of args;filename:line (of method installation);rank | ||
BIND_GLOBAL("WriteMethodOverview", function(fname) | ||
local name, sline, relname, f; | ||
relname := function(path) | ||
local ls, s; | ||
for s in GAPInfo.RootPaths do | ||
ls := Length(s); | ||
if Length(path) >= ls and path{[1..ls]}=s then | ||
return path{[ls+1..Length(path)]}; | ||
fi; | ||
od; | ||
return path; | ||
end; | ||
sline := function(f) | ||
local n; | ||
n := StartlineFunc(f); | ||
if n=fail then | ||
return "\c"; | ||
fi; | ||
return Concatenation(":",String(n),"\c"); | ||
end; | ||
f := function() | ||
local nam, m, s, op, i, j; | ||
for op in OPERATIONS do | ||
nam := NameFunction(op); | ||
for i in [0..6] do | ||
m := METHODS_OPERATION(op, i); | ||
s := BASE_SIZE_METHODS_OPER_ENTRY + i; | ||
for j in [1..Length(m)/s] do | ||
Print(nam,";\c",i,";", | ||
relname(m[j*s][1]),":",m[j*s][2],";\c", | ||
m[j*s-2],"\n"); | ||
od; | ||
od; | ||
od; | ||
end; | ||
PrintTo1(fname, f); | ||
end); | ||
|
||
# prints file with lines of format | ||
# filter name (with some abbreviations);rank | ||
BIND_GLOBAL("WriteFilterRanks", function(fname) | ||
local f; | ||
f := function() | ||
local nams, rks, n, i; | ||
nams := List(FILTERS, NameFunction); | ||
rks := List(FILTERS, RankFilter); | ||
SortParallel(nams, rks); | ||
for i in [1..Length(nams)] do | ||
n := SubstitutionSublist(nams[i],"CategoryCollections","CC"); | ||
if Length(n) > 75 then | ||
n := Concatenation(n{[1..30]},"...",n{[Length(n)-29..Length(n)]}); | ||
fi; | ||
Print(n,";",rks[i],"\n"); | ||
od; | ||
end; | ||
PrintTo1(fname, f); | ||
end); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -92,7 +92,7 @@ BIND_GLOBAL( "GAPInfo", rec( | |
rec( short:= "B", default := "", arg := "<name>", help := [ "current architecture"] ), | ||
rec( short:= "D", default := false, help := ["enable/disable debugging the loading of files"] ), | ||
rec( short:= "M", default := false, help := ["disable/enable loading of compiled modules"] ), | ||
rec( short:= "N", default := false, help := ["unused, for backward compatibility only"] ), | ||
rec( short:= "N", default := false, help := ["do not use hidden implications"] ), | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @frankluebeck The comment above says "These options must be kept in sync with those in system.c" but that file is not even modified by this PR. Am I missing something? |
||
rec( short:= "O", default := false, help := ["disable/enable loading of obsolete files"] ), | ||
rec( short:= "T", default := false, help := ["disable/enable break loop"] ), | ||
rec( long := "quitonbreak", default := false, help := ["quit GAP with non-zero return value instead of entering break loop"]), | ||
|
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't it be much easier to put the check for the command line option into
InstallHiddenTrueMethod
? Then one can even keep callingWITH_HIDDEN_IMPS_FLAGS
below, as we'd be guaranteed that there are not hidden implications beyond the regular implications, and almost all changes on the library side could be removed.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The
if GAPInfo.CommandLineOptions.N
are introduced such that it is easy to find the places where the behaviour is changed by the-N
switch.