Skip to content

Remove hacky StringRef cache #54

@raviqqe

Description

@raviqqe

Problem

  • The implicit global StringRef cache grows forever.
  • We can never clean them safely.
  • That makes the use of Melior impossible in compilers that share states in memory among compilation of modules.

Solution

  • Should the MLIR C API accept non-null-terminated strings?
  • Should we move this into a Context type making it a non-transparent type?

https://github.com/raviqqe/melior/blob/2118d871f7729714fd5e34986e45ba6513736ed7/src/string_ref.rs#L14

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions