这是indexloc提供的服务,不要输入任何密码
Skip to content

Should the alignment of destinationOffset in resolveQuerySet be 256 on Metal? #1845

@haoxli

Description

@haoxli

On macOS 11.0+, [MTLBlitCommandEncoder resolveCounters:inRange:destinationBuffer:destinationOffset:] requires the destinationOffset to be a multiple of 256 when Metal API validation is enabled, that means we need to change the destinationOffset alignment from 8 to 256 in resolveQuerySet.

But,

  • [MTLBlitCommandEncoder resolveCounters] is supported since macOS 10.15, and has no such restriction on macOS 10.15.
  • Apple document does not say the destinationOffset must be a multiple of 256.
  • The data type in destinationBuffer are uint64_t, it doesn't make sense to request the distinationOffset to be a multiple of 256, the alignment of 8 should be reasonable.

Is it a real restruction newly added on macOS 11.0 for some reason or a bug in the MTLDebugBlitCommandEncoder?

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions