================
@@ -711,6 +734,35 @@ std::optional<Register>
RootSignatureParser::parseRegister() {
return Reg;
}
+std::optional<float> RootSignatureParser::parseFloatParam() {
+ assert(CurToken.TokKind == TokenKind::pu_equal &&
+ "Expects to only be invoked starting at given keyword");
+ // Consume sign modifier
+ bool Signed =
+ tryConsumeExpectedToken({TokenKind::pu_plus, TokenKind::pu_minus});
+ bool Negated = Signed && CurToken.TokKind == TokenKind::pu_minus;
+
+ // DXC will treat a postive signed integer as unsigned
+ if (!Negated && tryConsumeExpectedToken(TokenKind::int_literal)) {
+ auto UInt = handleUIntLiteral();
----------------
bogner wrote:
Better to spell out the types here for clarity I think, especially given we're
casting the uint32_t to float here.
https://github.com/llvm/llvm-project/pull/140181
_______________________________________________
llvm-branch-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits