Skip to content

Enzyme-related (?) cache misses on 1.10 for degeneracystructure #457

Description

@kshyatt

As noted in #449, on 1.10, we intermittently encounter

Error During Test at C:\Users\runneradmin\.julia\packages\EnzymeTestUtils\fNmYk\src\test_forward.jl:71
  Got exception outside of a @test
  KeyError: key (ℂ^2  (ℂ^3)')  (ℂ^2  (ℂ^3)'  (ℂ^4)') not found
  Stacktrace:
   [1] getindex
     @ .\dict.jl:498 [inlined]
   [2] _unsafe_getindex
     @ C:\Users\runneradmin\.julia\packages\LRUCache\ZH7qB\src\LRUCache.jl:189

In the multiplication tests. This seems to only occur for Vtr, and what's especially strange about it is right before the "offending" line in LRUCache.jl, haskey(lru, key) (with this key) returned true while a lock was held. Some Enzyme friends are looking into this, but I'm also opening an issue as @lkdvos asked so that we can track this and reference it in the test file.

The error never occurs if we set the CacheStyle of degeneracystructure to NoCache or set the cache size of the GlobalLRUCache to 0 (not surprising since there is then no cache to miss on).

Removing one space from the product in the domain is seemingly enough to resolve this error, making me think it's some kind of weird race condition, but I've been unsuccessful in figuring out more so far.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions