profile
viewpoint
Ben Noordhuis bnoordhuis Deno Land Inc. The Netherlands

bnoordhuis/bspc 22

Quake 3 BSP-to-AAS compiler

bnoordhuis/amazing-graceful-fs 4

Like graceful-fs, but without eval() hacks and polyfills.

bnoordhuis/chicken-core 4

http://call-cc.org/

bnoordhuis/axis2-c 3

Apache Axis2/C is a Web services engine implemented in the C programming language.

bnoordhuis/chamfilter 3

block China and other South Asian countries at the firewall level

bnoordhuis/entityplus 3

just another quake 3 mod

bnoordhuis/c-ares 2

c-ares is a C library that performs DNS requests and name resolves asynchronously.

pull request commentlibuv/libuv

win: consider a broken pipe a normal EOF

@mmomtchev the test runner is sensitive to the working directory. Make sure to run the test from the main folder - call build/uv_run_tests_a, not uv_run_tests_a.

CI-in-node: https://ci.nodejs.org/view/libuv/job/libuv-in-node/172/ CI: https://ci.nodejs.org/view/libuv/job/libuv-test-commit/2115/

mmomtchev

comment created time in 7 minutes

PR opened denoland/rusty_v8

Support setting OOM callback on `Isolate`.

Exposes v8::Isolate::SetOOMErrorHandler.

+67 -3

0 comment

4 changed files

pr created time in an hour

issue openedlibuv/libuv

Sporadic `SIGILL` on M1/arm64 Apple Macs

Just wanted to bring this into attention, hopefully it's the right place to post.

I've been using an M1 Mac Mini with 8GB of ram (this is important). While testing out the new (beta) VSCode arm64 build, I've been running into frequent crashes with a SIGILL exit code.

Besides VSCode I've seen SIGILL in some other CLI apps as well, for example while running some python scripts.

I recently came across this issue report that was originally discovered in Go: https://openradar.appspot.com/FB8922558

This occurs whenever the copyout call in sendsig fails. The copyout call is responsible for writing the user-space signal handler’s stack frame. It should not be possible for copyout to fail in a well-behaved program where the stack frame is to be written to memory that is validly mapped in the target process. However, on arm64, if the copyout triggers a page fault, the copyout fails. The absent page should be paged in and used.

In the wild, the bug occurs most readily on a system under heavy load (particularly, memory pressure).

I have attached some crash dumps from VSCode here: https://github.com/microsoft/vscode/issues/113410#issuecomment-755635208

The stack trace for the SIGILL crashes mention libuv:

52  Electron Framework!node::LibuvStreamWrap::OnUvRead(long, uv_buf_t const*) [stream_base-inl.h : 126 + 0x10]
     sp = 0x000000016b956790    pc = 0x0000000106e80710
    Found by: stack scanning
53  Electron Framework!node::LibuvStreamWrap::ReadStart()::$_1::__invoke(uv_handle_s*, unsigned long, uv_buf_t*) [stream_wrap.cc : 218 + 0x4]
     sp = 0x000000016b9567c0    pc = 0x0000000106e80ed0
    Found by: stack scanning
54  Electron Framework!uv__stream_io [stream.c : 1239 + 0xc]
     sp = 0x000000016b956810    pc = 0x00000001046d6f80
    Found by: stack scanning

In the issue linked above, we thought this might be fixed by https://github.com/libuv/libuv/pull/3064 but I now believe this is a separate problem.

Note that the Golang guys were able to find a workaround, see: https://github.com/golang/go/commit/7f688d18c0ae6df3e895d21799b8ece7d5941293

Also important is that nodejs crashes with EFAULT or EPIPE quite frequently by itself on the M1, as reported in: https://github.com/nodejs/node/issues/36826

  • Version: (not sure, latest from nodejs 15.5.1 and from Electron)
  • Platform: Darwin Andreis-Mac-mini.local 20.2.0 Darwin Kernel Version 20.2.0: Wed Dec 2 20:40:21 PST 2020; root:xnu-7195.60.75~1/RELEASE_ARM64_T8101 arm64

created time in 3 hours

issue openedlibuv/help

how to generate x86 specific sln using cmake

I have generate x64 sln for successfully using "cmake .." in windows 10. but is there any defines to generate x86 specific sln ?

thanks!

created time in 6 hours

issue commentlibuv/libuv

get_ibmi_physical_address can't handle when Qp2getifaddrs returns names longer than 10 characters

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

NattyNarwhal

comment created time in 7 hours

pull request commentlibuv/libuv

Keepalive

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

theanarkh

comment created time in 7 hours

pull request commentlibuv/libuv

win: consider a broken pipe a normal EOF

