forked from ocaml/ocaml
-
Notifications
You must be signed in to change notification settings - Fork 1
Re-enable mark stack compression #2
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
Closed
Closed
Conversation
This file contains hidden or 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
The string @qs@ is available to use in template.in files that produce OCaml code allowing strings to be written as {@qs@|@variable_from_configure@|@qs@} guaranteeing that any value of @variable_from_configure@ yields a properly quoted OCaml string. The calculation inserts 'o' characters until none of the strings passed to AC_SUBST include the sequence |o..o}
* Fixed memory leak from sigaltstack
…N) (ocaml#11095) * [Minor] Clean-up some atomic casts * Strengthen test * Add an acquire fence after `young_limit` triggers an allocation failure The output has been disassembled (gcc -O2, arch=x86-64) to confirm that `CAMLunlikely` works as intended and produces equivalent code as before. * Reintroduce caml_update_young_limit This function ensures that young_limit is always reset to its desired value, without risk of race. Also avoid relying on an information-carrying value for young_limit. * Always reset young limit with dedicated function Aim to take all requests into account to simplify reasoning Reset young_limit after reinitialisation of interrupt variables * [minor] Simplify assertion and make it clearer at least to me (the absence of race in the assertion depended on who calls it)
`ranlib` seems unnecessary if a POSIX-compliant `ar` is used and time stamps are preserved when a `.a` file is installed.
…adunsafe Document that Scanf is not thread-safe
Joining more than once on a domain no longer raises an exception.
fix ocaml#9140 New flag creation `nocwd`
Make finaliser2 test deterministic
Simplify Domain.join
kayceesrk
reviewed
Apr 22, 2022
value block; | ||
uintnat offset; | ||
value* start; | ||
value* end; |
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.
IIUC end
points to the word after the last markable word? If so, perhaps worth adding a comment here.
GNU make needs to know that the compiler libs .cmo and .cmi are produced simultaneously by the same recipe. The fix exploits the fact that while GNU make multi-target rules are quite new (GNU make 4.3+), multi-target pattern rules have existed for a long time. Previously, only the dependency of byte/dynlink_compilerlibs.cmi on byte/dynlink_compilerlibs.cmo was given to GNU make. GNU make (correctly) infers that as no rules emit byte/dynlink_compilerlibs.cmi, it can't change during the build. It therefore only checks the state of byte/dynlink_compilerlibs.cmo at the start of the build, so if it then changes _during_ the build, it does not propagate any rebuilds to things which depended on byte/dynlink_compilerlibs.cmi which in this case includes dynlink_common.cmo. The lack of this dependency allowed dynlink.cma to be relinked with inconsistent assumptions when rebuilding in parallel.
The Iload constructor was changed from a triple to a record, but the disabled backends weren't updated.
Eliminates the partial match warning in these backends, but obviously the emitters are still broken.
Unused variable r12 was originally removed in PR#502.
Extra parameter added in the multicore merge. Obviously the emitter remains broken.
The i386 emitter still had the 4.x name.
The two labels were swapped. Fixes: ocaml#11202
Delay releasing joining domains
Fix or document concurrency issues on channels in Multicore
The test triggers a stack overflow in the type checker. With the new default max stack size, it takes forever to reach the overflow. Co-authored-by: Florian Angeletti <[email protected]>
This had been forgotten in ocaml#11243
Guard additional uses of _MSC_VER to suppress undefined variable warnings (cherry picked from commit 2c2e990)
Factors out some common usage between Warnings and Location for zero-length ghost locations.
Load_path.find{,_uncap} now invoke a hook before raising Not_found, which provides a mechanism for automatically adding directories to the Load_path if required.
[1/3] Restructure LIBDIR: Move Dynlink, Str and Unix to sub-directories
Suggested-by: Guillaume Munch-Maccagnoni <[email protected]> Suggested-by: David Allsopp <[email protected]> Reviewed-by: KC Sivaramakrishnan <[email protected]>
protect Max_domains with CAML_INTERNALS
Before this commit, the -cmi-file option was recognized only by ocamlc. This commit makes sure the option is also recognized by ocamlopt.
Make sure ocamlopt recognizes the -cmi-file command-line option
Makefile.config_if_required can be include'd more than once which overrides any changes made to flags.
Co-authored-by: fabbing <[email protected]>
Ensure Makefile.build_config is only loaded once
43a9649
to
a15e30a
Compare
unfortunately the rebase to upstream has broken the diff here. Going to reopen afresh as #3... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
This PR re-enables mark stack compression when the mark stack reaches more than 1/32th of the major heap.
The PR introduces a simple mark-stack compression scheme. All the mark entries are converted into compressed entries of two words (
page
,bitfield
). For a contiguous heap of sizeH
words and 64bit words, there can be no more thanH/64
compressed entries. We also keep contiguous mark stack entries that can not be more effectively compressed as (page
,bitfield
); for example a very large record or array.The first 5 commits are refactorings to make things go smoothly at the end. The last commit introduces the compression scheme which utilises the addrmap to collate the compressed entries.
This scheme of mark stack compression, is simpler than schemes which require synchronisation and scanning pages; see ocaml-multicore#474 which utilised a synchronisation scheme to make rescanning work.