Skip to content

B5 coverage update#103

Open
coreyqh wants to merge 14 commits into
mainfrom
b5
Open

B5 coverage update#103
coreyqh wants to merge 14 commits into
mainfrom
b5

Conversation

@coreyqh
Copy link
Copy Markdown
Owner

@coreyqh coreyqh commented Apr 27, 2026

WIP

@coreyqh coreyqh mentioned this pull request Apr 27, 2026
@Lamarr3314
Copy link
Copy Markdown
Contributor

Lamarr3314 commented Apr 27, 2026

MinNorm +- 3ulp corrections:
The current coverpoint on B5 checks the bit just before the mantissa. Because there is padding included before the intermediate results, this means that the padded 0 will result in incorrect coverage for values where the mantissa must be all 1s. While this technically works for +3ulp because all +3ulp values have a string of 0s and that padded 0 does not affect it, we should have consistency and change the range for both +-3ulp.
F32 + 3ulp
F32 - 3ulp
F64 + 3ulp
F64 - 3ulp
F128 + 3ulp
F128 - 3ulp
F16 + 3ulp
F16 - 3ulp
BF16 + 3ulp
BF16 - 3ulp
MinSubNorm +-3ulp corrections:
Expand Range of the mantissa to also have the lsb included. For example, the if statement for F32 + 3ulp values should read: iff (CFI.intermX == 0 && CFI.intermM[INTERM_M_BITS -: F32_M_BITS + 1] == 1) {
F32 + 3ulp
F32 - 3ulp
F64 + 3ulp
F64 - 3ulp
F128 + 3ulp
F128 - 3ulp
F16 + 3ulp
F16 - 3ulp
BF16 + 3ulp
BF16 - 3ulp
Additionally, there is a coverpoint called minSubNorm_pm_3_ulp which is unused. Correcting the above +-3ulp coverpoints above should be sufficient. these unused pm coverpoints can be removed.
F32_pm_3ulp
F64_pm_3ulp
F12_pm_3ulp
F16_pm_3ulp
BF16_pm_3ulp
Also, in your coverage, you reference a coverpoint called "precision"_btw_minSubnorm_zero. This coverpoint does not exist anywhere in your code. Making this function will allow the btw_minSunNorm_zero check to work.
F32_btw
F64_btw
F128_btw
F16_btw
BF16_btw

@coreyqh coreyqh marked this pull request as ready for review April 28, 2026 02:31
@coreyqh
Copy link
Copy Markdown
Owner Author

coreyqh commented Apr 28, 2026

@Lamarr3314 Arithmetic operations should be good now. I will get to converts later tonight.

@coreyqh
Copy link
Copy Markdown
Owner Author

coreyqh commented Apr 28, 2026

Converts are annoying. Mostly done here, just need to write a few helper coverpoints

@coreyqh
Copy link
Copy Markdown
Owner Author

coreyqh commented Apr 29, 2026

@Lamarr3314 The covergroup should be good to go. Let me know if you see anything dubious, otherwise I will merge in the morning.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants