Skip to content

Calli with no arguments will crash dataflow analysis #1582

Closed
@MichalStrehovsky

Description

@MichalStrehovsky

We call PopUnknown with whatever is the number of parameters to the calli, but the first thing that PopUnknown does is that it will throw if this is less then 1.

https://github.com/mono/linker/blob/4f6f471f99189cb79f13a5b1ccfd3a26f81db601/src/linker/Linker.Dataflow/MethodBodyScanner.cs#L515-L516

I'm not sure we even use the return value of PopUnknown for anything, so maybe this can be simplified and doesn't have to throw (it's a thing taken from .NET Native analyzer verbatim if I remember correctly). I hit this while already yak shaving so I don't want to dig into this any further right now, just filing this for tracking.

Cc @vitek-karas

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions