A problem with FFI is that if a callout segfaults, all of memory
including that of the Image is suspect, and execution of the Image terminates.
Occasionally I hunt around hoping to find technology to mitigate that problem.
Maybe this time in I found something... Memory Protection Keys [1]
Perhaps these could ensure Image memory safe when an FFI callout segfaults.
IIUC the main problem with protecting Image memory on every FFI callout
is the time it would take update the flags on every page of Image memory.
Would being able to change the protection of a massive number of pages
with one syscall make it feasible to wrap them around FFI callouts?
This may be useful at least where the FFI use is more about reuse of
existing functionality than about performance.
Or at least useful while someone is learning/experimenting with FFI for
the first time or while becoming familiar with some external library.
Further info at [2] & [3].
cheers -ben
[1] https://lwn.net/Articles/643797/
[2] http://man7.org/linux/man-pages/man7/pkeys.7.html
[3] https://lwn.net/Articles/689395/
I just noticed that the bintray deployment script has the following regex:
{"includePattern": "../products/((newspeak|pharo|squeak).*\\.(?:gz|zip|dmg))", "uploadPattern": "$1"}
Since I was tagging the minheadless with a cmake-minhdls- prefix, they build artifacts are not matching this regex. I prefer changing the prefix with a -cmake-minhdls suffix instead of messing with a potentially dangerous regex.
You can view, comment on, or merge this pull request online at:
https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/411
-- Commit Summary --
* Tag the minheadless builds with CMake with a suffix instead of a prefis.
-- File Changes --
M deploy/pack-vm.sh (10)
-- Patch Links --
https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/411.patchhttps://github.com/OpenSmalltalk/opensmalltalk-vm/pull/411.diff
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/411
Branch: refs/heads/Cog
Home: https://github.com/OpenSmalltalk/opensmalltalk-vm
Commit: d46b3bdc153849fa52e7cfdb7e2314cfabc2c535
https://github.com/OpenSmalltalk/opensmalltalk-vm/commit/d46b3bdc153849fa52…
Author: Ronie Salgado <roniesalg(a)gmail.com>
Date: 2019-06-26 (Wed, 26 Jun 2019)
Changed paths:
M deploy/pack-vm.sh
Log Message:
-----------
Tag the minheadless builds with CMake with a suffix instead of a prefis.
I just noticed that the bintray deployment script have the following regex:
{"includePattern": "../products/((newspeak|pharo|squeak).*\\.(?:gz|zip|dmg))", "uploadPattern": "$1"}
I prefer adding a -cmake-minhdls suffix instead of messing with a potentially dangerous regex.
Commit: 1feda0291023aa06bb953ed065f684bc506d6a64
https://github.com/OpenSmalltalk/opensmalltalk-vm/commit/1feda0291023aa06bb…
Author: Eliot Miranda <eliot.miranda(a)gmail.com>
Date: 2019-06-27 (Thu, 27 Jun 2019)
Changed paths:
M deploy/pack-vm.sh
Log Message:
-----------
Merge pull request #411 from ronsaldo/bug/minheadless-ci-deploy
Tag the minheadless builds with CMake with a suffix instead of a prefix.
Compare: https://github.com/OpenSmalltalk/opensmalltalk-vm/compare/9a881a3b5179...1f…