This is an archive of the discontinued LLVM Phabricator instance.

[MLIR][SPIRV] Add flat, location, and noperspective decorations
ClosedPublic

Authored by Hazem on May 29 2020, 1:47 PM.

Details

Summary

Add support for flat, location, and noperspective decorations in the serializer and deserializer to be able to process basic shader files for graphics applications"

Diff Detail

Event Timeline

Hazem created this revision.May 29 2020, 1:47 PM
Herald added a project: Restricted Project. · View Herald TranscriptMay 29 2020, 1:47 PM
Herald added a project: Restricted Project. · View Herald TranscriptJun 1 2020, 11:53 AM

Thanks @Hazem ! Just a few nits. Could you just name the test file as decorations.mlir to follow the terms in the spec?

mlir/test/Dialect/SPIRV/Serialization/decorators.mlir
4 ↗(On Diff #267361)

Acutally I think we should // CHECK: location = 0: i32 instead of the spv.globalVariable here given that's the purpose of the test? :)

Similarly for the rest: // CHECK: no_perspective , // CHECK: flat?

antiagainst requested changes to this revision.Jun 4 2020, 7:45 AM
This revision now requires changes to proceed.Jun 4 2020, 7:45 AM
Hazem marked an inline comment as done.Jun 4 2020, 2:35 PM
Hazem updated this revision to Diff 268607.Jun 4 2020, 3:31 PM
  • rename decorations test file and edit CHECK string values to reflect what the tests actually check
antiagainst accepted this revision.Jun 5 2020, 5:35 AM
This revision is now accepted and ready to land.Jun 5 2020, 5:35 AM
This revision was automatically updated to reflect the committed changes.