@bzoz I removed a workaround for this special case on Win32 from another test There are quite lots of tests that do not pass when run manually - but do when run through ctest - I don't know if this is a problem on my end?

mmomtchev

comment created time in 7 hours

startedbnoordhuis/node-heapdump

started time in 11 hours

issue openedlibuv/libuv

how to generate x86 specific sln using cmake

I have generate x64 sln for successfully using "cmake .." in windows 10. but is there any defines to generate x86 specific sln ?

thanks!

created time in 12 hours

pull request commentcisco/ChezScheme

Limit the line length

If a wide-screen user wants a narrower text they can make their web browser window narrower. With this change a user who wants text wider than 640 pixels (on my system, using the default font size) has no recourse aside from manually overriding the style sheet.

soegaard

comment created time in 19 hours

PR opened cisco/ChezScheme

Limit the line length

According to Matthew Butterick in "Practical Typography" [1] the maximal line length should not be much higher than 90 characters.

This commit changes style of csug style to set the maximal line length. This should only affect users with wide screens.

[1] https://practicaltypography.com/line-length.html

+2 -1

0 comment

1 changed file

pr created time in 20 hours

pull request commentlibuv/libuv

win: consider a broken pipe a normal EOF

@mmomtchev could you add a test for this?

mmomtchev

comment created time in a day

pull request commentlibuv/libuv

win,fsevent: optionally ignore change to last access time

Generally, LGTM, but this needs a test.

drizzd

comment created time in a day

startedbnoordhuis/node-heapdump

started time in a day

pull request commentlibuv/libuv

Document that uv_read_stop always succeeds

I will be honest I'm not a big fan of this "stale bot"

skissane

comment created time in a day

startedmikeal/IPSQL

started time in 2 days

startedu-u-h/swapforth

started time in 2 days

startedAlim-Oezdemir/RamenEngine

started time in 2 days

issue commentForthHub/discussion

Minimal set of low level words to build forth

"I still can't see for example how to build rot from your 7 words: nop, nand, !, @, um+, special, lit. can you define rot in those words." - One can build flip flops and address decoders from NANDs, SRAM and registers from flip flops and decoders, and stacks from SRAM and register (if not implemented as cascaded shift register). From there, it needs moving stack tops between two stacks and from/to a temporary holding register (to avoid, at this point, swap), and voila, there's your ROT :)

kt97679

comment created time in 2 days

startedbnoordhuis/node-heapdump

started time in 2 days

issue commentdenoland/rusty_v8

mingw-32 windows build failed

I used this tutorial - https://github.com/BrooksPatton/learning-rust/wiki/cross_compiling

Japroz-Saini

comment created time in 2 days

issue commentdenoland/rusty_v8

mingw-32 windows build failed

So an you pls tell me what to write in the config file for msvc and what commands do I use to compile my software for windows .

Japroz-Saini

comment created time in 2 days

issue openeddenoland/rusty_v8

mingw-32 windows build failed

Hi,My windows build failed while I ran the following commands:

rustup target add x86_64-pc-windows-gnu
cargo build --release --target x86_64-pc-windows-gnu

I even created a .cargo folder and created a config file but I got an error. File to small to be an archive

created time in 2 days

startedbnoordhuis/node-heapdump

started time in 2 days

startedbnoordhuis/node-iconv

started time in 3 days

startedipxe/ipxe

started time in 3 days

Pull request review commentlibuv/libuv

darwin: Use posix_spawn to spawn subprocesses in macOS

 static void uv__process_child_init(const uv_process_options_t* options, #endif  +#if defined(__APPLE__)+typedef struct uv__posix_spawn_fncs_tag {+  struct {+    int (*set_uid_np)(const posix_spawnattr_t *, uid_t);+    int (*set_gid_np)(const posix_spawnattr_t *, gid_t);+    int (*set_groups_np)(const posix_spawnattr_t*, int, gid_t*, uid_t);+  } spawnattr;++  struct {+    int (*addchdir_np)(const posix_spawn_file_actions_t *, const char *);+  } file_actions;+} uv__posix_spawn_fncs_t;+++static uv_once_t posix_spawn_init_fncs_once = UV_ONCE_INIT;+static uv__posix_spawn_fncs_t posix_spawn_fncs;+++void uv__spawn_init_posix_spawn_fncs(void) {+  /* Try to locate all non-portable functions at runtime */+  posix_spawn_fncs.spawnattr.set_uid_np = +    dlsym(RTLD_DEFAULT, "posix_spawnattr_set_uid_np");+  posix_spawn_fncs.spawnattr.set_gid_np = +    dlsym(RTLD_DEFAULT, "posix_spawnattr_set_gid_np");+  posix_spawn_fncs.spawnattr.set_groups_np = +    dlsym(RTLD_DEFAULT, "posix_spawnattr_set_groups_np");+  posix_spawn_fncs.file_actions.addchdir_np = +    dlsym(RTLD_DEFAULT, "posix_spawn_file_actions_addchdir_np");+}+++int uv__spawn_set_posix_spawn_attrs(posix_spawnattr_t* attrs,+                                    const uv__posix_spawn_fncs_t* posix_spawn_fncs,+                                    const uv_process_options_t* options) {+  int err;+  unsigned int flags;+  sigset_t signal_set;++  err = posix_spawnattr_init(attrs);+  if (err != 0) {+    /* If initialization fails, no need to de-init, just return */+    return err;+  }++  if (options->flags & UV_PROCESS_SETUID) {+    if (posix_spawn_fncs->spawnattr.set_uid_np == NULL) {+      err = ENOSYS;+      goto error;+    }++    err = posix_spawn_fncs->spawnattr.set_uid_np(attrs, options->uid);+    if (err != 0)+      goto error;+  }++  if (options->flags & UV_PROCESS_SETGID) {+    if (posix_spawn_fncs->spawnattr.set_gid_np == NULL) {+      err = ENOSYS;+      goto error;+    }++    err = posix_spawn_fncs->spawnattr.set_gid_np(attrs, options->gid);+    if (err != 0) +      goto error;+  }++  if (options->flags & (UV_PROCESS_SETUID | UV_PROCESS_SETGID)) {+    /* Using ngroups = 0 implied the group_array is empty, and so +     * its contents are never traversed. Still the +     * posix_spawn_set_groups_np function seems to require that the +     * group_array pointer be non-null */+    const int ngroups = 0;+    gid_t group_array = KAUTH_GID_NONE;++    if (posix_spawn_fncs->spawnattr.set_groups_np == NULL) {+      err = ENOSYS;+      goto error;+    }+    +    /* See the comment on the call to setgroups in uv__process_child_init above+     * for why this is not a fatal error */+    SAVE_ERRNO(posix_spawn_fncs->spawnattr.set_groups_np(+      attrs, +      ngroups, +      &group_array, +      KAUTH_UID_NONE));+  }++  /* Set flags for spawn behavior +    * 1) POSIX_SPAWN_CLOEXEC_DEFAULT: (Apple Extension) All descriptors in+    * the parent will be treated as if they had been created with O_CLOEXEC.+    * The only fds that will be passed on to the child are those manipulated+    * by the file actions+    * 2) POSIX_SPAWN_SETSIGDEF: Signals mentioned in spawn-sigdefault in+    * the spawn attributes will be reset to behave as their default+    * 3) POSIX_SPAWN_SETSIGMASK: Signal mask will be set to the value of+    * spawn-sigmask in attributes+    * 4) POSIX_SPAWN_SETSID: Make the process a new session leader if a+    * detached session was requested. */+  flags = POSIX_SPAWN_CLOEXEC_DEFAULT |+          POSIX_SPAWN_SETSIGDEF |+          POSIX_SPAWN_SETSIGMASK;+  if (options->flags & UV_PROCESS_DETACHED) +    flags |= POSIX_SPAWN_SETSID;

You can check that with sysctlbyname("kern.osrelease", str, &size, NULL, 0); >= 19.0.0

https://stackoverflow.com/questions/11072804/how-do-i-determine-the-os-version-at-runtime-in-os-x-or-ios-without-using-gesta

jpcanepa

comment created time in 3 days

startednushell/vscode-nushell-lang

started time in 3 days

pull request commentlibuv/libuv

zos: build in ASCII code page and introduce zoslib

The release is currently waiting on https://github.com/libuv/libuv/pull/3064 (cc: @vtjnash). After that lands, I'll also need to run the CI and Node.js integration CI before cutting the release.

zsw007

comment created time in 3 days

pull request commentlibuv/libuv

zos: build in ASCII code page and introduce zoslib

CI: https://ci.nodejs.org/view/libuv/job/libuv-test-commit/2113/ Resume-CI: https://ci.nodejs.org/view/libuv/job/libuv-test-commit/2114/

CI looks good (one instance of https://github.com/libuv/libuv/issues/2307 and the libuv-test-commit-zos-cmake job is expected to fail with this PR until it is updated as per https://github.com/nodejs/build/issues/2491). We'll need to coordinate landing this PR and updating https://ci.nodejs.org/view/libuv/job/libuv-test-commit-zos-cmake to avoid broken builds.

@cjihrig what's the current outlook on https://github.com/libuv/libuv/issues/3086? I'd like not to break the CI while a release is in progress. FWIW I don't think this PR needs to make 1.41.0 (but equally no objections if it does).

zsw007

comment created time in 3 days

more