Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

S benchmark doing 2x work

Abierto
#33 4 comentarios 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
35/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Estancado
Stack tecnológico
javascript

Línea de trabajo

Locate the benchmark source referenced in the issue and compare the S implementation with the other signal implementations. Check the node creation and batching setup, then update the benchmark results after correcting those differences; the issue does not name a specific file or test command.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Hi Andrea --
I've seen this benchmark used in a couple other signal implementations but haven't traced down the source. Do you know where it comes from? It has some weird pieces in the S implementation. For instance, this line ...

         S(props.a), S(props.b), S(props.c), S(props.d);

... means that S is actually creating 2 nodes in every place where the other libraries are creating only 1. So S is doing twice the work of the others.

It also disables batching for S but no other library, which seems weird. S should have:

     const run = BATCHED ? S.freeze : (fn) => fn();

Would you mind fixing those in your copy and updating the results?

Other than those issues specific to S, this is almost the worst possible benchmark if you're trying to improve actual application performance. All it tests is update speed of deep intermediate nodes, which happens rarely to never. It doesn't test creation time or memory usage at all, even though those are the biggest factors in app performance.

Overall, though, it's cool to see other fast signals implementations come out. I'm reading through usignal, neat stuff!
-- Adam

Lenguaje dominante
JavaScript
Estrellas
268
Forks
15
Métricas de merge de PR
Sin PR fusionados en 30 d

Preparar el entorno

Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Issues similares

Más issues de JavaScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.