================
@@ -58,28 +61,39 @@ int printGPUsByKFD(StringRef NodePath) {
return 1;
long GFXVersion = 0;
+ uint64_t Capability = 0;
for (line_iterator Lines(**BufferOrErr, false); !Lines.is_at_end();
++Lines) {
- StringRef Line(*Lines);
- if (Line.consume_front("gfx_target_version")) {
- if (Line.drop_while([](char C) { return std::isspace(C); })
- .consumeInteger(10, GFXVersion))
+ // Split by ' ' to differentiate capability and capability2
+ auto [Key, Value] = StringRef(*Lines).split(' ');
+ if (Key == "gfx_target_version") {
+ if (Value.trim().consumeInteger(10, GFXVersion))
+ return 1;
+ } else if (Key == "capability") {
----------------
accauble wrote:
I could. I worried about the accidental removal of the space, but I can change
it back.
https://github.com/llvm/llvm-project/pull/224480
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits