-
-
Notifications
You must be signed in to change notification settings - Fork 49
Description
What Happened?
While creating some tests, I noticed that the parse flags method fails for the following cases:
k8,"Opteron, Athlon64"
avx512_bitalg,"Support for VPOPCNT[B,W] and VPSHUF-BITQMB instructions"
fsgsbase,"RDFSBASE, WRFSBASE, RDGSBASE, WRGSBASE instructions"
msbds_only,CPU is only affected by the MSDBS variant of BUG_MDS
They should be cleaned and result as
k8 -> Opteron, Athlon64
avx512_bitalg -> Support for VPOPCNT[B,W] and VPSHUF-BITQMB instructions
fsgsbase -> RDFSBASE, WRFSBASE, RDGSBASE, WRGSBASE instructions
msbds_only -> CPU is only affected by the MSDBS variant of BUG_MDS // note extra space in between
You can also view the parsing failure in the popup in features/bugs
To fix this, additional replace () methods will need to be called to get rid of extra spaces and double quotes as well as the string split method needs to be replaced with a manual spit into two sections based on the first comma position.
Steps to Reproduce
- Print out what is stored in a new
Monitor.CPUobject ascpu.features.valuesand compare it to what is stored in the csv files. - Find the features/bugs specified above and check for values that contain commas inside double quotes.
- There is a test in https://github.com/Tbusk/monitor/tree/feature/tests that can be ran to show this
Expected Behavior
The parsing should account for only one comma and remove extra spaces and double quotes.
OS Version
Other Linux
OS Architecture
amd64 (on most hardwares)
Session Type
Secure Session (Wayland)
Software Version
Compiled from git
Log Output
Hardware Info
No response