#[Bug] Burst error BC1054: Unable to resolve type `T. Reason: Unknown.`

1 messages · Page 1 of 1 (latest)

vital gorge
#

When using a method on a custom type DataBlock8x8<T>, burst is not happy. I figured out it's because of an interface implementation using T recursively.

Fortunately I can simply remove the interface; I'm not using it anymore. I'm posting this to report the issue, see if anyone had similar issues (and if workarounds exist?).

Also in modifying these types I've had to nuke the burst cache multiple times to make sure things are actually reinterpreted correctly. The types are defined in an external DLL, perhaps this plays a role?

(Burst 1.8.11)

    DataBlock8x8<int> t1 = default;
    Debug.Log(t1.IsCreated); // Burst error BC1054: Unable to resolve type `T. Reason: Unknown.`
public unsafe interface IDataBlockIterator<T>
    where T : unmanaged
{
    // ..
}

public unsafe interface IDataBlock<T, TBlockIterator> : IDisposable
    where T : unmanaged
    where TBlockIterator : unmanaged, IDataBlockIterator<T>
{
    bool IsCreated { get; }
    // ..
}

public unsafe struct DataBlock8x8<T> : IDataBlock<T, DataBlock8x8<T>.Iterator>
{
    internal unsafe struct Header
    {
        public const int SIZE = BitSet64.SIZE;
        internal BitSet64 Bits;
    }

    Header* _ptr;

    public bool IsCreated
    {
        [MethodImpl(MethodImplOptions.AggressiveInlining)]
        get => _ptr != null;
    }

    // ..
}
slow hemlock
#

the burst team doesn't usually hang out on discord but they do check the forums regularly; I suggest cross-posting there, since it sounds like a legitimate bug to me