Raw profiler hook fails because of a null ref
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 35/100
Línea de trabajo
Comienza en CCorProfilerInfoWrapper::GetILFunctionBody y sigue el estado de CMethodInfo después de SetFinalRenderedFunctionBody, especialmente la relación entre m_bIsInstrumented, m_pIntermediateRenderedMethod y m_pFinalRenderedMethod. Compara el cambio propuesto en SetFinalRenderedFunctionBody con el issue 370 y el commit referenciado. Se considera terminado cuando la reescritura de raw-profiler ya no produce una referencia nula ni un HRESULT de error y recupera el cuerpo de método válido.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
This is somewhat relate to https://github.com/microsoft/CLRInstrumentationEngine/issues/370, as it seems impossible to test them separately, but I believe it a separate issue.
It seems if a raw profiler chooses to rewrite a method but it hasn't been rewritten by an instrumentation method then an null ref will occur, or rather the functions will start to return fail HRESULTs because of a null ref.
For an existing method that has been instrumented by the raw profiler but not an instrumentation method CCorProfilerInfoWrapper::GetILFunctionBody will call pMethodInfo->GetIntermediateRenderedFunctionBody. This because pMethodInfo->IsInstrumented() has been set when CMethodInfo::SetFinalRenderedFunctionBody was called.
This means that we're in a state where m_bIsInstrumented is true, m_pIntermediateRenderedMethod is null and m_pFinalRenderedMethod is set to a valid method body.
So, our CMethodInfo has a valid method body, but I'm not sure what the correct way to retrieve it.
One possible fix is to update CMethodInfo::SetFinalRenderedFunctionBody so that it sets m_pIntermediateRenderedMethod if it is not already set. I believe this works, but can't test it properly because of the other issue: https://github.com/robertpi/CLRInstrumentationEngine/commit/22b96b56ec69b1cdb74e9d0d5f3a73169385a923#diff-9025cfc4efbe6666f69f6103e8d4aca595e5107e7c0ec46d644b3f34345717c9R1314
There maybe other better ways to fix this.
- Lenguaje dominante
- C++
- Estrellas
- 105
- Forks
- 53
- Merge medio
- 3 d 14 h
- PR fusionados (30 d)
- 4
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de microsoft/CLRInstrumentationEngine
-
documentation
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
microsoft/CLRInstrumentationEngine#169 · 2 comentarios ·
-
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 20/100
-
Dificultad 3/5 1-2 días Aptitud para principiantes 45/100
microsoft/CLRInstrumentationEngine#526 · 1 reacción ·
-
bug
Dificultad 3/5 1-2 días Aptitud para principiantes 35/100
Todos los issues de microsoft/CLRInstrumentationEngine
Issues similares
-
enhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
metasequoiaime/msime#9113 ·
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 65/100
tone-3000/tone3000-plugin#257 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Locked plugin flip-flops position on every refresh after being disabledPosiblemente ocupada @Illustar0 la tomó hoy. Abiertoissue report
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
ModOrganizer2/modorganizer#2449 ·
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 67/100
Los mantenedores suelen responder en 1 día
-
enhancement P5
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
open-astro/AlpacaBridge#1468 ·
Los mantenedores suelen responder en 1 día